CVE Tools
A Trailing Dot Broke Visual Studio Copilot's Guardrails. Microsoft Fixed the 8.8 RCE and Paid the Researcher $0.. Windows quietly strips a period off the end of a filename. Copilot's own edit-confirma

A Trailing Dot Broke Visual Studio Copilot's Guardrails. Microsoft Fixed the 8.8 RCE and Paid the Researcher $0.

Windows quietly strips a period off the end of a filename. Copilot's own edit-confirmation check didn't know that — so an AI agent could rewrite its own MCP config and settings under a filename that looked different but wrote to the same file.

Our read: this is a patch-now bug — CVSS 8.8, no workaround, fixed in the October 13, 2026 Patch Tuesday — but the more durable lesson is the bug class. Visual Studio's Copilot agent checked whether a filename matched a protected name as a literal string, before Windows' own filesystem silently stripped a trailing period from it. That one-character gap let a prompt-injected agent write to .mcp.json and settings.VisualStudio.json under a name that looked different but resolved to the file it was explicitly supposed to be blocked from touching. The same researcher, Johann Rehberger (wunderwuzzi) of Embrace The Red, says it's the third bug in two months that Microsoft patched but declined to pay a bounty for.

8.8CVSS scoreMicrosoft's own severity label: "Important," not "Critical"
CWE-94Code injectiona path-validation bypass, not a memory-safety bug
70 daysReport to patchAug 4 → Oct 13, 2026 — confirmed Sept 16
$0Bounty paidruled out of scope; the researcher's third unpaid patch in two months

The bug: a string compare that didn't know about Windows' trailing-dot quirk

Visual Studio's and SQL Server Management Studio's Copilot agent can edit files in your workspace, but it's supposed to ask for confirmation before touching a short list of protected configuration files — .mcp.json (which MCP servers the agent is allowed to launch) and settings.VisualStudio.json (editor and tool settings, including the path to the ripgrep binary Copilot uses for search). The confirmation check, in EditsFunctionHandler.GetEditConfirmationTypeAsync inside Microsoft.VisualStudio.Copilot.Core.dll, compared the requested filename against the protected names as literal strings.

Windows has a decades-old quirk: Win32 file APIs accept a trailing ASCII period (0x2E) in a filename, but silently drop it when the file is actually created or written — settings.VisualStudio.json. and settings.VisualStudio.json are the same file on disk. The confirmation check ran before that normalization, so settings.VisualStudio.json. read as a different, unprotected string — and sailed through. The actual write landed on the real, protected file anyway. Rehberger found the same gap let path traversal (..\) escape the Extensions directory the agent is otherwise confined to, and that a leaked InstallationID inside SSMS.isolation.ini was enough to compute the exact settings path to target in SSMS.

From an untrusted prompt to code execution

  1. Attacker plants instructions in content the agent reads
  2. Prompt injection steers Copilot (MAI-Code-1-Flash) to edit a settings file
  3. Filename submitted with a trailing dot, e.g. settings.VisualStudio.json.
  4. String-compare guardrail doesn't recognize it as the protected file — no confirmation prompt
  5. Windows strips the dot on write; real settings.VisualStudio.json is overwritten
  6. ripgrepPath repointed to calc.exe, or .mcp.json registers a rogue MCP server
  7. Next search or IDE restart launches the attacker's command

Two working demos, both ending in arbitrary code execution

  1. Ripgrep hijack (Visual Studio). An injected prompt tells Copilot to set copilot.general.tools.ripgrepPath to C:\Windows\System32\calc.exe inside settings.VisualStudio.json. (trailing dot). The agent is then asked to run an ordinary grep search — Copilot shells out to what it thinks is ripgrep, and Calculator opens instead.
  2. Rogue MCP server (SSMS). The agent rewrites .mcp.json. to register a new MCP server pointing at an attacker-chosen command, adds that server's name to enabledMcpServers, and removes it from disabledMcpServers. The next time the IDE launches configured MCP servers, the attacker's command runs. In SSMS, the extra step is reading the leaked InstallationID from SSMS.isolation.ini to locate the right settings path.

"Important" vs. 8.8: the severity label and the score disagree

FieldValueSource
CVSS score8.8 (CVSS 3.1, AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H)cve.tools / NVD
Microsoft's severity categoryImportant (not Critical)MSRC advisory
EPSS0.82% — 56.9th percentilecve.tools
CWECWE-94, Improper Control of Generation of Codecve.tools
In CISA KEV?Nocve.tools
Public exploit / PoC codeNone trackedcve.tools

The part that isn't a CVE: a $0 bounty for a patched RCE

