security-review
Skill73 starsChanged 49 days agoMITView on GitHub
Comprehensive security review for Termote. Use when reviewing PRs, auditing code, or before releases. Covers auth bypass, request guards (Host/Origin/Content-Type), terminal WebSocket stream, child-process lifetime, command/argument injection (tmux, psmux, herdr), the Go CLI (install layout, saved config, update, service registration, process kill) and container setup.
190 other projects use a version of this.
Adopted by
Most recently taken up by
- Badhon-00/MDCPtheir own version, first seen Nov 16, 2026
- FAHTHIZ/oasistheir own version, first seen Nov 16, 2026
- metacircu1ar/hive_skillstheir own version, first seen Nov 15, 2026
- rschuft/ai-frontend-skill-packstheir own version, first seen Nov 15, 2026
- 81wallace18/codex-skillstheir own version, first seen Nov 15, 2026
- FimawLLC/fimaw-skillstheir own version, first seen Nov 15, 2026
Used with
Projects with it also use dependency-cve-sweep, fleet-standard-adoption and 10 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
berntpoppSkilldependency-cve-sweep
Use when handling Dependabot PRs, CodeQL/Trivy alerts, or doing a routine dependency/CVE sweep for this repo.
Also in 12 projects that use this
berntpoppSkillfleet-standard-adoption
Use when bringing this repo into compliance with a GeneFoundry fleet standard (tool-naming, response-envelope, container-hardening, versioning, MCP transport, or logging) or closing its tracking issue.
Also in 12 projects that use this
xfstudioSkilllinkerd-patterns
Implement Linkerd service mesh patterns for lightweight, security-focused service mesh deployments. Use when setting up Linkerd, configuring traffic policies, or implementing zero-trust networking with minimal overhead.
Also in 6 projects that use this
xfstudioSkillteam-composition-analysis
This skill should be used when the user asks to "plan team
Also in 5 projects that use this
HABUBUSSSkillproject-guidelines-example
Also in 16 projects that use this
niloykumarbarmanSkillagent-sort
Build an evidence-backed ECC install plan for a specific repo by sorting skills, commands, rules, hooks, and extras into DAILY vs LIBRARY buckets using parallel repo-aware review passes. Use when ECC should be trimmed to what a project actually needs instead of loading the full bundle.
Also in 13 projects that use this
- +2 more from berntpopp
Other versions190 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 190
- affaan-m/ECC★ 246ksame name
- github/awesome-copilot★ 41ksame name
- langfuse/langfuse★ 37ksame name
- nearai/ironclaw★ 13ksame name
- joe-bell/cva★ 6.9ksame name
- doorkeeper-gem/doorkeeper★ 5.5ksame name
- github/squad★ 3.4ksame name
- compozy/compozy★ 2.9ksame name
- trycompai/comp★ 2.1ksame name
- xu-xiang/everything-claude-code-zh★ 1.9ksame name
180 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository3 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- website/llms-full.txtllms.txt
- website/llms.txtllms.txt
The file
We split this skill into the rules it gives an agent
8 rules. 0 are common, 4 are distinctive, and 4 are very specific to this project.
0
Common
Most of the 162 edited versions we read keep these.
4
Distinctive
This author's own choices. Worth a look.
4
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 43
When a saved config exists (server/serve_config.go), termote serve reads it and ignores every TERMOTE_* variable.
- Distinctive: line 52
No credentials in logs, error responses or child-process environments
- Very specific: line 60
No user input reaches exec.Command without validation.
- Distinctive: line 103
No world-writable sensitive files (/etc/passwd, /etc/group)
- Distinctive: line 104
No secrets in image layers.
- Distinctive: line 155
If the user asks to fix issues, apply changes directly.
- Very specific: line 158
Run go build to verify (for Go changes)
- Very specific: line 159
Run go test to verify tests pass
“Common” is measured: kept by at least 6 in 10 of the 162 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Termote Security Review
Review Termote for security vulnerabilities, tailored to its 1.0 architecture: one Go binary (termote) that is both the server (PWA + /api/mux/* + terminal WebSocket stream + auth) and the CLI (termote start/container up/update/...), a React PWA, an online installer (scripts/install.sh/install.ps1) plus a checkout-only dev shim (scripts/termote.sh/termote.ps1), and a Docker image. There is no install command, no ttyd and no /terminal/ iframe any more: the server runs the terminal itself on a PTY (Unix) or ConPTY (Windows) and streams it over /api/mux/stream. Backends: tmux (psmux on Windows) and herdr (Unix only, via its socket and CLI).
Arguments
--full: Scan entire codebase (default if no unstaged changes)--diff-only: Only review changed files--focus <area>: Focus on specific area (auth, api, stream, herdr, cli, docker, shell)
Current arguments: $ARGUMENTS
Step 1: Determine Scope
If --diff-only or there are uncommitted/staged changes:
Run git diff + git diff --cached to get changed files
If --full or clean tree:
Scan all key files
If --focus specified:
Filter to relevant files onlyFor a release review, diff against the previous tag:
git diff <prev-tag>..HEAD -- server pwa/src scripts Dockerfile entrypoint.sh docker-compose.yml.
Step 2: Review by Area
Launch parallel review agents for each relevant area. Pass the diff or file contents to each agent.
Area: Auth & Request Guards (server/serve.go, server/guard.go)
Check against checklist.md:
- Basic auth on ALL routes except the PWA public paths (manifest,
sw.js,workbox-*.js) - When a saved config exists (
server/serve_config.go),termote servereads it and ignores everyTERMOTE_*variable; only without one (container, manual run) doesvalidateConfig/the environment apply — empty password withoutTERMOTE_NO_AUTH=truerefuses to start either way - herdr with auth off needs
TERMOTE_HERDR_ALLOW_NO_AUTH=true(--allow-herdr-no-auth) - Host allowlist (
hostGuard,TERMOTE_ALLOWED_HOSTS) on every request (DNS rebinding); no wildcard - Cross-site writes rejected (
writeGuard):Sec-Fetch-Site,Originin the allowlist, JSON-onlyContent-Typeon every non-GET/api/method - Rate limiting on auth failures; constant-time password comparison
- Session cookie:
HttpOnly,SameSite=Strict,Securewhen HTTPS; bounded store - No credentials in logs, error responses or child-process environments
Area: API & Command Injection (server/mux.go, server/mux_tmux.go, server/mux_herdr.go)
Check against checklist.md:
- tmux targets validated with
validTmuxID(no ':' → no other session, no leading '-' → no flag injection) and qualified server-side - herdr IDs match
herdrWorkspaceIDRe/herdrTabIDRe/herdrPaneIDReand must exist in the current snapshot - No user input reaches
exec.Commandwithout validation; herdr socket calls go throughjson.Marshal - Body size limit (8KB) and keys length limit (4096) on writes
- Method enforcement on every handler; wrong method → JSON 405
- Error responses generic (
mux command failed); onlyinputErrortext is echoed
Area: Terminal Stream (server/stream.go, server/pty_*.go, server/herdr_stream.go)
Check against checklist.md:
/api/mux/streamrequires auth + Host allowlist +Sec-Fetch-Site/Origincheck + single-use 30s token- Size limits:
cols/rowsclamped to [1, 500], 64 KiB client messages, at most 8 streams, 32 live tokens - Keepalive and write timeouts; no URL (token) logging
- Closing a stream, SIGTERM and a hard kill of the server all end the whole child process tree (process group /
Pdeathsig/ Job Object); orphan reaping never matches unrelated processes
Area: Herdr Backend (server/herdr_rpc.go, server/mux_herdr.go, server/herdr_stream.go)
Check against checklist.md:
- Socket JSON-RPC: one request per connection, request < 1 MiB, reply bounded, deadlines from ctx
herdr terminal session observe <pane>argv built from a validated pane ID and integer sizes only- NDJSON frames decoded defensively (bad lines skipped, never executed or echoed)
- Input queue bounded per pane; writes ordered
Area: Go CLI (server/cli*.go, server/install_layout.go, server/tailscale.go)
Check against checklist.md:
- Config file 0600 (Unix) / owner-only ACL (Windows), atomic write; password AES-256-CBC with an
HMAC keyed by a random per-install
secretfile (0600) on Unix, DPAPI on Windows - The password never ends up in the systemd unit, launchd plist, Scheduled Task or any process
command line (container: passed as
-e NAMEfrom the CLI's own environment, not a file) update: version regex, HTTPS download, sha256 check (mandatory), tar extraction refuses escaping paths, symlinks and backslashes; the versioned install layout (install_layout.go) switchescurrentatomically and never partially removes a version- External commands (
tailscale serve— never withsudo,offneverreset—podman/docker run,powershell -EncodedCommand,netsh) get only validated values as separate argv entries - Process matching before kill: exact command line / image path, PID file cross-checked; never kill unrelated processes
Area: Docker & Container (Dockerfile, entrypoint.sh, docker-compose.yml)
Check against checklist.md:
- Base image pinned by digest;
tinias PID 1 - No world-writable sensitive files (/etc/passwd, /etc/group)
- No secrets in image layers; minimal installed packages
- Port published on 127.0.0.1 unless
--lan; password and allowed hosts passed as-e NAMEvalues from the CLI's own environment, never an env file or a command-line argument - Runs as
--user <uid>:<gid>(rootless podman:--userns=keep-id; rootless Docker: no--user); the workspace is mounted with--mount, not-v - Sensitive host dirs excluded from mounts (.ssh, .gnupg, .aws)
Area: Shell Scripts (scripts/install.sh, scripts/install.ps1, scripts/termote.sh, scripts/termote.ps1)
Check against checklist.md:
install.sh/install.ps1(release installers): version validated, HTTPS download,.sha256checksum verification mandatory (no way to skip it), never start the server themselvestermote.sh/termote.ps1(checkout-only dev shims): only resolve/build thetermote-devbinary andexecit; no logic that handles secrets- Variables quoted; no
evalor sourcing of the saved config file
Step 3: Report
Output a structured report:
## Security Review Report
### Summary
- Scope: [full / diff-only / focused]
- Files reviewed: N
- Issues: X critical, Y high, Z medium, W low
### Critical / High (must fix)
| # | Area | File:Line | Issue | Exploit path | Recommendation |
### Medium (should fix)
| # | Area | File:Line | Issue | Exploit path | Recommendation |
### Low / Informational
| # | Area | File:Line | Issue | Recommendation |
### Passed Checks
- [list of areas that passed cleanly]Known, accepted decisions (do not re-raise as findings):
requestIsHTTPStrustsX-Forwarded-Protofrom any source (only affects that client's own cookie)- Container running as root is out of scope (rejected hardening scope) — note
container upotherwise runs as--user <uid>:<gid>(rootless podman:--userns=keep-id; rootless Docker: no--user)
Step 4: Fix (if requested)
If the user asks to fix issues, apply changes directly. For each fix:
- Edit the source file
- Run
go buildto verify (for Go changes) - Run
go testto verify tests pass
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

