GHSA-95rp-6gqp-6622

Suggest an improvement
Source
https://github.com/advisories/GHSA-95rp-6gqp-6622
Import Source
https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2023/08/GHSA-95rp-6gqp-6622/GHSA-95rp-6gqp-6622.json
JSON Data
https://api.osv.dev/v1/vulns/GHSA-95rp-6gqp-6622
Aliases
Related
Published
2023-08-30T20:08:58Z
Modified
2023-11-08T04:13:22.108597Z
Severity
  • 9.8 (Critical) CVSS_V3 - CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H CVSS Calculator
Summary
Command Injection Vulnerability in find-exec
Details

Older versions of the package are vulnerable to Command Injection as an attacker controlled parameter. As a result, attackers may run malicious commands.

For example:

const find = require("find-exec");
find("mplayer; touch hacked")

This creates a file named "hacked" on the filesystem.

You should never allow users to control commands to find, since this package attempts to run every command provided.

Thanks to @miguelafmonteiro for reporting.

Database specific
{
    "github_reviewed_at": "2023-08-30T20:08:58Z",
    "cwe_ids": [
        "CWE-78"
    ],
    "nvd_published_at": "2023-08-30T18:15:09Z",
    "severity": "CRITICAL",
    "github_reviewed": true
}
References

Affected packages

npm / find-exec

Package

Affected ranges

Type
SEMVER
Events
Introduced
0Unknown introduced version / All previous versions are affected
Fixed
1.0.3