Python-free launcher + robust Windows Docker detection - #8
Open
kendrixjw wants to merge 2 commits into
Open
Conversation
- ht.sh: run scripts via host Python, or bootstrap in a container (Python + Docker CLI, host socket mounted) when none is present - ht_env.py: probe daemon with `docker version` (fixes Windows Docker Desktop false-negative); add HT_FORCE_HOST/HT_FORCE_DOCKER - ht_run.py: honor HT_HOST_CWD so local-file tools work under the container bootstrap - SKILL.md: drive all scripts through `sh ht.sh <name>` Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
ht.sh runs under /bin/sh (including inside the bootstrap container); a CRLF checkout on Windows would break the interpreter line. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Makes the pentest skill turnkey on Windows hosts that have Docker but no Python (and hardens Docker detection generally). Previously, preflight required a host Python interpreter to run and misreported a working Docker Desktop as unavailable, leaving the skill
blockedon an otherwise capable machine.Changes
scripts/ht.sh(new) — Python-free launcher. Runs theht_*.pyscripts with the host's Python when a real interpreter is present (rejects the Windows Store execution-alias stub by actually executing it). When none exists, it bootstraps them inside a small cached container (Python + Docker CLI) with the host Docker socket mounted, so tool containers are still launched by the host daemon. Invoke any script assh ht.sh <name> [args].scripts/ht_env.py— probe the daemon withdocker versioninstead ofdocker info(lighter, still daemon-confirming) and raise the timeout 5s→15s, fixing a Windows Docker Desktop false-negative that collapsed the backend tofallback. AddedHT_FORCE_HOST/HT_FORCE_DOCKERoverrides so detection stays correct when bootstrapped in a container.scripts/ht_run.py— honorHT_HOST_CWDas the Docker volume source, so local-file tools (trufflehog, ffuf wordlists, …) still see host files under the container bootstrap (avoids the Docker-in-Docker path trap).skills/pentest/SKILL.md— drive all scripts throughsh ht.sh <name>..gitattributes(new) — pin*.shto LF so the launcher isn't broken by a CRLF checkout on Windows.Verification (Windows + Docker Desktop, no host Python)
sh ht.sh preflight→verdict: ready,host: windows,backend: dockersh ht.sh run … httpx -u example.com→status: oksh ht.sh run … trufflehog filesystem /work→ scanned a planted host file (provesHT_HOST_CWDdelivers local files into tool containers)sh ht.sh search --q nmap→ clean JSONNote
The bootstrap path mounts the host Docker socket into the launcher container — standard for this tooling, but worth calling out as host-level daemon access.
🤖 Generated with Claude Code