Accusoft ImageGear IGXMPXMLParser::parseDelimiter stack-based buffer overflow vulnerability
A stack-based buffer overflow exists in the IGXMPXMLParser::parseDelimiter function of Accusoft ImageGear 19.10 when parsing a specially crafted PSD file. An attacker could cause a denial of service or potentially leak one byte of the stack canary, depending on how the library is used.
Originally disclosed on Cisco Talos
A stack-based buffer overflow vulnerability exists in the IGXMPXMLParser::parseDelimiter functionality of Accusoft ImageGear 19.10. A specially-crafted PSD file can overflow a stack buffer, which could either lead to denial of service or, depending on the application, to an information leak.
The full write-up lives on its author's site
It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
How it worked
Root cause
The code fails to account for an extra byte written when a delimiter is present, causing the loop to write one byte beyond the 256-byte buffer.
Impact
The vulnerability could cause a denial of service and, depending on the application, may leak one byte from the stack canary.
What the attacker needed
Victim opens a malicious PSD file; application uses ImageGear library
The fix
The vendor patched the vulnerability in ImageGear Pro v20.0.
How it was found
- Craft a PSD file containing XMP metadata with a tag name longer than 256 characters.
- Load the malformed PSD file using the ImageGear library.
- The parser processes the XMP metadata and overflows the stack buffer, triggering a security check failure.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
A buffer overflow happens when a program writes more data into a fixed-size memory area than it can hold, corrupting nearby data. Here, a malformed image file causes the program to write past a 256-byte buffer on the stack, which can crash the program or leak a small amount of memory. The attacker only needs to provide a malicious file to trigger this.
What is Memory corruption?
Native code reads or writes memory it should not: overflows, use-after-free, type confusion. The core of browser, kernel and parser bugs.