pdfjs is vulnerable to Infinite Loop
47
Medium Risk
Affected versions of this package are vulnerable to an infinite loop when processing a corrupted PDF file containing malformed arrays. The lexer fails to properly handle cases where the array terminator ] is missing, causing it to loop indefinitely after exceeding the buffer length without triggering an error. An attacker could exploit this vulnerability by crafting a malicious PDF to induce a denial-of-service (DoS) condition, consuming excessive CPU resources. This exploit occurs because the lexer continues searching for the terminator even after the buffer bounds have been exceeded.
You are affected if you are using a version that falls within the vulnerable range.
pdfjs is vulnerable to Infinite Loop in versions 2.0.0 - 2.5.3.
Upgrade the pdfjs library to the patch version.
Connect your repositories to instantly see whether vulnerable or malicious packages exist in your codebase.
Free. No credit card required.

SOC 2Compliant
ISO 27001Compliant