scaffold-hooks
Audited by Socket on Aug 10, 2026
2 alerts found:
Anomalyx2No clear evidence of malware (no exfiltration, cryptomining, credential theft, or persistence) is present in this fragment. The primary security risk is that the code executes repository-derived shell/Python scripts and, critically, executes command strings from generated hooks.json using subprocess with shell=True and sources generated shell libraries via bash -c. If untrusted skill content is ever processed in a sensitive environment, this could enable arbitrary command execution. Treat this as a high-risk test harness pattern rather than proven sabotage.
This Python module itself does not show direct malicious behavior (no embedded payloads, credentials, network activity, or obfuscation). However, it is a high-impact code-execution harness: it scaffolds and then runs/sources bash scripts originating from a caller-provided skill directory, and it parses JSON output from those executed scripts. If the skill/package is untrusted, the supply-chain risk comes from arbitrary side effects performed by the shell scripts contained in that skill, not from this Python logic. Treat the harness as dangerous when applied to untrusted dependencies; sandboxing/allowlisting is recommended.