typescript-expert
Pass
Audited by Gen Agent Trust Hub on Feb 17, 2026
Risk Level: SAFECOMMAND_EXECUTIONEXTERNAL_DOWNLOADS
Full Analysis
- [COMMAND_EXECUTION] (LOW): The script
scripts/ts_diagnostic.pyutilizessubprocess.run(cmd, shell=True)to perform project analysis. - Evidence: Multiple calls to
run_cmdexecute commands likenpx tsc,node, andgrep. Usingshell=Trueis a security anti-pattern that can be vulnerable to environment-based command injection if the environment variables or local file names are manipulated. - [EXTERNAL_DOWNLOADS] (LOW): The script relies on
npxto execute the TypeScript compiler. - Evidence:
run_cmd("npx tsc --version"). If thetypescriptpackage is missing in the local environment,npxwill attempt to download it from the npm registry at runtime, introducing a remote dependency fetch. - [INDIRECT_PROMPT_INJECTION] (LOW): The diagnostic script processes data from external, potentially untrusted sources (project files) and outputs them to the agent console.
- Ingestion points:
package.json,tsconfig.json, and source files in thesrc/directory viagrepandjson.load. - Boundary markers: Absent. The script prints raw tool output and file contents directly to stdout.
- Capability inventory:
subprocess.run(shell execution), file system read access. - Sanitization: None. The script does not escape or validate the content of the files it reads before displaying them to the agent, which could allow an attacker to embed malicious instructions in a
package.jsondescription or source code comment.
Audit Metadata