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

JS: Modeling of rimraf functions #19196

Merged
merged 3 commits into from
Apr 3, 2025
Merged

JS: Modeling of rimraf functions #19196

merged 3 commits into from
Apr 3, 2025

Conversation

Napalys
Copy link
Contributor

@Napalys Napalys commented Apr 2, 2025

Added MaD for rimraf functions which were not covered.

@Napalys Napalys marked this pull request as ready for review April 2, 2025 12:26
@Copilot Copilot bot review requested due to automatic review settings April 2, 2025 12:26
@Napalys Napalys requested a review from a team as a code owner April 2, 2025 12:26
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR enhances the modeling of rimraf functions to improve path-injection analysis by adding support for additional methods.

  • Updated tests to include calls to various rimraf methods as sinks.
  • Extended the sink model in the YAML configuration to cover both synchronous and asynchronous rimraf methods.
  • Added change notes documenting the support for additional rimraf methods.

Reviewed Changes

Copilot reviewed 3 out of 4 changed files in this pull request and generated no comments.

File Description
javascript/ql/test/query-tests/Security/CWE-022/TaintedPath/rimraf.js Added tests invoking multiple rimraf methods to simulate potential path-injection sinks.
javascript/ql/lib/ext/rimraf.model.yml Extended modeling definitions to cover new rimraf method variations.
javascript/ql/lib/change-notes/2025-04-02-rimraf.md Added change note highlighting the new support for additional rimraf methods.
Files not reviewed (1)
  • javascript/ql/test/query-tests/Security/CWE-022/TaintedPath/TaintedPath.expected: Language not supported

Tip: If you use Visual Studio Code, you can request a review from Copilot before you push from the "Source Control" tab. Learn more

@Napalys Napalys merged commit 5c42c0b into github:main Apr 3, 2025
14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants