Back to Intelligence

Belgium eID Browser Extension RCE: How a Compromised Trust Framework Exposed Citizen Accounts — Detection and Hardening Guide

SA
Security Arsenal Team
August 13, 2026
10 min read

Belgium's electronic ID (eID) system is the backbone of digital identity for millions of citizens — it gates access to tax filings, health records, social security, and government services. This week, researchers disclosed that the browser extension underpinning eID authentication contained severe vulnerabilities that allowed remote code execution on endpoints where citizens authenticated. In plain terms: the component designed to prove who you are could be turned into a delivery vehicle for running attacker-controlled code under your identity.

This is not a niche European government problem. It is a case study in a systemic blind spot that affects every enterprise I assess: browser extensions operate with extraordinary privilege, receive almost none of the scrutiny we apply to traditional software, and sit directly in the authentication path. If your organization uses hardware-backed authentication, smart card middleware, or PKI-based SSO with a browser extension component — and most do — this story is about you.

Technical Analysis

The Architecture That Failed

Belgium's eID implementation follows the standard smart-card-to-browser pattern:

  1. Middleware layer — a locally installed package that communicates with the smart card reader.
  2. Native messaging host — a local process registered with the browser that brokers communication between web pages and the middleware via the browser's native messaging API (chrome.runtime.sendNativeMessage / browser.runtime.sendNativeMessage).
  3. Browser extension — the JavaScript-facing component that content pages invoke to trigger authentication flows.

The disclosed vulnerabilities lived in this extension and its trust boundary with web content. The critical failures, from a defender's perspective:

  • Insufficient origin validation. The extension failed to rigorously verify which web origins could invoke its privileged messaging interface. That means an arbitrary malicious site — or a compromised legitimate site — could reach functionality that was intended only for official government portals.
  • Trust in the native messaging channel. Once a web page can drive the extension, it can drive the native messaging host. Weak input validation between the extension and the local host process turned an extension-reachable flaw into local code execution in the context of the logged-on user.
  • Authentication session exposure. Because the extension mediates the signing and authentication flows, compromise at this layer does not just yield code execution — it yields the ability to manipulate or abuse the citizen's authenticated session and signed transactions. That is the difference between an endpoint bug and an identity infrastructure compromise.

Why Extensions Are the Soft Underbelly

I have run red team exercises where the fastest path to a beachhead was not a phish with a macro — it was abusing the extension ecosystem. The structural problems:

  • Extensions auto-update silently; your change-management process never sees them.
  • EDR tools frequently exclude browser processes and their child processes from aggressive scrutiny because of performance tuning and false-positive fatigue.
  • Native messaging hosts execute as separate local binaries, often outside the browser sandbox entirely, inheriting full user privileges.
  • Enterprise software inventories almost never include extension manifests, versions, or permissions.

No CVE identifier has been published in the source reporting at the time of writing, and exploitation status against Belgian citizens in the wild has not been confirmed in the disclosure. Treat this as pre-exploitation-window intelligence: the vulnerability class is now public, the research is public, and extension trust-boundary flaws of this type are historically quick to be weaponized once described.

Detection & Response

The highest-fidelity detection strategy for extension-borne RCE is not signature-based — it is behavioral. A compromised extension or native messaging host manifests as the browser process tree doing things browsers do not do: spawning shells, script interpreters, or unsigned binaries outside sanctioned install paths.

The following detections target exactly that observable chain.

YAML
---
title: Browser Process Spawning Shell or Script Interpreter - Potential Extension or Native Messaging RCE
id: 3f8a2c71-9d4e-4b6a-ae15-7c2d5f9b1e08
status: experimental
description: Detects web browsers spawning command shells or script interpreters, consistent with code execution achieved through a malicious or compromised browser extension or native messaging host such as the Belgium eID extension flaw. Browsers should not ordinarily parent cmd, powershell, wscript, or rundll32.
references:
  - https://www.darkreading.com/application-security/belgium-eid-authentication-citizen-accounts-rce
  - https://attack.mitre.org/techniques/T1059/
  - https://attack.mitre.org/techniques/T1554/
