ast-grep is vulnerable to Inclusion of Functionality from Untrusted Control Sphere
80
CVE Score
High
Inclusion of Functionality from Untrusted Control Sphere
The ast-grep CLI reads a project's sgconfig.yml during setup_project_is_possible(), unconditionally loaded native custom-language shared libraries declared under custom_languages in that config. Default usage of the CLI against a project directory containing an sgconfig.yml with a custom_languages entry caused the native library path to be loaded and registered with no opt-in or warning. The fix, shipped in 0.50.0, adds an --allow-custom-languages CLI flag and makes register_custom_language() return a thrown CustomLanguageNotAllowed error unless that flag is passed or no custom languages are configured.
Upgrade the ast-grep package to version 0.50.0 or later.
You are affected if you are using a version that falls within the vulnerable range and are running the CLI against a project whose configuration declares custom language libraries.
0.5.0 - 0.45.3
Fixed in 0.50.0ast-grep is vulnerable to Inclusion of Functionality from Untrusted Control Sphere in versions 0.5.0 - 0.45.3.
Secure your code, cloud, and runtime in one central system. Connect a repo to discover what the reasoning agents find in your codebase.
No credit card required | Scan results in 32 seconds.
I consent to receiving marketing communications based on Aikido’s Privacy Policy.
SOC 2Compliant
ISO 27001Compliant
ISO 42001Compliant© All Intel data is openly available and commercially licensed.