Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

jsonpath-plus Critical RCE in 4.0.0, need an update to 10.0.0 to fix it. #4966

Closed
Yokai1000 opened this issue Oct 11, 2024 · 4 comments · Fixed by #4981
Closed

jsonpath-plus Critical RCE in 4.0.0, need an update to 10.0.0 to fix it. #4966

Yokai1000 opened this issue Oct 11, 2024 · 4 comments · Fixed by #4981

Comments

@Yokai1000
Copy link

Yokai1000 commented Oct 11, 2024

Description:

Affected versions of this package are vulnerable to Remote Code Execution (RCE) due to improper input sanitization. An attacker can execute aribitrary code on the system by exploiting the unsafe default usage of vm in Node.

This package is present in @rushstack/heft-config-file package.json

Note:

The unsafe behavior is still available after applying the fix but it is not turned on by default.

# Path: index.js
const { JSONPath } = require("jsonpath-plus");

const data = {};

let x = JSONPath({
    json: data,
    path: "$[(this.constructor.constructor("require(\"child_process\").exec(\"cat /etc/passwd\")")())]"
});
@dengkunli
Copy link

Reference: CVE-2024-21534

It's been 2 weeks with no response ? Rush team plz fix it asap

@iclanton iclanton moved this from Needs triage to High priority in Bug Triage Oct 23, 2024
@github-project-automation github-project-automation bot moved this from High priority to Closed in Bug Triage Oct 23, 2024
@Mino-Chen-Sap
Copy link

Hello @iclanton , could I know when you will release the fix? I checked that in the latest version 5.140.0, this fix is not in it.

@iclanton
Copy link
Member

It'll be in the next release of Rush. I can probably put out a patch today or tomorrow.

@iclanton
Copy link
Member

5.140.1 is out with this change.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

4 participants