CVE-2023-40164
Notepad++ vulnerability analysis and mitigation

Overview

Notepad++ is a free and open-source source code editor. Versions 8.5.6 and prior are vulnerable to global buffer read overflow in nsCodingStateMachine::NextStater. The vulnerability was discovered and reported by GHSL team member Jaroslav Lobačevski (GitHub Advisory).

Technical details

The vulnerability occurs in the nsCodingStateMachine::NextState function where the array index byteCls depends on the input file content and can exceed the size of the charLenTable buffer. For example, when byteCls is set to 9, it attempts to read beyond the ISO2022JPCharLenTable which contains only 8 elements, resulting in a buffer overflow condition. The vulnerability has been assigned a CVSS 3.1 Base Score of 5.5 MEDIUM (Vector: CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:N/A:N) (NVD).

Impact

The exploitability of this issue is not clear. Potentially, it may be used to leak internal memory allocation information (GitHub Advisory).

Mitigation and workarounds

As of the time of publication, no known patches are available in existing versions of Notepad++ (NVD).

Additional resources


SourceThis report was generated using AI

Related Notepad++ vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

CVE-2023-47452HIGH7.8
  • Notepad++Notepad++
  • cpe:2.3:a:notepad-plus-plus:notepad\+\+
NoYesNov 30, 2023
CVE-2023-6401HIGH7.8
  • Notepad++Notepad++
  • cpe:2.3:a:notepad-plus-plus:notepad\+\+
NoYesNov 30, 2023
CVE-2025-49144HIGH7.3
  • Notepad++Notepad++
  • cpe:2.3:a:notepad-plus-plus:notepad\+\+
NoYesJun 23, 2025
CVE-2023-40166MEDIUM5.5
  • Notepad++Notepad++
  • cpe:2.3:a:notepad-plus-plus:notepad\+\+
NoYesAug 25, 2023
CVE-2023-40164MEDIUM5.5
  • Notepad++Notepad++
  • cpe:2.3:a:notepad-plus-plus:notepad\+\+
NoYesAug 25, 2023

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management