marked@0.3.7 vulnerabilities

A markdown parser built for speed

  • latest version

    16.0.0

  • latest non vulnerable version

  • first published

    13 years ago

  • latest version published

    14 days ago

  • licenses detected

  • Direct Vulnerabilities

    Known vulnerabilities in the marked package. This does not include vulnerabilities belonging to this package’s dependencies.

    How to fix?

    Automatically find and fix vulnerabilities affecting your projects. Snyk scans for vulnerabilities and provides fixes for free.

    Fix for free
    VulnerabilityVulnerable Version
    • M
    Regular Expression Denial of Service (ReDoS)

    marked is a low-level compiler for parsing markdown without caching or blocking for long periods of time.

    Affected versions of this package are vulnerable to Regular Expression Denial of Service (ReDoS) when unsanitized user input is passed to block.def.

    How to fix Regular Expression Denial of Service (ReDoS)?

    Upgrade marked to version 4.0.10 or higher.

    <4.0.10
    • M
    Regular Expression Denial of Service (ReDoS)

    marked is a low-level compiler for parsing markdown without caching or blocking for long periods of time.

    Affected versions of this package are vulnerable to Regular Expression Denial of Service (ReDoS) when passing unsanitized user input to inline.reflinkSearch, if it is not being parsed by a time-limited worker thread.

    How to fix Regular Expression Denial of Service (ReDoS)?

    Upgrade marked to version 4.0.10 or higher.

    <4.0.10
    • M
    Regular Expression Denial of Service (ReDoS)

    marked is a low-level compiler for parsing markdown without caching or blocking for long periods of time.

    Affected versions of this package are vulnerable to Regular Expression Denial of Service (ReDoS). The em regex within src/rules.js file have multiple unused capture groups which could lead to a denial of service attack if user input is reachable.

    How to fix Regular Expression Denial of Service (ReDoS)?

    Upgrade marked to version 1.1.1 or higher.

    <1.1.1
    • M
    Regular Expression Denial of Service (ReDoS)

    marked is a low-level compiler for parsing markdown without caching or blocking for long periods of time.

    Affected versions of this package are vulnerable to Regular Expression Denial of Service (ReDoS). A Denial of Service condition could be triggered through exploitation of the heading regex.

    How to fix Regular Expression Denial of Service (ReDoS)?

    Upgrade marked to version 0.4.0 or higher.

    <0.4.0
    • M
    Regular Expression Denial of Service (ReDoS)

    marked is a low-level compiler for parsing markdown without caching or blocking for long periods of time.

    Affected versions of this package are vulnerable to Regular Expression Denial of Service (ReDoS). The inline.text regex may take quadratic time to scan for potential email addresses starting at every point.

    How to fix Regular Expression Denial of Service (ReDoS)?

    Upgrade marked to version 0.6.2 or higher.

    >=0.1.3 <0.6.2
    • H
    Regular Expression Denial of Service (ReDoS)

    marked is a low-level compiler for parsing markdown without caching or blocking for long periods of time.

    Affected versions of this package are vulnerable to Regular Expression Denial of Service (ReDoS). This can cause an impact of about 10 seconds matching time for data 150 characters long.

    How to fix Regular Expression Denial of Service (ReDoS)?

    Upgrade marked to version 0.3.18 or higher.

    <0.3.18
    • H
    Cross-site Scripting (XSS)

    marked is a low-level compiler for parsing markdown without caching or blocking for long periods of time.

    Affected versions of this package are vulnerable to Cross-site Scripting (XSS). Browsers support both lowercase and uppercase x in hexadecimal form of HTML character entity, but marked unescaped only lowercase.

    This may allow an attacker to create a link with javascript code.

    For example:

    var marked = require('marked');
    marked.setOptions({
      renderer: new marked.Renderer(),
      sanitize: true
    });
    
    text = `
    lower[click me](javascript&#x3a;...)lower
    upper[click me](javascript&#X3a;...)upper
    `;
    
    console.log(marked(text));
    

    will render the following:

    <p>lowerlower
    upper<a href="javascript&#X3a;...">click me</a>upper</p>
    

    How to fix Cross-site Scripting (XSS)?

    Upgrade marked to version 0.3.9 or higher.

    <0.3.9
    • M
    Cross-site Scripting (XSS)

    marked is a low-level compiler for parsing markdown without caching or blocking for long periods of time.

    Affected versions of this package are vulnerable to Cross-site Scripting (XSS). When mangling is disabled via option mangle, marked doesn't escape target href. This may allow an attacker to inject arbitrary html-event into resulting a tag.

    For example:

    var marked = require('marked');
    marked.setOptions({
      renderer: new marked.Renderer(),
      sanitize: true,
      mangle: false
    });
    
    text = `
    <bar"onclick="alert('XSS')"@foo>
    `;
    
    console.log(marked(text));
    

    will render:

    <p><a href="mailto:bar"onclick="alert('XSS')"@foo">bar"onclick="alert('XSS')"@foo</a></p>
    

    How to fix Cross-site Scripting (XSS)?

    Upgrade marked to version 0.3.9 or higher.

    <0.3.9
    • H
    Regular Expression Denial of Service (ReDoS)

    marked is a low-level compiler for parsing markdown without caching or blocking for long periods of time.

    Affected versions of this package are vulnerable to Regular Expression Denial of Service (ReDoS) when parsing the input markdown content (1,000 characters costs around 6 seconds matching time).

    How to fix Regular Expression Denial of Service (ReDoS)?

    Upgrade marked to version 0.3.9 or higher.

    <0.3.9