Packages / tough-cookie / Security

HighVulnerabilityGHSA-g7q5-pjjr-gqvpCVE-2017-15010Published 24 Jul 2018

Regular Expression Denial of Service in tough-cookie

Your version

Affected releases · tough-cookie

  • 2.x2.0.0 – 2.3.2Fixed in 2.3.3
  • 1.x and older0.9.0 – 1.2.0No fix, no longer updated

On 2.x, the newest line:

npm install tough-cookie@2.3.3
Every release on a timeline
6.x
  1. Not affected

    6.0.0 – 6.1.0

    4 releases, latest

2.x
  1. Affected

    2.0.0 – 2.3.2

    8 releases

  2. Fixed

    2.3.3 – 2.5.0

    5 releases

1.x
  1. Affected

    1.0.0 – 1.2.0

    3 releases

0.x
  1. Affected

    0.9.0 – 0.13.0

    19 releases

51 stable releases of tough-cookie, oldest to newest, one row per major.

What happens

Affected versions of tough-cookie are susceptible to a regular expression denial of service.

The amplification on this vulnerability is relatively low - it takes around 2 seconds for the engine to execute on a malicious input which is 50,000 characters in length.

If node was compiled using the -DHTTP_MAX_HEADER_SIZE however, the impact of the vulnerability can be significant, as the primary limitation for the vulnerability is the default max HTTP header length in node.

Recommendation

Update to version 2.3.3 or later.

A whole project to check? Paste its package.json in the dependency check: every deprecated, outdated or vulnerable dependency, with what to upgrade to. Free, no account.