Nitro Pro PDF ICCBased ColorSpace Stroke Color Code Execution Vulnerability
A heap-based buffer overflow exists in Nitro Pro when rendering a PDF page that uses an ICCBased colorspace for stroke colour. An attacker could craft a PDF with a large /N value to overflow a fixed-size heap buffer, potentially leading to code execution.
feliz cumpleaños para mi Follow
Originally disclosed on Cisco Talos
An exploitable code execution vulnerability exists in the rendering functionality of Nitro Pro 13.13.2.242 and 13.16.2.300. When drawing the contents of a page and selecting the stroke color from an “ICCBased” colorspace, the application will read a length from the file and use it as a loop sentinel when writing data…
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
Impact
An attacker could cause a heap-based buffer overflow, which may lead to code execution under the context of the application.
What the attacker needed
Victim opens a crafted PDF; Nitro Pro [redacted] or 13.16.2.300
How it was found
- Create a PDF page that sets the stroke colour using an ICCBased colorspace.
- In the ICCBased colorspace dictionary, set the /N key to a value larger than the buffer size.
- Ensure the /Alternate key is present but is not a PDFName, so the component count is not recalculated.
- Open the crafted PDF in Nitro Pro to trigger the overflow.
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 PDF file can describe colours using a colour profile. The program reads a number from the file that says how many colour components there are, and uses that number to decide how many times to write into a fixed-size memory area. If the number is too big, the program writes past the end of that area, corrupting memory and possibly letting an attacker run their own code.
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.