author: Security Arsenal
date: 2026/04/06
tags:
  - attack.execution
  - attack.t1059
  - attack.persistence
  - attack.t1554
logsource:
  category: process_creation
  product: windows
detection:
  selection_parent:
    ParentImage|endswith:
      - '\chrome.exe'
      - '\msedge.exe'
      - '\firefox.exe'
      - '\brave.exe'
  selection_child:
    Image|endswith:
      - '\cmd.exe'
      - '\powershell.exe'
      - '\pwsh.exe'
      - '\wscript.exe'
      - '\cscript.exe'
      - '\mshta.exe'
      - '\rundll32.exe'
      - '\regsvr32.exe'
  filter_known_native_hosts:
    CommandLine|contains:
      - 'native messaging host'
  condition: selection_parent and selection_child and not filter_known_native_hosts
falsepositives:
  - Legitimate native messaging hosts (eID middleware, SSO brokers, enterprise password managers) spawning helper processes; baseline these by full command line, not process name
  - Browser crash-reporting utilities
level: high
---
title: Unsigned or User-Directory Binary Executed as Browser Native Messaging Host
id: 8b1e4d92-6c3f-4a78-bd29-1e5f7a3c9d46
status: experimental
description: Detects execution of native messaging host binaries from user-writable or non-standard locations. Legitimate middleware (including Belgium eID) installs its native messaging host under Program Files; execution from AppData, Temp, or Public directories indicates a trojanized or rogue host registered by a malicious extension.
references:
  - https://www.darkreading.com/application-security/belgium-eid-authentication-citizen-accounts-rce
  - https://attack.mitre.org/techniques/T1554/
author: Security Arsenal
date: 2026/04/06
tags:
  - attack.persistence
  - attack.t1554
  - attack.defense_evasion
logsource:
  category: process_creation
  product: windows
detection:
  selection_path:
    Image|contains:
      - '\AppData\Local\Temp\'
      - '\AppData\Roaming\'
      - '\Users\Public\'
      - '\ProgramData\Microsoft\Crypto\'
  selection_parent:
    ParentImage|endswith:
      - '\chrome.exe'
      - '\msedge.exe'
      - '\firefox.exe'
  condition: selection_path and selection_parent
falsepositives:
  - Some legitimate password-manager and SSO extensions install hosts under AppData; verify publisher signature before allowlisting
level: high

For Microsoft Sentinel and Defender for Endpoint environments, the following hunt identifies the same process-tree anomaly fleet-wide, with prevalence scoring to separate sanctioned middleware from outliers. A native messaging host used by every workstation in a government agency will show high parent prevalence; a trojanized host on three machines will not.

KQL — Microsoft Sentinel / Defender
let BrowserProcesses = dynamic(['chrome.exe','msedge.exe','firefox.exe','brave.exe']);
let SuspiciousChildren = dynamic(['cmd.exe','powershell.exe','pwsh.exe','wscript.exe','cscript.exe','mshta.exe','rundll32.exe','regsvr32.exe']);
DeviceProcessEvents
| where TimeGenerated > ago(14d)
| where InitiatingProcessFileName in~ (BrowserProcesses)
| where FileName in~ (SuspiciousChildren)
   or (FolderPath has_any ('\\AppData\\Local\\Temp\\','\\Users\\Public\\') and InitiatingProcessFileName in~ (BrowserProcesses))
| summarize ExecutionCount = count(),
            DistinctDevices = dcount(DeviceId),
            Devices = make_set(DeviceName, 10),
            SampleCommandLine = take_any(ProcessCommandLine)
    by FileName, FolderPath, InitiatingProcessFileName
| extend PrevalenceTier = case(DistinctDevices <= 5, 'LOW - Investigate Immediately',
                               DistinctDevices <= 50, 'MEDIUM - Verify Against Software Inventory',
                               'HIGH - Likely Sanctioned Middleware')
| order by DistinctDevices asc;

