Severity by source
CVSS:4.0/AV:L/AC:H/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X
Local-only binary planting (AV:L); multiple preconditions and a privileged user must select the attacker dir, so AC:H and UI:R; attacker needs no prior privileges (PR:N); code runs as installer with full C/I/A.
Primary rating from Vendor (GitHub_M).
CVSS VectorVendor: GitHub_M
Lifecycle Timeline
3DescriptionCVE.org
Notepad++ is a free and open-source source code editor. From 8.9.4 until 8.9.6, Notepad++ contains a local privilege escalation vulnerability in the installer. During installation, the installer invokes powershell.exe without using an absolute path after setting the working directory to the installation contextMenu directory. If an attacker can pre-place a malicious powershell.exe in a user-writable custom installation directory, and a privileged user later runs the installer and selects that directory, the attacker-controlled executable is launched with the elevated privileges of the installer. This vulnerability is fixed in 8.9.6.
AnalysisAI
Local privilege escalation in the Notepad++ Windows installer (versions 8.9.4 through 8.9.5) lets an unprivileged local attacker gain the elevated privileges of the installer by planting a malicious powershell.exe. Because the installer calls powershell.exe by name (not absolute path) after setting the working directory to the installation contextMenu folder, a privileged user who installs into an attacker-writable custom directory triggers execution of the attacker's binary. No public exploit has been identified at time of analysis; the issue is fixed in 8.9.6 and corresponds to CWE-426 (Untrusted Search Path).
Technical ContextAI
The root cause is CWE-426 (Untrusted Search Path / insecure binary resolution) in the NSIS-based installer script (PowerEditor/installer/nppSetup.nsi). To register the Windows 11 modern right-click context menu, the installer ran 'powershell -Command "Add-AppxPackage ..."' invoking powershell.exe by bare name. On Windows, command resolution searches the current working directory and PATH; since the installer first set its working directory to $INSTDIR\contextMenu, a powershell.exe placed alongside the MSIX in that directory is resolved and executed before the legitimate System32 copy. The affected product per CPE is cpe:2.3:a:notepad-plus-plus:notepad-plus-plus, the widely used open-source Windows source-code editor. The fix reads the trusted PowerShell path from HKLM\SOFTWARE\Microsoft\PowerShell\1\ShellIds\Microsoft.PowerShell and invokes that absolute path instead.
RemediationAI
Vendor-released patch: upgrade to Notepad++ 8.9.6, which resolves the PowerShell path from the HKLM registry (SOFTWARE\Microsoft\PowerShell\1\ShellIds\Microsoft.PowerShell) and invokes that absolute path instead of the bare 'powershell' name; obtain it via the official release and review the advisory at https://github.com/notepad-plus-plus/notepad-plus-plus/security/advisories/GHSA-6f8f-vmfc-r8c5. If you cannot immediately patch, run the installer only from trusted, non-writable locations and install Notepad++ into a default protected path such as %ProgramFiles% (which standard users cannot write to), avoiding custom user-writable installation directories where a malicious powershell.exe could be pre-placed - the trade-off is loss of flexible install-location choice. Additionally, audit candidate install directories for a stray powershell.exe before running the elevated installer, and restrict who can drop files into shared install staging folders; these controls reduce the planting opportunity but do not substitute for upgrading.
More in Notepad Plus Plus
View allNotepad++ versions prior to 8.8.9 contain an update integrity verification vulnerability (CVE-2025-15556) when using the
Local code execution in Notepad++ before 8.9.6.1 occurs because the <GUIConfig name="commandLineInterpreter"> value in c
An Untrusted search path vulnerability in notepad++ 6.5 allows local users to gain escalated privileges through the msim
Notepad++ is a free and open-source source code editor. Rated high severity (CVSS 7.8), this vulnerability is no authent
Notepad++ versions 8.4.1 and before are vulnerable to DLL hijacking where an attacker can replace the vulnerable dll (Ux
SciLexer.dll in Scintilla in Notepad++ (x64) before 7.7 allows remote code execution or denial of service via Unicode ch
Notepad++ versions before 8.9.2 allow local code execution through an unsafe search path vulnerability that permits atta
Notepad++ v8.4.1 was discovered to contain a stack overflow via the component Finder::add(). Rated medium severity (CVSS
Notepad++ is a free and open-source source code editor. Rated medium severity (CVSS 5.5), this vulnerability is no authe
Notepad++ is a free and open-source source code editor. Rated medium severity (CVSS 5.5), this vulnerability is no authe
Notepad++ is a free and open-source source code editor. Rated medium severity (CVSS 5.5), this vulnerability is no authe
Local OS command injection in Notepad++ before 8.9.6.1 lets an attacker who can write to a user's shortcuts.xml inject a
Same weakness CWE-426 – Untrusted Search Path
View allSame technique Privilege Escalation
View allShare
External POC / Exploit Code
Leaving vuln.today
EUVD-2026-39905