Conversation
- Add protocol validation to external scanner (block file://, gopher://, etc.) - Add warning when scanning private/reserved IPs (allowed since local testing is a core use case) - Enable TLS certificate validation by default, controllable via insecure option - Replace execSync shell interpolation with execFileSync to prevent shell injection in soul scanner
There was a problem hiding this comment.
Claude Code Review
VERDICT: APPROVE
SUMMARY: This is a documentation-focused PR that updates the README to document new --publish and --registry-url flags for version 0.10.0, along with version bumps in package files. The only code changes are minor improvements to the external scanner: protocol validation, private IP warnings, and fixing an insecure SSL default. After verifying the full source code, no security or correctness issues were introduced.
FINDINGS:
None. All potential security concerns were adequately mitigated:
-
Protocol validation (lines 73-82 in external-scanner.ts): Blocks dangerous protocols like
file://,gopher://, allowing onlyhttp://andhttps://. This prevents SSRF via protocol smuggling. -
Private IP scanning (lines 61-72, 89-94): Detects RFC 1918 ranges and cloud metadata endpoints (169.254.169.254), logs a warning, but allows scanning to proceed — correct for a security scanner's legitimate use case.
-
SSL certificate validation (line 318 in external-scanner.ts): The fix corrects inverted logic from the previous code (
rejectUnauthorized: falsehardcoded). Now properly respects theinsecureflag with correct boolean logic (rejectUnauthorized: !insecure), defaulting to secure (rejecting unauthorized certs). -
Command injection mitigation (lines 562-564 in soul/scanner.ts): Replaced shell-interpolated
execSyncwithexecFileSyncusing array arguments, eliminating shell injection risk when passing the prompt to theclaudeCLI.
All changes pass the verification mandate — mitigations are present in the same code paths where vulnerabilities could have existed.
Reviewed 7 files changed (10577 bytes)
Summary
--publishflag onsecure,attack, andscan-soulcommands--registry-urlcustom endpoint option to examplesTest plan