Local command execution via stale in-memory shortcuts
Published Jun 26, 2026 · Updated Jun 26, 2026
TOCTOU in NppCommands.cpp in Notepad++ before 8.9.6.4 allows local users to execute commands via a swapped shortcuts.xml file. At command dispatch, the code validates the HMAC of the restored on-disk file but executes a UserCommand retained in the startup-populated _userCommands vector. Write access to shortcuts.xml before launch and restoration before command dispatch are required; the injected command runs with the current user's privileges.
Summary
What happened
TOCTOU in NppCommands.cpp in Notepad++ before 8.9.6.4 allows local users to execute commands via a swapped shortcuts.xml file. At command dispatch, the code validates the HMAC of the restored on-disk file but executes a UserCommand retained in the startup-populated _userCommands vector. Write access to shortcuts.xml before launch and restoration before command dispatch are required; the injected command runs with the current user's privileges.
The record
- CVE
- CVE-2026-52885
- Published
- Jun 26, 2026
- Updated
- Jun 26, 2026
- Vendor
- Notepad++
- Product
- Notepad++
- Classifications
- CWE-367
- Attack vector
- local
- Privileges
- Unavailable
Timeline
How it unfolded
- Jun 26, 2026CVE publishedPublication date reported by the CVE source.
- Jun 26, 2026Record updatedLatest update available in the CVE record.
Exploitability
Present is not the same as exploitable
Compare your product and version with the public record. A matching version still requires validation against your environment.
Is a vulnerable build present?
Compare these published version ranges with your installed build and any vendor patches.
- Affected versionversion=< 8.9.6.4
What conditions does exploitation require?
What is affected?
Published CVSS scores
CVSS describes severity. EPSS estimates exploitation probability.
Attacks
What attackers are doing with it
Daily unique IPs observed by Shadowserver honeypots for known exploited vulnerabilities (KEVs). Missing observations do not establish an absence of attacks.
Weakness, pattern, technique
Public exploit references
- poc_8962_toctou.ps1functional · demonstrated
Labels summarize the accepted research assessment. They do not indicate a test against your environment.
Technologies
Your stack
See the directory against your own environment.
Your stack
Check the software in your environment
Book a demo to see how Hinoki identifies affected software and validates exploitability in your environment.
Book a demo