league/commonmark is vulnerable to Cross-Site Scripting (XSS)
61
Medium Risk
The Attributes extension's href and src unsafe-link filter checks each URL against an anchored denylist regex without first normalizing embedded control bytes. Markdown that hides a javascript: scheme with an embedded tab, newline, or leading control character passes the filter unchanged, even when allow_unsafe_links is disabled. Browsers strip those bytes before parsing the scheme, so the crafted link still executes script in a viewer's session. The fix normalizes control characters in the unsafe-link check so obfuscated dangerous schemes are detected and filtered.
You are affected if you are using a version that falls within the vulnerable range and you use the Attributes extension to render untrusted Markdown input.
league/commonmark is vulnerable to Cross-Site Scripting (XSS) in versions 1.5.0 - 2.8.3.
Upgrade the league/commonmark 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.

I consent to receiving marketing communications based on Aikido’s Privacy Policy.
SOC 2Compliant
ISO 27001Compliant