Notepad-plus-plus
Notepad++: Stack Buffer Overflow in `NppParameters::writeSession` via overlong session path
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.
Affected versions and mitigation
From the CVE record and the vendor's references.Affected
- < 8.9.8
Fixed in 8.9.8
Mitigation
Upgrade notepad-plus-plus to 8.9.8 or later.
References
- Vendor advisory github.com/notepad-plus-plus/notepad-plus-plus…
- Patch github.com/notepad-plus-plus/notepad-plus-plus…
- Release notes github.com/notepad-plus-plus/notepad-plus-plus…
Timeline
Days relative to CVE publicationNo public PoC found yet; not in CISA KEV.
PoC repositories
Found on GitHub.No PoC repositories found yet.