A critical Heap-based Buffer Overflow vulnerability exists in the SAML Decode feature of the mimeTools plugin for Notepad++. When handling specially crafted Base64-encoded or DEFLATE-compressed SAML payloads, the plugin fails to enforce proper buffer boundary checks during inflate decompression and raw text copying. An attacker can leverage this vulnerability by tricking a user into decoding a malicious payload via the mimeTools plugin, leading to memory corruption, application crashes, or potential arbitrary code execution.
Vulnerability Type: Heap-based Buffer Overflow ( CWE-122 ), Uncontrolled Resource Consumption / Decompression Bomb ( CWE-409 )
Impact: Critical (Potential Remote Code Execution / Denial of Service)
The SAML Decode pipeline processes input through URL decoding, Base64 decoding, and optional DEFLATE decompression ( tinflate ). The output buffer ( dest ) passed into samlDecode() is allocated with a fixed maximum size defined by SAML_MESSAGE_MAX_SIZE (200,000 bytes).
Multiple vectors allow an attacker to bypass length restrictions and corrupt heap memory:
Unbounded DEFLATE Decompression (Decompression Bomb / Heap Overflow): When decompressing a DEFLATE-compressed SAML payload, tinf_uncompress() in tinflate.c was called without enforcing the maximum capacity of the output buffer ( inflatedText ). A compressed payload expanding to more than 200,000 bytes writes beyond allocated heap boundaries during literal output writes, match copies, or uncompressed block copies.
Unbounded DEFLATE Decompression (Decompression Bomb / Heap Overflow): When decompressing a DEFLATE-compressed SAML payload, tinf_uncompress() in tinflate.c was called without enforcing the maximum capacity of the output buffer ( inflatedText ). A compressed payload expanding to more than 200,000 bytes writes beyond allocated heap boundaries during literal output writes, match copies, or uncompressed block copies.
Plain XML memcpy Buffer Overflow: If a Base64-decoded SAML payload was uncompressed plain text (starting with MIME Tools > SAML Decode.
Notepad++ crashes because samlDecode inflates ~300 000 bytes into a 200 000-byte heap buffer.
Successful exploitation allows an attacker to write arbitrary data past allocated heap boundaries. This can cause immediate software instability, application crash (Denial of Service), or potential execution of arbitrary code within the context of the running application process.
The full story
This article is one source in a clustered incident — the cluster page carries the summary, timeline and every other outlet covering it.