For deep-dive endpoint forensics with Velociraptor, hunt the actual extension and native messaging host registration artifacts. On Windows, Chrome and Edge register native messaging hosts via HKLM\SOFTWARE\Google\Chrome\NativeMessagingHosts and HKCU equivalents; Firefox uses HKLM\SOFTWARE\Mozilla\NativeMessagingHosts. An attacker-controlled extension must register a manifest somewhere — and that manifest is forensic gold.

VQL — Velociraptor
-- Enumerate native messaging host registrations and validate their install paths
LET registry_hives = ('HKEY_LOCAL_MACHINE/SOFTWARE/Google/Chrome/NativeMessagingHosts/*',
                      'HKEY_CURRENT_USER/SOFTWARE/Google/Chrome/NativeMessagingHosts/*',
                      'HKEY_LOCAL_MACHINE/SOFTWARE/Mozilla/NativeMessagingHosts/*',
                      'HKEY_CURRENT_USER/SOFTWARE/Mozilla/NativeMessagingHosts/*',
                      'HKEY_LOCAL_MACHINE/SOFTWARE/Microsoft/Edge/NativeMessagingHosts/*')

SELECT Key.OSPath AS RegistryPath,
       Key.Name AS HostName,
       read_file(filename=Key.OSPath.OSPath) AS ManifestPointer
FROM foreach(row=registry_hives,
             query={SELECT * FROM glob(globs=OSPath, accessor='registry')})
WHERE HostName IS NOT NULL

-- Correlate with running browser-spawned child processes
SELECT Pid, Ppid, Name, Exe, CommandLine, Username, CreateTime
FROM pslist()
WHERE get(field='Ppid') IN (SELECT Pid FROM pslist()
                            WHERE Name =~ '(chrome|msedge|firefox|brave)\\.exe')
  AND (Name =~ '(cmd|powershell|wscript|cscript|mshta|rundll32)\\.exe'
       OR Exe =~ '(AppData\\\\Local\\\\Temp|Users\\\\Public)')

Remediation and Hardening

Immediate Actions

  1. Update the Belgium eID middleware and browser extension to the latest vendor release. Check the official Belgium eID portal (eid.belgium.be) and the Federal Public Service Policy & Support (BOSA) advisories for the patched version. If your organization has Belgian staff or partners authenticating with eID, push the update through your package manager (Intune, SCCM, or equivalent) rather than waiting for auto-update.
  2. Inventory every native messaging host in your environment. These are local executables reachable from any web page through an extension — they deserve the same change-control scrutiny as services and scheduled tasks.
  3. Baseline sanctioned extensions and enforce allowlisting. Use Chrome's ExtensionInstallAllowlist/ExtensionInstallForcelist and Edge equivalents via Group Policy. If your identity stack requires the eID extension, pin it explicitly and block everything else by default.

The following script audits native messaging host registrations, flags hosts installed outside sanctioned directories, and checks extension inventories across Chrome and Edge profiles:

PowerShell
# Belgium eID / Native Messaging Host Audit Script
# Run as Administrator on Windows endpoints. Outputs JSON for SIEM ingestion.

$findings = @()

# 1. Enumerate native messaging host registrations (Chrome, Edge, Firefox)
$nmhRoots = @(
    'HKLM:\SOFTWARE\Google\Chrome\NativeMessagingHosts',
    'HKCU:\SOFTWARE\Google\Chrome\NativeMessagingHosts',
    'HKLM:\SOFTWARE\Microsoft\Edge\NativeMessagingHosts',
    'HKCU:\SOFTWARE\Microsoft\Edge\NativeMessagingHosts',
    'HKLM:\SOFTWARE\Mozilla\NativeMessagingHosts',
    'HKCU:\SOFTWARE\Mozilla\NativeMessagingHosts'
)

