security-scan

Warn

Audited by Gen Agent Trust Hub on Jul 15, 2026

Risk Level: MEDIUMCOMMAND_EXECUTIONDATA_EXFILTRATION
Full Analysis
  • [COMMAND_EXECUTION]: The script scripts/scan.mjs executes shell commands via execSync to perform scans. In the scanDependencies function, it constructs a command using keys (package names) from the package.json of the codebase being scanned.
  • Evidence: .github/skills/security-scan/scripts/scan.mjs: const timeRaw = run(npm view "${name}@${version}" time --json 2>/dev/null, 10_000).trim()
  • [COMMAND_EXECUTION]: The package names (name) extracted from the dependencies list in package.json are not sanitized before being interpolated into the shell command string. An attacker could craft a package.json with a malicious package name containing shell metacharacters (e.g., ;, &, or backticks) to execute arbitrary commands on the host system when the scan is run on untrusted code.
  • [DATA_EXFILTRATION]: The scanDependencies function performs network requests to the public npm registry using the npm view command for every dependency found in the project. This transmits project metadata (dependency names and versions) to an external service.
Audit Metadata
Risk Level
MEDIUM
Analyzed
Jul 15, 2026, 01:07 AM
Security Audit — agent-trust-hub — security-scan