10.28.2
10 years ago
8 days ago
Known vulnerabilities in the preact package. This does not include vulnerabilities belonging to this package’s dependencies.
Snyk's AI Trust Platform automatically finds the best upgrade path and integrates with your development workflows. Secure your code at zero cost.
Fix for free| Vulnerability | Vulnerable Version |
|---|---|
preact is a fast 3kB alternative to React with the same modern API. Affected versions of this package are vulnerable to Access of Resource Using Incompatible Type ('Type Confusion') during rendering in the vnode constructor. An attacker can inject arbitrary HTML or execute scripts by supplying specially crafted JSON objects that are incorrectly interpreted as valid VNodes when unsanitized, unvalidated user input is passed directly into the render tree. Note: This is only exploitable if applications pass unmodified, unsanitized values from user-modifiable data sources directly into the render tree, assume these values are strings while the data source could return JavaScript objects, and the data source fails to perform type sanitization or is compromised. ##Workaround This vulnerability can be mitigated by validating input types, enforcing strict type contracts at API boundaries, casting or validating network data before rendering, sanitizing external data, and implementing a strict Content Security Policy (CSP) to prevent inline script execution. How to fix Access of Resource Using Incompatible Type ('Type Confusion')? Upgrade | >=10.26.5 <10.26.10>=10.27.0 <10.27.3>=10.28.0 <10.28.2 |