markdown-it-prism@2.1.1 vulnerabilities

Highlights code blocks in markdown-it using Prism.

  • latest version

    3.0.0

  • latest non vulnerable version

  • first published

    9 years ago

  • latest version published

    7 months ago

  • licenses detected

  • Direct Vulnerabilities

    Known vulnerabilities in the markdown-it-prism package. This does not include vulnerabilities belonging to this package’s dependencies.

    Fix vulnerabilities automatically

    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
    VulnerabilityVulnerable Version
    • M
    Cross-site Scripting (XSS)

    markdown-it-prism is a The plugin will insert the necessary markup into all code blocks. Include one of Prism’s stylesheets in your HTML to get highlighted code.

    Affected versions of this package are vulnerable to Cross-site Scripting (XSS). It is possible to insert malicious JavaScript as markup to the package which will be returned unsanitised.

    PoC

    public class Foo() {
        public Foo(bar) {
            System.out.println(bar);
        }
    }
    

    How to fix Cross-site Scripting (XSS)?

    Upgrade markdown-it-prism to version 2.1.3 or higher.

    <2.1.3