Disclosure to patch, in public dates

  1. Initial report to MSRC
    The path-validation bypass leading to RCE, reported by Johann Rehberger.
  2. Broader Visual Studio impact shared
    Additional VS-specific exploit paths identified and sent to Microsoft.
  3. Follow-up communication
    Per the researcher's published timeline.
  4. Microsoft confirms the vulnerability
  5. Bounty decision: $0
    Ruled "out of scope" for a reward.
  6. Fix ships
    Patch Tuesday — Visual Studio 2022 17.14.42, Visual Studio 2026 18.10.4.
This will not prevent the write to that exact file! ... Security controls around agents must hold even when the agent itself is compromised or misaligned.
— Johann Rehberger (wunderwuzzi), Embrace The Red

Rehberger frames the $0 decision as part of a pattern, not a one-off: by his count, this is the third vulnerability in two months that Microsoft confirmed and patched but ruled ineligible for a reward. He's not alleging the bug was faked or overstated — he's flagging an incentive problem: if confirmed, patched, CVE-rated RCEs keep coming back as "out of scope," independent researchers have less reason to report to the vendor first rather than disclosing publicly or selling the finding elsewhere.

What the guardrail checked vs. what Windows actually does

Copilot's edit-confirmation check
  • Compares the requested filename to a list of protected names
  • Treats the comparison as an exact string match
  • Runs before the OS normalizes the path
Correct for the string it sees — wrong file identity model.
Windows NTFS / Win32 file APIs
  • Silently strips a trailing ASCII period from filenames on write
  • Resolves `..\` traversal components
  • Has worked this way for decades — it's documented Microsoft behavior
Not a bug in Windows; a well-known normalization quirk the check didn't account for.

Why this isn't just a Visual Studio story

CWE-94 — code injection that happens because an AI agent's own safety check can be routed around — is becoming a recurring shape, not an isolated class of bug. We covered the same root pattern in PraisonAI's CodeAgent (CVE-2026-61447, CVSS 10.0): a component designed to execute model-generated code, with a containment assumption that didn't hold once untrusted input reached it. The common thread across both is that the vulnerable surface isn't the AI model's judgment — it's the boring, deterministic plumbing (a path check, a sandbox boundary) that was supposed to backstop that judgment regardless of what the model decided to do.

ProductAffected versionsFixed in
Visual Studio 2022 (17.14)17.14.0 – below 17.14.4217.14.42
Visual Studio 2026 (18.10)18.10.0 – below 18.10.418.10.4
SQL Server Management StudioShares the vulnerable Copilot.Core.dllFixed with the same rollup
No vendor detection signature exists yet · Audit script (cve.tools editorial, not vendor-issued)

Microsoft's fix is a code change (`GetFullPath` normalization before the comparison), not a signature defenders can deploy. There is no public Sigma, Suricata, or Nuclei rule for this bug. Below is an audit check we wrote ourselves — not a vendor-issued or crowd-sourced detection — to help you confirm you're patched and your settings weren't already tampered with.

Leftover trailing-dot config files or an unexpected ripgrepPath value that would indicate the bypass was used before you patched.
# PowerShell: flag suspicious ripgrepPath / MCP entries and leftover trailing-dot files
Get-ChildItem -Recurse -Filter "settings.VisualStudio.json*" $env:APPDATA,$env:LOCALAPPDATA 2>$null |
  Where-Object { $_.Name -match '\.$' -or (Get-Content $_.FullName -Raw) -match 'ripgrepPath'} |
  ForEach-Object { Write-Host "Review: $($_.FullName)" }
Get-ChildItem -Recurse -Filter ".mcp.json*" $env:USERPROFILE 2>$null |
  Where-Object { $_.Name -match '\.$' } |
  ForEach-Object { Write-Host "Trailing-dot .mcp.json found: $($_.FullName)" }
cve.tools
  1. Update to Visual Studio 2022 17.14.42, Visual Studio 2026 18.10.4, or the equivalent patched SSMS build — there is no workaround short of the patch.
  2. After updating, manually inspect .mcp.json, enabledMcpServers/disabledMcpServers, and the copilot.general.tools.ripgrepPath value in settings.VisualStudio.json for anything you didn't configure yourself.
  3. If you run Copilot agents against untrusted content (web pages, third-party repos, tool output you don't control), treat that as the real attack surface — this bug needed prompt injection to matter, not network access.
  4. Track your own exposure on your stack rather than assuming a Patch Tuesday fix means every machine in your fleet is current.

Vulnerability and bounty data current as of October 23, 2026

For the bigger picture on the vendor behind this bug, see our Microsoft vendor page and trends for how this CVE compares to the rest of the record October 2026 Patch Tuesday batch.

Sources: Embrace The Red — "Visual Studio Copilot and SSMS Remote Code Execution" (original research) · Microsoft Security Response Center — CVE-2026-103572 advisory · NVD — CVE-2026-103572