Mocha, a simple, flexible, and fun JavaScript test framework, saw a minor version update from 3.0.1 to 3.0.2 in August 2016. While the core functionality and dependencies remain consistent between the two versions, potential users should be aware of the subtle changes. Both versions share identical dependencies, including tools for diffing, globbing file patterns, debugging, system notifications, JSON handling, directory creation, command-line argument parsing, and browser output management. The development dependencies also are identical, indicating a consistent toolchain for testing and building Mocha itself. These include testing frameworks like Karma, assertion libraries like Should.js and Expect.js, linting tools like ESLint, and utilities for browser testing and code transformation.
The key difference lies in the release date, with version 3.0.2 being released on August 8, 2016, a few days after version 3.0.1 which was released on August 4, 2016. This suggests that version 3.0.2 likely includes bug fixes or minor improvements over its predecessor. While the changelog isn't directly available here, developers should usually consult the official Mocha repository or release notes to understand the specific fixes or enhancements included in version 3.0.2. For new projects, opting for the latest version (3.0.2) is generally recommended to benefit from the most recent fixes. Projects already using Mocha 3.0.1 should evaluate the changelog to determine if upgrading is necessary based on whether the fixes address specific issues they are encountering. Both versions maintain the MIT license, ensuring open-source usage.
All the vulnerabilities related to the version 3.0.2 of the package
Regular Expression Denial of Service (ReDoS)
A vulnerability was found in diff before v3.5.0, the affected versions of this package are vulnerable to Regular Expression Denial of Service (ReDoS) attacks.
debug Inefficient Regular Expression Complexity vulnerability
A vulnerability classified as problematic has been found in debug-js debug up to 3.0.x. This affects the function useColors of the file src/node.js. The manipulation of the argument str leads to inefficient regular expression complexity. Upgrading to version 3.1.0 is able to address this issue. The name of the patch is c38a0166c266a679c8de012d4eaccec3f944e685. It is recommended to upgrade the affected component. The identifier VDB-217665 was assigned to this vulnerability. The patch has been backported to the 2.6.x branch in version 2.6.9.
Regular Expression Denial of Service in debug
Affected versions of debug
are vulnerable to regular expression denial of service when untrusted user input is passed into the o
formatter.
As it takes 50,000 characters to block the event loop for 2 seconds, this issue is a low severity issue.
This was later re-introduced in version v3.2.0, and then repatched in versions 3.2.7 and 4.3.1.
Version 2.x.x: Update to version 2.6.9 or later. Version 3.1.x: Update to version 3.1.0 or later. Version 3.2.x: Update to version 3.2.7 or later. Version 4.x.x: Update to version 4.3.1 or later.
Vercel ms Inefficient Regular Expression Complexity vulnerability
A vulnerability, which was classified as problematic, has been found in vercel ms up to 1.x. This issue affects the function parse of the file index.js. The manipulation of the argument str leads to inefficient regular expression complexity. The attack may be initiated remotely. The exploit has been disclosed to the public and may be used. Upgrading to version 2.0.0 is able to address this issue. The name of the patch is caae2988ba2a37765d055c4eee63d383320ee662. It is recommended to upgrade the affected component. The associated identifier of this vulnerability is VDB-217451.
Growl before 1.10.0 vulnerable to Command Injection
Affected versions of growl
do not properly sanitize input prior to passing it into a shell command, allowing for arbitrary command execution.
Update to version 1.10.0 or later.
Prototype Pollution in minimist
Affected versions of minimist
are vulnerable to prototype pollution. Arguments are not properly sanitized, allowing an attacker to modify the prototype of Object
, causing the addition or modification of an existing property that will exist on all objects.
Parsing the argument --__proto__.y=Polluted
adds a y
property with value Polluted
to all objects. The argument --__proto__=Polluted
raises and uncaught error and crashes the application.
This is exploitable if attackers have control over the arguments being passed to minimist
.
Upgrade to versions 0.2.1, 1.2.3 or later.
Prototype Pollution in minimist
Minimist prior to 1.2.6 and 0.2.4 is vulnerable to Prototype Pollution via file index.js
, function setKey()
(lines 69-95).