CVE-2026-86054

Notepad++: Stack Buffer Overflow in `NppParameters::writeSession` via overlong session path

Published Sep 22, 2026 CVSS 3.1 · 7.8 High EPSS < 1% KEV · Not listed
Description
Notepad++ is a free and open-source source code editor. Prior to 8.9.8, Notepad++ contains a stack buffer overflow in NppParameters::writeSession in PowerEditor/src/Parameters.cpp because it copies a session path derived from -settingsDir= into backupPathName[MAX_PATH] with unbounded wcscpy and appends SESSION_BACKUP_EXT with unbounded wcscat. A sufficiently long settings directory causes the backup suffix to exceed the fixed stack buffer when Notepad++ saves the session, and the protected release build terminates through its stack canary, causing denial of service. This issue is fixed in version 8.9.8.

Analysis

AI-generated

Technical impact

A buffer overflow occurs in the NppParameters::writeSession routine when a session is saved. The code copies the settings directory path – supplied via the -settingsDir option – into a fixed‑size buffer without bounds checking, then concatenates a backup suffix. If the directory name is long enough, the concatenation overruns the stack buffer, triggering the stack canary and causing the protected release build to terminate. The vulnerability therefore results in an application crash and interruption of service, but it does not grant code execution.

Affected Systems

Notepad++ versions earlier than 8.9.8 on Windows are affected. The vulnerability is present in the source code referenced in the official GitHub repository and fixed in the 8.9.8 release; any installation using an older version and a long settings directory path is at risk.

Risk and Exploitability

The CVSS score of 7.8 indicates a high severity, reflecting the significant loss of availability and the lack of mitigation in the affected builds. No EPSS score is available, so the exploitation probability cannot be quantified. The vulnerability is not listed in the CISA Known Exploited Vulnerabilities catalog, and no public exploits have been reported. Likely attack conditions require a local user or a process with access to Notepad++ to trigger the overflow by saving a session after configuring an overlong settings directory path. No remote trigger or privilege escalation is required. Given the lack of a remote exploit vector and the existing stack canary, the risk is confined to local denial of service on the affected system.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Update Notepad++ to version 8.9.8 or later to receive the fix that addresses the unbounded string operations.
  • If an upgrade is not immediately possible, shorten the path used for the settings directory or avoid using the -settingsDir option with an excessively long value.
  • Stop using the session‑save feature until the patch is applied to prevent accidental application crashes caused by the overflow.

Generated by OpenCVE AI on September 22, 2026 at 18:38 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories available
History
Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'poc', 'Technical Impact': 'total'}, 'version': '2.0.3'}

Type Values Removed Values Added
First Time appeared Notepad-plus-plus
Notepad-plus-plus notepad++
Vendors & Products Notepad-plus-plus
Notepad-plus-plus notepad++
Type Values Removed Values Added
Description Notepad++ is a free and open-source source code editor. Prior to 8.9.8, Notepad++ contains a stack buffer overflow in NppParameters::writeSession in PowerEditor/src/Parameters.cpp because it copies a session path derived from -settingsDir= into backupPathName[MAX_PATH] with unbounded wcscpy and appends SESSION_BACKUP_EXT with unbounded wcscat. A sufficiently long settings directory causes the backup suffix to exceed the fixed stack buffer when Notepad++ saves the session, and the protected release build terminates through its stack canary, causing denial of service. This issue is fixed in version 8.9.8.
Title Notepad++: Stack Buffer Overflow in `NppParameters::writeSession` via overlong session path
Weaknesses CWE-121
References
Metrics cvssV3_1

{'score': 7.8, 'vector': 'CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H'}

Weaknesses
  • CWE-121

    Stack-based Buffer Overflow

Sources

Status
PUBLISHED
Assigner
GitHub_M
Published
Updated
Sep 28, 2026, 5:36 PM
Reserved
Sep 4, 2026, 7:29 PM
Status
Awaiting Analysis
Published
Sep 22, 2026, 6:17 PM
Modified
Sep 28, 2026, 6:17 PM