Intel

AIKIDO-2025-10150

canvg is vulnerable to Prototype Pollution

Prototype PollutionCVE-2025-25977 Published Mar 13, 2025

80

High Risk

This Affects:

jscanvg
3.0.0 - 3.0.8
Fixed in 3.0.11
4.0.0 - 4.0.2
Fixed in 4.0.3
Are you affected? Scan for Free

TL;DR

Affected versions of this package are affected by Prototype Pollution in the StyleElement constructor that arises from a design flaw when getting or setting object properties. This vulnerability allows attackers to manipulate the global prototype chain. If the library interacts with sensitive Node.js APIs, an attacker could exploit these rogue properties to inject malicious code, potentially leading to arbitrary code execution.

Who does this affect?

You are affected if you are using a version that falls within the vulnerable range.

Background info

canvg is vulnerable to Prototype Pollution in versions 3.0.0 - 3.0.8 and 4.0.0 - 4.0.2.

How to fix this

Upgrade the canvg library to the patch version.