mocha@0.0.1-alpha3 vulnerabilities

simple, flexible, fun test framework

Direct Vulnerabilities

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

Automatically find and fix vulnerabilities affecting your projects. Snyk scans for vulnerabilities and provides fixes for free.
Fix for free
Vulnerability Vulnerable Version
  • H
Regular Expression Denial of Service (ReDoS)

mocha is a javascript test framework for node.js & the browser.

Affected versions of this package are vulnerable to Regular Expression Denial of Service (ReDoS) in the clean function in utils.js.

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

Upgrade mocha to version 10.1.0 or higher.

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

mocha is a javascript test framework for node.js & the browser.

Affected versions of this package are vulnerable to Regular Expression Denial of Service (ReDoS). If the stack trace in utils.js begins with a large error message (>= 20k characters), and full-trace is not undisabled, utils.stackTraceFilter() will take exponential time to run.

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

Upgrade mocha to version 6.0.0 or higher.

<6.0.0