foreach ($root in $nmhRoots) {
    if (Test-Path $root) {
        Get-ChildItem $root | ForEach-Object {
            $manifestPath = (Get-ItemProperty $_.PSPath).'(default)'
            if (-not $manifestPath) {
                $manifestPath = (Get-ItemProperty $_.PSPath).'(Default)'
            }
            $suspicious = $false
            $reason = ''
            if ($manifestPath -match 'AppData\\Local\\Temp|Users\\Public|\\Downloads\\') {
                $suspicious = $true; $reason = 'Host manifest in user-writable/unexpected path'
            }
            # Parse manifest and validate the host binary signature
            if ($manifestPath -and (Test-Path $manifestPath)) {
                try {
                    $manifest = Get-Content $manifestPath -Raw | ConvertFrom-Json
                    $hostExe = $manifest.path
                    if ($hostExe -and (Test-Path $hostExe)) {
                        $sig = Get-AuthenticodeSignature $hostExe
                        if ($sig.Status -ne 'Valid') {
                            $suspicious = $true; $reason = "Host binary unsigned or invalid signature: $hostExe"
                        }
                    }
                } catch { $reason = 'Manifest parse failure - inspect manually' }
            }
            $findings += [PSCustomObject]@{
                HostName     = $_.PSChildName
                RegistryRoot = $root
                ManifestPath = $manifestPath
                Suspicious   = $suspicious
                Reason       = $reason
                Timestamp    = (Get-Date).ToString('o')
            }
        }
    }
}

# 2. Inventory installed extensions across all Chrome/Edge user profiles
$extensionDirs = @(
    "$env:LOCALAPPDATA\Google\Chrome\User Data\*\Extensions",
    "$env:LOCALAPPDATA\Microsoft\Edge\User Data\*\Extensions"
)
foreach ($dir in $extensionDirs) {
    Get-ChildItem $dir -ErrorAction SilentlyContinue | ForEach-Object {
        Get-ChildItem $_.FullName -ErrorAction SilentlyContinue | ForEach-Object {
            $manifestFile = Join-Path $_.FullName 'manifest.json'
            if (Test-Path $manifestFile) {
                $m = Get-Content $manifestFile -Raw | ConvertFrom-Json
                $perms = ($m.permissions + $m.host_permissions) -join ','
                $risky = $perms -match '<all_urls>|nativeMessaging|webRequest|cookies'
                $findings += [PSCustomObject]@{
                    HostName     = "EXT:$($m.name)"
                    RegistryRoot = $_.Parent.Parent.FullName
                    ManifestPath = $manifestFile
                    Suspicious   = ($risky -and $m.name -notmatch 'eID|beid')
                    Reason       = "High-privilege permissions: $perms"
                    Timestamp    = (Get-Date).ToString('o')
                }
            }
        }
    }
}

# 3. Output flagged results
$findings | Where-Object { $_.Suspicious } | ConvertTo-Json -Depth 4
Write-Host "`nTotal artifacts audited: $($findings.Count). Flagged: $(($findings | Where-Object Suspicious).Count)"

Strategic Hardening

  • Apply CIS Control 7 (Continuous Vulnerability Management) to the extension layer. Your VM program almost certainly covers OS and application CVEs; extend scope to browser extensions and native messaging hosts. They are software. They have attack surface. Inventory them.
  • Network-layer containment. Extensions that only need to talk to specific government or IdP origins can be constrained via ExtensionSettings policy with runtime_blocked_hosts — reducing the blast radius if origin validation in the extension itself is weak, as it was here.
  • Authentication assurance review. If your workforce or constituency authenticates through extension-mediated flows (smart cards, FIDO brokers, SSO extensions), assume the extension layer can be compromised and require phishing-resistant factors whose signing operations occur in hardware the extension cannot drive unattended. Monitor for signing operations initiated outside expected user session patterns.
  • Tabletop the scenario. This incident is a ready-made tabletop: "Our identity middleware extension is compromised and is executing code on 400 endpoints during authentication." Walk your IR team through extension-specific forensics — most playbooks have never touched a NativeMessagingHosts registry key.

The broader lesson from Belgium is one I deliver to CISOs every quarter: the trust frameworks we build identity on are only as strong as their least-scrutinized component. Right now, in most environments, that component is the browser extension.

Related Resources

Security Arsenal Penetration Testing Services AlertMonitor Platform Book a SOC Assessment vulnerability-management Intel Hub

Is your security operations ready?

Get a free SOC assessment or see how AlertMonitor cuts through alert noise with automated triage.