Executive summary
juanfont/headscale scores 58 out of 100 and is rated Adequate, while four of its five lenses score higher still: Code Health at 85 and Performance at 80, both rated Strong, and Maturity at 63 and Security and Compliance at 60, both rated Adequate. The project hasn't declared a stable release yet, so its lenses are rated against a lower bar than a released product's, while the score itself is worked out as for any repository.
The score is lower than those four because the weakest lens counts most, and here that is Production Readiness, which scores 50 and is rated Adequate. Its Outbound HTTP resilience dimension scores 3 out of 10, and until that reaches 4, Production Readiness can't be rated higher than Adequate. The first actions are to resolve the 1 No ADRs found finding(s) in ADR Quality and to resolve the 1 Off-boarding risk finding(s) in Bus Factor, and if Production Readiness rose to 70, the score would rise from 58 to about 65.
18 findings are critical: nine in Static Analysis (SAST), six in IaC & Container Security and three in Dependency Vulnerabilities.
Watchdog couldn't measure 37 dimensions in this code, among them Cyclomatic Complexity, Cognitive Complexity and Code Duplication, so they are left out of the score. The product code is 54,075 lines, which would take an estimated 1.1 person-years, around €170,000, to rebuild.
If Production Readiness rose from 50 to 70, the lowest score rated Strong, the score would rise from 58 to about 65.
New since the last survey: 18 findings
- Explicit Debt · TodoComment hscontrol/servertest/ephemeral_test.go
- Static Analysis (SAST) · REDACTED
- Static Analysis (SAST) · REDACTED
- Supply-chain Provenance & Signing · REDACTED
- Supply-chain Provenance & Signing · REDACTED
- Supply-chain Provenance & Signing · REDACTED
- Supply-chain Provenance & Signing · REDACTED
- Supply-chain Provenance & Signing · REDACTED
- Supply-chain Provenance & Signing · REDACTED
- Supply-chain Provenance & Signing · REDACTED
- Supply-chain Provenance & Signing · REDACTED
- Supply-chain Provenance & Signing · REDACTED
- Supply-chain Provenance & Signing · REDACTED
- Exception handling · Swallowed exception (caught, then discarded) hscontrol/policy/policyutil/reduce.go
- Exception handling · Swallowed exception (caught, then discarded) hscontrol/types/node.go
- Schema migrations · Schema created by GORM AutoMigrate (no migration path) hscontrol/db/db.go
- Schema migrations · Schema created by GORM AutoMigrate (no migration path) hscontrol/db/db.go
- Schema migrations · Schema created by GORM AutoMigrate (no migration path) hscontrol/db/db.go
Fixed since the last survey: 263 findings
- Cyclomatic Complexity · Policy.validate (cyclomatic 124) hscontrol/policy/v2/types.go
- Cyclomatic Complexity · PolicyManager.ViaRoutesForPeer (cyclomatic 50) hscontrol/policy/v2/policy.go
- Cyclomatic Complexity · Headscale.Serve (cyclomatic 49) REDACTED
- Cyclomatic Complexity · Policy.compileSSHPolicy (cyclomatic 46) hscontrol/policy/v2/filter.go
- Cyclomatic Complexity · State.UpdateNodeFromMapRequest (cyclomatic 42) hscontrol/state/state.go
- Cyclomatic Complexity · main.runTestContainer (cyclomatic 40) cmd/hi/docker.go
- Cyclomatic Complexity · hsic.New (cyclomatic 38) REDACTED
- Cyclomatic Complexity · db.NewHeadscaleDatabase (cyclomatic 36) hscontrol/db/db.go
- Cyclomatic Complexity · tsic.New (cyclomatic 33) integration/tsic/tsic.go
- Cyclomatic Complexity · integration.requireAllClientsOnlineWithSingleTimeout (cyclomatic 31) integration/helpers.go
- Cyclomatic Complexity · State.applyAuthNodeUpdate (cyclomatic 30) hscontrol/state/state.go
- Cyclomatic Complexity · PolicyManager.SSHCheckParams (cyclomatic 29) hscontrol/policy/v2/policy.go
- Cyclomatic Complexity · NodeStore.applyBatch (cyclomatic 29) hscontrol/state/node_store.go
- Cyclomatic Complexity · util.ParseTraceroute (cyclomatic 29) hscontrol/util/util.go
- Cyclomatic Complexity · State.HandleNodeFromPreAuthKey (cyclomatic 28) hscontrol/state/state.go
- Cyclomatic Complexity · Headscale.scheduledTasks (cyclomatic 26) REDACTED
- Cyclomatic Complexity · AuthProviderOIDC.OIDCCallbackHandler (cyclomatic 26) hscontrol/oidc.go
- Cyclomatic Complexity · types.validateServerConfigInto (cyclomatic 25) hscontrol/types/config.go
- Cyclomatic Complexity · apiv2.registerKeys (cyclomatic 24) hscontrol/api/v2/keys.go
- Cyclomatic Complexity · apiv2.registerDevices (cyclomatic 23) hscontrol/api/v2/devices.go
- Cyclomatic Complexity · hscontrol.NewHeadscale (cyclomatic 23) REDACTED
- Cyclomatic Complexity · PolicyManager.updateLocked (cyclomatic 23) hscontrol/policy/v2/policy.go
- Cyclomatic Complexity · State.createAndSaveNewNode (cyclomatic 23) hscontrol/state/state.go
- Cyclomatic Complexity · State.HandleNodeFromAuthPath (cyclomatic 23) hscontrol/state/state.go
- Cyclomatic Complexity · v2.validateUserReferences (cyclomatic 22) hscontrol/policy/v2/policy.go
- Cyclomatic Complexity · mapSession.serveLongPoll (cyclomatic 22) hscontrol/poll.go
- Cyclomatic Complexity · State.reregisterNodeWithPAK (cyclomatic 22) hscontrol/state/state.go
- Cyclomatic Complexity · hsic.extractTarToDirectory (cyclomatic 22) REDACTED
- Cyclomatic Complexity · main.cleanupSuccessfulTestArtifacts (cyclomatic 21) cmd/hi/cleanup.go
- Cyclomatic Complexity · apiv1.registerNodeWriteOps (cyclomatic 20) hscontrol/api/v1/nodes.go
- Cyclomatic Complexity · PolicyManager.BuildPeerMap (cyclomatic 20) hscontrol/policy/v2/policy.go
- Cyclomatic Complexity · types.LoadServerConfig (cyclomatic 20) hscontrol/types/config.go
- Cyclomatic Complexity · v2.resolveSSHTestDestNodes (cyclomatic 19) hscontrol/policy/v2/sshtest.go
- Cyclomatic Complexity · v2.validateSSHSrcDstCombination (cyclomatic 19) hscontrol/policy/v2/types.go
- Cyclomatic Complexity · PolicyManager.invalidateAutogroupSelfCache (cyclomatic 19) hscontrol/policy/v2/policy.go
- Cyclomatic Complexity · Headscale.handleRegister (cyclomatic 18) hscontrol/auth.go
- Cyclomatic Complexity · Batcher.worker (cyclomatic 18) hscontrol/mapper/batcher.go
- Cyclomatic Complexity · v2.evaluateAssertion (cyclomatic 18) hscontrol/policy/v2/sshtest.go
- Cyclomatic Complexity · HAHealthProber.ProbeOnce (cyclomatic 18) hscontrol/state/ha_health.go
- Cyclomatic Complexity · Change.Merge (cyclomatic 18) hscontrol/types/change/change.go
- Cyclomatic Complexity · Change.Type (cyclomatic 18) hscontrol/types/change/change.go
- Cyclomatic Complexity · integration.requireAllClientsOfflineStaged (cyclomatic 18) integration/helpers.go
- Cyclomatic Complexity · integration.NewScenario (cyclomatic 18) REDACTED
- Cyclomatic Complexity · integration.doLoginURLWithClient (cyclomatic 18) REDACTED
- Cyclomatic Complexity · apiv1.registerNodeAdminOps (cyclomatic 17) hscontrol/api/v1/nodes.go
- Cyclomatic Complexity · main.listControlFiles (cyclomatic 16) cmd/hi/docker.go
- Cyclomatic Complexity · HSDatabase.BackfillNodeIPs (cyclomatic 16) hscontrol/db/ip.go
- Cyclomatic Complexity · Groups.UnmarshalJSON (cyclomatic 16) hscontrol/policy/v2/types.go
- Cyclomatic Complexity · Policy.compileNodeAttrs (cyclomatic 16) hscontrol/policy/v2/compiled.go
- Cyclomatic Complexity · Scenario.ShutdownAssertNoPanics (cyclomatic 16) REDACTED
- Cyclomatic Complexity · Scenario.createHeadscaleEnvWithTags (cyclomatic 16) REDACTED
- Cognitive Complexity · Policy.validate (cognitive 284) hscontrol/policy/v2/types.go
- Cognitive Complexity · PolicyManager.ViaRoutesForPeer (cognitive 127) hscontrol/policy/v2/policy.go
- Cognitive Complexity · Policy.compileSSHPolicy (cognitive 114) hscontrol/policy/v2/filter.go
- Cognitive Complexity · Headscale.Serve (cognitive 95) REDACTED
- Cognitive Complexity · util.ParseTraceroute (cognitive 64) hscontrol/util/util.go
- Cognitive Complexity · hsic.New (cognitive 62) REDACTED
- Cognitive Complexity · main.runTestContainer (cognitive 60) cmd/hi/docker.go
- Cognitive Complexity · tsic.New (cognitive 60) integration/tsic/tsic.go
- Cognitive Complexity · main.cleanupSuccessfulTestArtifacts (cognitive 57) cmd/hi/cleanup.go
- Cognitive Complexity · NodeStore.applyBatch (cognitive 57) hscontrol/state/node_store.go
- Cognitive Complexity · integration.requireAllClientsOnlineWithSingleTimeout (cognitive 57) integration/helpers.go
- Cognitive Complexity · Batcher.worker (cognitive 51) hscontrol/mapper/batcher.go
- Cognitive Complexity · PolicyManager.SSHCheckParams (cognitive 50) hscontrol/policy/v2/policy.go
- Cognitive Complexity · db.NewHeadscaleDatabase (cognitive 47) hscontrol/db/db.go
- Cognitive Complexity · v2.resolveSSHTestDestNodes (cognitive 46) hscontrol/policy/v2/sshtest.go
- Cognitive Complexity · State.HandleNodeFromPreAuthKey (cognitive 46) hscontrol/state/state.go
- Cognitive Complexity · State.UpdateNodeFromMapRequest (cognitive 45) hscontrol/state/state.go
- Cognitive Complexity · v2.evaluateAssertion (cognitive 42) hscontrol/policy/v2/sshtest.go
- Cognitive Complexity · Headscale.scheduledTasks (cognitive 40) REDACTED
- Cognitive Complexity · hsic.extractTarToDirectory (cognitive 39) REDACTED
- Cognitive Complexity · PolicyManager.invalidateAutogroupSelfCache (cognitive 37) hscontrol/policy/v2/policy.go
- Cognitive Complexity · hscontrol.NewHeadscale (cognitive 36) REDACTED
- Cognitive Complexity · Headscale.handleRegister (cognitive 36) hscontrol/auth.go
- Cognitive Complexity · main.waitForContainerFinalization (cognitive 35) cmd/hi/docker.go
- Cognitive Complexity · ExtraRecordsMan.Run (cognitive 35) hscontrol/dns/extrarecords.go
- Cognitive Complexity · integration.requireAllClientsOfflineStaged (cognitive 34) integration/helpers.go
- Cognitive Complexity · integration.NewScenario (cognitive 34) REDACTED
- Cognitive Complexity · policyutil.reduceCapGrantRule (cognitive 32) hscontrol/policy/policyutil/reduce.go
- Cognitive Complexity · State.applyAuthNodeUpdate (cognitive 32) hscontrol/state/state.go
- Cognitive Complexity · Scenario.createHeadscaleEnvWithTags (cognitive 32) REDACTED
- Cognitive Complexity · apiv2.registerKeys (cognitive 31) hscontrol/api/v2/keys.go
- Cognitive Complexity · mapSession.serveLongPoll (cognitive 31) hscontrol/poll.go
- Cognitive Complexity · TailscaleInContainer.WaitForPeers (cognitive 30) integration/tsic/tsic.go
- Cognitive Complexity · PolicyManager.BuildPeerMap (cognitive 29) hscontrol/policy/v2/policy.go
- Cognitive Complexity · HAHealthProber.ProbeOnce (cognitive 29) hscontrol/state/ha_health.go
- Cognitive Complexity · v2.validateUserReferences (cognitive 28) hscontrol/policy/v2/policy.go
- Cognitive Complexity · Groups.UnmarshalJSON (cognitive 28) hscontrol/policy/v2/types.go
- Cognitive Complexity · State.HandleNodeFromAuthPath (cognitive 28) hscontrol/state/state.go
- Cognitive Complexity · types.validateServerConfigInto (cognitive 28) hscontrol/types/config.go
- Cognitive Complexity · Scenario.CreateTailscaleNodesInUser (cognitive 27) REDACTED
- Cognitive Complexity · HSDatabase.BackfillNodeIPs (cognitive 26) hscontrol/db/ip.go
- Cognitive Complexity · State.createAndSaveNewNode (cognitive 26) hscontrol/state/state.go
- Cognitive Complexity · Scenario.ShutdownAssertNoPanics (cognitive 26) REDACTED
- Cognitive Complexity · StatsCollector.collectStatsForContainer (cognitive 25) cmd/hi/stats.go
- Cognitive Complexity · apiv2.registerDevices (cognitive 25) hscontrol/api/v2/devices.go
- Cognitive Complexity · AuthProviderOIDC.OIDCCallbackHandler (cognitive 25) hscontrol/oidc.go
- Cognitive Complexity · v2.validateSSHSrcDstCombination (cognitive 25) hscontrol/policy/v2/types.go
- Cognitive Complexity · State.reregisterNodeWithPAK (cognitive 25) hscontrol/state/state.go
- Cognitive Complexity · cli.nodesToPtables (cognitive 24) cmd/headscale/cli/nodes.go
Rebuild cost: about €170,000 · Estimate
| Cost to rebuild | €55,000 to €280,000, for 919 to 2,917 hours of work, about 1.1 person-years for 1 to 3 engineers |
|---|---|
| Difficulty of the problem | Standard, judged from the kind of software and how it is built. Code that solves a harder problem, such as payments or medical bookings, costs more per line to write. |
| Quality factor | ×0.8 at a score of 58. Better code takes more work to write, so the factor is ×1.0 at a score of 70, lower below it and higher above it. |
| Size | Medium: 54,075 lines of product code |
Top priorities
Diagnosis: what the measurements show together
At a glance — Code Health
At a glance — Architecture
At a glance — Maturity
At a glance — Readiness
At a glance — Security
At a glance — Performance
Security & Compliance — OWASP Top-10 mapping
| OWASP category | Findings | Severity |
|---|---|---|
| A02:2025 — Security Misconfiguration | 23 | High / Critical |
| A03:2025 — Software Supply Chain Failures | 21 | High / Critical |
| A05:2025 — Injection | 19 | High / Critical |
Roadmap
First, harden outbound HTTP calls by enforcing explicit timeouts, adding retry logic with back-off, and implementing circuit breakers for failing dependencies. Second, replace GORM AutoMigrate with a versioned migration tool to ensure safe and reproducible database schema evolution. Finally, address critical knowledge and documentation gaps by resolving off-boarding risks, creating the missing Architecture Decision Records, and documenting significant design decisions in a centralized folder.
| Do this | Helps | Effort | Dimension |
|---|---|---|---|
| Resolve the 1 No ADRs found finding(s) in ADR Quality. | +3.4 pts | Low | ADR Quality |
| Resolve the 1 Off-boarding risk finding(s) in Bus Factor. | +3.2 pts | Low | Bus Factor |
| Resolve the 2 Dependency pinned to a stale untagged commit finding(s) in Dependency Hygiene. | +2.2 pts | Low | Dependency Hygiene |
| Give every `http.Client` an explicit `Timeout` (never call `http.Get`/`http.Post` or `http.DefaultClient`, which have none), or build each request with `http.NewRequestWithContext` under a `context.WithTimeout`; add retry with back-off (`hashicorp/go-retryablehttp`) and a breaker (`sony/gobreaker`) around dependencies that fail. | +3.7 pts | Medium | Outbound HTTP resilience |
| Replace GORM AutoMigrate with a versioned migration tool such as golang-migrate, goose or Atlas so the production schema can evolve safely and reproducibly. | +3.7 pts | Medium | Schema migrations |
| Record your significant design decisions. Write one short document per decision, giving its date, the situation, the decision and its consequences, and keep them together with your other design documents. A docs/adr folder with each file named by number and title is the easiest place to find them. | +2.9 pts | Medium | Architecture documentation |
| Document RTO/RPO and a tested restore procedure (a backup config alone isn't disaster recovery). | +2.7 pts | Medium | DR & Backup |
| Enable Dependabot/Renovate or a dependency-review gate. | +2.0 pts | Medium | Security & performance tooling |
File quality
| File | Score | Band | Worst signal |
|---|---|---|---|
| REDACTED | 1.4 | Slop | Dependency Vulnerabilities: High CVE: REDACTED |
| REDACTED | 1.7 | Slop | Static Analysis (SAST): High: REDACTED |
| REDACTED | 2.8 | Slop | IaC & Container Security: High IaC: REDACTED |
| REDACTED | 3.0 | Mixed | Static Analysis (SAST): High: REDACTED |
| REDACTED | 3.4 | Mixed | Static Analysis (SAST): High: REDACTED |
| REDACTED | 3.5 | Mixed | IaC & Container Security: High IaC: REDACTED |
| REDACTED | 3.5 | Mixed | IaC & Container Security: High IaC: REDACTED |
| REDACTED | 3.5 | Mixed | IaC & Container Security: High IaC: REDACTED |
| REDACTED | 3.7 | Mixed | Static Analysis (SAST): High: REDACTED |
| REDACTED | 4.1 | Mixed | IaC & Container Security: High IaC: REDACTED |
| REDACTED | 4.4 | Mixed | IaC & Container Security: High IaC: REDACTED |
| REDACTED | 6.1 | Mixed | Static Analysis (SAST): Medium: REDACTED |
| hscontrol/db/db_test.go | 6.4 | Mixed | Explicit Debt: TodoComment |
| hscontrol/state/state.go | 6.4 | Mixed | Explicit Debt: TodoComment |
| hscontrol/db/migrate_credentials.go | 6.4 | Mixed | Explicit Debt: TodoComment |
| REDACTED | 6.5 | Mixed | Static Analysis (SAST): High: REDACTED |
| hscontrol/oidc.go | 6.5 | Mixed | Explicit Debt: TodoComment |
| hscontrol/db/secret.go | 6.5 | Mixed | Explicit Debt: TodoComment |
| hscontrol/db/db.go | 6.5 | Mixed | Explicit Debt: TodoComment |
| hscontrol/db/api_key.go | 6.6 | Mixed | Explicit Debt: TodoComment |
How the grades work
A definite problem that already costs you something and drags the score down: a missing authorisation check, a dependency with a known exploit, a build that does not reproduce. Failure here tends to cause failures elsewhere.
Likely wrong, but not failing yet. It degrades the codebase over a longer horizon and can cause failures elsewhere — not urgent this week, not something to carry for two years either.
Recorded, with no effect on how the codebase functions. Present so the survey is complete, not because it needs doing.
Something this survey could not settle from the outside, and which could be critical or serious. Either a control was required and no positive evidence of it exists in the repository — a backup job that nothing shows was ever restored from proves nothing about restores — or our own analysis could not run over that part of the tree. This is not a clean result. These are excluded from the score rather than awarded a pass, so the number on the cover neither rewards nor penalises them: if you act on this survey without resolving them, you carry that risk yourself. Each one is named under Limitations.
Methodology & how to trust this report
Watchdog is a deep, periodic assessment — run each sprint, monthly, or quarterly, taking the time to go wider and deeper than a quick check and surfacing in one coherent report what you'd otherwise piece together from a dozen separate tools. It scores deterministically: the same commit yields the same score, every run. 38 of 41 evaluated dimensions are computed purely by tools and static analysis (confidence 1.0); 3 documentation/naming judgement(s) are LLM-assisted and labelled advisory. Overall confidence is 0.8 — the weighted average across measured dimensions; it falls as more of the score leans on LLM-assisted judgement and rises when it's fully tool-backed.
What we checked — 41 dimensions across the health lenses
- Can you open the finding? Real findings cite a repo-relative file and line you can open at the cited line — never an absolute scratch path. Here, 226 of 238 do; the remainder are repo-wide signals — a dimension-level measurement, not a single line.
- Is there a tool behind the number? Every score below names the method that produced it — Roslyn, git, a scanner, or (for a handful of documentation/naming dimensions) an LLM labelled sampled · advisory — not a narrative.
- Does re-running give the same result? Run it again on the same commit and the score — and this report, byte for byte — is identical. A report whose numbers move between runs is describing the run, not the code.
Tools & methods
| Method | Backs | Version | Evaluator |
|---|---|---|---|
| Roslyn static analysis | Complexity, cohesion, coupling, dead code, API surface, layering | 5.3.0 | ✓ deterministic |
| Native secret scanner | Hardcoded secrets / credentials | 1.0.0 | ✓ deterministic |
| Watchdog duplication detector (in-process) | Code duplication | 1.0.0 | ✓ deterministic |
| Coverage (coverlet / dotnet-coverage) | Line & branch coverage | 10.0.400 | ✓ deterministic |
| NuGet / dotnet | Outdated, vulnerable & deprecated dependencies | 10.0.400 | ✓ deterministic |
| git / LibGit2Sharp | Churn hotspots, knowledge concentration, history | 2.43.0 · 0.31.0 | ✓ deterministic |
| gitleaks · semgrep · trivy · checkov | Secrets in history, SAST, CVEs, IaC & container, PII / GDPR | 1.86.0 · 0.69.3 · 3.2.533 | ✓ deterministic |
| LLM (sampled · advisory) | Documentation quality, ADR conformance, naming — sampled over a bounded sample; advisory, never a deterministic measurement | Local LLM | ◐ LLM · sampled · advisory |
Run transparency — what happened this run
- D1 Cyclomatic Complexity — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Most of this repository's production source (.go) had no cyclomatic complexity computed for it: no function bodies were exposed for those file kinds by any language model this pass could load.
- D2 Cognitive Complexity — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Most of this repository's production source (.go) had no cognitive complexity computed for it: no function bodies were exposed for those file kinds by any language model this pass could load.
- D4 Code Duplication — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Most of this repository's production source (.go) was not read by duplication detection: no source of those file kinds was exposed to the token comparison by any language model this pass could load.
- D8 Code Coverage — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Coverage NOT MEASURED: test source is present (.go) but the built-in coverage collector has no runner for this repository's ecosystem — so this suite was never executed by it. Not scored — this is a gap in the analyzer's language coverage, not a defect in the repo. To have real coverage read, produce a coverage report in a standard format (`go test -coverprofile=coverage.out ./...`) and commit it — a hosted scan measures a clone of the repository, so a report that exists only in a working tree, a CI runner's or your own, never reaches it; the artefact is commonly gitignored, so `git add -f` that one file (or un-ignore its path) and commit it alongside the code it measures. You can widen what we reach: optional: produce a coverage report in a standard format (`go test -coverprofile=coverage.out ./...`) and commit it — a hosted scan measures a clone of the repository, so a report that exists only in a working tree, a CI runner's or your own, never reaches it; the artefact is commonly gitignored, so `git add -f` that one file (or un-ignore its path) and commit it alongside the code it measures — then the real number is read on the next scan.
- D11 Test Reliability — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Test source is present (.go) and this repository declares a Go test suite (github.com/juanfont/headscale), but it was not re-run: the analyzer environment could not run it. Not scored — this is a gap in the analyzer's language coverage, not a finding about this repository.
- D14 License Compliance — measured, with a gap in what it reached — Watchdog measured this, but not all of it. What it did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. This repository declares a Python pyproject.toml/requirements.txt (pip/uv/Poetry), but the licence verdict published here was taken over its Go module dependencies. Nothing was read about its Python dependencies' licensing in either direction, and a clean score on this card must not be read as covering them.
- D15 Churn × Complexity Hotspots — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. A hotspot is churn × complexity. Churn was measured (221397 line(s) across the 90-day window), but no complexity could be computed for .go, which is most of this repository's production code — so every churned file would score as complexity 0 and the hotspot list would be empty no matter how tangled the code is. Not scored — this is a gap in the analysis run, not a finding about this repository.
- D22 Internal API Consistency — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. D22 identifies the intentionally-exposed surface from `IsPackable` and `.Contracts` project names, MSBuild conventions read off the loaded project set. This target exposed no such projects, so the probe never ran; this says nothing about whether the repository has a public API. A language sidecar this run needed FAILED, so the code model the non-MSBuild public-API collector reads was never built — this is a DEGRADED run, not a settled gap, and the surface may well be collectable on a re-run: The Go sidecar exited 0 and produced a model, but its own source census reports it opened ZERO Go files — while the engine's presence probe found Go source in this tree. The model is therefore empty for a reason on OUR side, not the repository's, and Go is recorded as unread rather than as clean.
- D26 Project Cohesion — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Project size and spread are measured over build units (a .NET project, a Maven or Gradle module, an npm, Deno or JSR package, a Go module, a Cargo crate, a Python, Composer, Bundler, RubyGems, Mix, rebar3, sbt, SwiftPM or pub package, an OTP application, an Xcode project or XcodeGen spec, or a checkout that declares no build at all) whose source a code model reads. This repository's production source is in a language no model reads, or in units whose build tool D26 does not recognise. That is a gap in this analyzer's language reach — not a finding that the repository's projects are cohesive.
- D28 Secrets (history) — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Gitleaks produced no output — a clean scan reports `[]`, so this is a scan that did not run, not a repo without secrets. The scanner (gitleaks) ran but its output could not be parsed into the expected shape, so this run is a measurement gap rather than a clean pass.
- D32 Data Compliance (PII/GDPR) — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. `hscontrol/api/v1/types.go`, `hscontrol/policy/v2/types.go`, `hscontrol/state/state.go`, `REDACTED`, `integration/tsic/tsic.go` produced a parse error, so every rule in this engine's `gdpr.yml` was absent there. That absence is NOT a clean result: these rules detect personal data crossing a boundary into a log sink, a URL or browser storage, and a file that was never parsed cannot report any of the three. The rest of the tree analysed normally and its rows above stand; only these files are unaccounted for. You can widen what we reach: fix the syntax error (or exclude the file deliberately) and re-scan to cover it.
- AX2 Stateful singletons — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- AX6 Interface segregation — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is computed over the public interfaces this run's compilations declare, and none was loaded, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- AXR1 Runtime accessibility — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Render strategy: boot via Dockerfile (REDACTED). docker build failed (exit 1) — DEPRECATED: The legacy builder is deprecated and will be removed in a future release. Install the buildx component to build images with BuildKit: https://docs.docker.com/go/bui…; runtime evidence skipped.
- C1 Data Protection — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. These personal data controls are read from declarative annotations, request middleware, entity/column names and guard methods in a C# source model, and none was loaded on this run, so there was nothing to gather. That is a gap in this analyzer's language reach — not a finding that the repository lacks personal data controls.
- C2 Access Controls — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. These authorization controls are read from declarative annotations, request middleware, entity/column names and guard methods in a C# source model, and none was loaded on this run, so there was nothing to gather. That is a gap in this analyzer's language reach — not a finding that the repository lacks authorization controls.
- C3 Audit Trail — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. These audit controls are read from declarative annotations, request middleware, entity/column names and guard methods in a C# source model, and none was loaded on this run, so there was nothing to gather. That is a gap in this analyzer's language reach — not a finding that the repository lacks audit controls.
- C4 Data Retention — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. These retention controls are read from declarative annotations, request middleware, entity/column names and guard methods in a C# source model, and none was loaded on this run, so there was nothing to gather. That is a gap in this analyzer's language reach — not a finding that the repository lacks retention controls.
- C5 Data-Subject Rights — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. These data-subject rights controls are read from declarative annotations, request middleware, entity/column names and guard methods in a C# source model, and none was loaded on this run, so there was nothing to gather. That is a gap in this analyzer's language reach — not a finding that the repository lacks data-subject rights controls.
- ED5 Idempotency — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check finds retry-prone mutations by walking the repository's declared types, and NONE was loaded on this run, so it had nothing to look at. That is a limit of the analyzer's reach — neither a .NET project nor a language model of this repository's code reached it — not a finding that this repository has no command handlers or message consumers.
- GD1 Unfinished & placeholder code — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check reads C# syntax, F#, JavaScript/TypeScript, Dart, Ruby and Scala source only, and no C#, F#, JavaScript/TypeScript, Dart, Ruby or Scala was found, and this repository's Go is not read yet, so it had nothing of this repository's product to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- IC1 Incompleteness & stubs — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check reads C# syntax, JavaScript/TypeScript, Java, Dart, Ruby and Scala source only, and no C#, JavaScript/TypeScript, Java, Dart, Ruby or Scala was found, and this repository's Go is not read yet, so it had nothing of this repository's product to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- PF3 Async & latency hygiene — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. No function of a language this check models was read, so there was no async code to examine. That is a limit of the analyzer on this repository, not a finding about it.
- S1 Web-Security Posture — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. These web-security controls are read from declarative annotations, request middleware, entity/column names and guard methods in a C# source model, and none was loaded on this run, so there was nothing to gather. That is a gap in this analyzer's language reach — not a finding that the repository lacks web-security controls.
- X1 Async correctness — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check reads C# syntax, and JavaScript/TypeScript, Python, Dart, Ruby, Scala, Rust and Kotlin source only, and no C# was loaded and no JavaScript/TypeScript, Python, Dart, Ruby, Scala, Rust or Kotlin was found in this repository, so it had nothing of this repository's product to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X12 Unreachable branch — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check reads C# syntax, and JavaScript/TypeScript, Python, Dart, Ruby, Scala and Kotlin source only, and no C# was loaded and no JavaScript/TypeScript, Python, Dart, Ruby, Scala or Kotlin was found in this repository, so it had nothing of this repository's product to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X13 Undrained process stream — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check reads C# syntax, and JavaScript/TypeScript, Python, Dart, Ruby, Scala and Kotlin source only, and no C# was loaded and no JavaScript/TypeScript, Python, Dart, Ruby, Scala or Kotlin was found in this repository, so it had nothing of this repository's product to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X16 Unfloored truncation loop — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check reads C# syntax, and JavaScript/TypeScript, Java, PHP, Dart, Ruby, Scala and Kotlin source only, and no C# was loaded and no JavaScript/TypeScript, Java, PHP, Dart, Ruby, Scala or Kotlin was found in this repository, so it had nothing of this repository's product to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X17 Uncapped recursion over a caller-supplied document — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check reads C# syntax, and JavaScript/TypeScript, Python, Dart, Ruby, Scala and Kotlin source only, and no C# was loaded and no JavaScript/TypeScript, Python, Dart, Ruby, Scala or Kotlin was found in this repository, so it had nothing of this repository's product to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X18 Disposal-pattern correctness — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check reads C# syntax, and JavaScript/TypeScript, Java, Kotlin, Dart, Ruby, Scala and PHP source only, and no C# was loaded and no JavaScript/TypeScript, Java, Kotlin, Dart, Ruby, Scala or PHP was found in this repository, so it had nothing of this repository's product to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X19 Unrestored process-global state — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check reads C# syntax, and JavaScript/TypeScript, Java, Kotlin, Python, Dart, Ruby, Scala and PHP source only, and no C# was loaded and no JavaScript/TypeScript, Java, Kotlin, Python, Dart, Ruby, Scala or PHP was found in this repository, so it had nothing of this repository's product to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X22 Contradicted release guard — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check reads C# syntax, and Java, TypeScript/JavaScript, Python, Dart, Ruby, Scala, Kotlin and PHP source only, and no C# was loaded, and this repository's Go is not read yet, so it had nothing of this repository's product to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X23 Unguarded diagnostic materialisation — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check reads C# syntax, and JavaScript/TypeScript, Java, F#, Python, Dart, Ruby, Scala, Kotlin and PHP source only, and no C# was loaded and no JavaScript/TypeScript, Java, F#, Python, Dart, Ruby, Scala, Kotlin or PHP was found in this repository, so it had nothing of this repository's product to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X24 Document value interpolated into markup unescaped — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check reads C# syntax, and JavaScript/TypeScript, Java, Scala, Ruby and Python source only, and no C# was loaded and no JavaScript/TypeScript, Java, Scala, Ruby or Python was found in this repository, so it had nothing of this repository's product to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X25 Inert configuration knob — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check reads C# syntax, and JavaScript/TypeScript, Java, Kotlin, Scala, PHP, Erlang, Python, Dart and Ruby source only, and no C# was loaded and no JavaScript/TypeScript, Java, Kotlin, Scala, PHP, Erlang, Python, Dart or Ruby was found in this repository, so it had nothing of this repository's product to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X27 Collection changed while being enumerated — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check reads C# syntax, and Java, Rust, Erlang, F#, Python, Dart, Ruby, Scala and Kotlin source only, and no C# was loaded, no Java, Rust, Erlang, F#, Python, Dart, Ruby, Scala or Kotlin was found, and this repository's Go is not read yet, so it had nothing of this repository's product to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X29 Per-element action decided by a fixed element — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check reads C# syntax, and JavaScript/TypeScript, Java, Rust, Dart, Ruby, Scala and Kotlin source only, and no C# was loaded and no JavaScript/TypeScript, Java, Rust, Dart, Ruby, Scala or Kotlin was found in this repository, so it had nothing of this repository's product to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X4 Structured logging — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check reads C# syntax, and JavaScript/TypeScript, Java, Kotlin, Python, PHP, Dart, Ruby, Scala and Rust source only, and no C# was loaded and no JavaScript/TypeScript, Java, Kotlin, Python, PHP, Dart, Ruby, Scala or Rust was found in this repository, so it had nothing of this repository's product to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X7 Silent fallback defaults — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check reads C#, Python, TypeScript/JavaScript, Rust, Go, Java, Kotlin, Scala, PHP, Ruby, Swift and Dart syntax only, and no C#, Python, TypeScript/JavaScript, Rust, Go, Java, Kotlin, Scala, PHP, Ruby, Swift or Dart was loaded for this repository, so it had nothing of this repository's product to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- Production source was not modelled — run is Degraded — No code model read .go, so the complexity, duplication and architecture dimensions were scored over a minority of this repository rather than its product, and dimensions that abstained did so for want of a model rather than for want of findings. The grade is NOT representative of this repository; diagnostics.md records the exact cause. The Go sidecar exited 0 and produced a model, but its own source census reports it opened ZERO Go files — while the engine's presence probe found Go source in this tree. The model is therefore empty for a reason on OUR side, not the repository's, and Go is recorded as unread rather than as clean.
Limitations & what we did not check
Watchdog assesses the repository exactly as committed, and only the repository. By design it does not reach outside the source tree: the live cloud account, the running CI/CD pipeline, the host's branch-protection and approval rules, the production configuration, or a restore actually exercised against a backup are all out of scope. That boundary is a feature, not a gap — a repo-relative, deterministic scan re-runs identically on any commit and every finding opens at a real file and line, where a live audit can neither be reproduced nor traced. The visible consequence is that controls which leave no in-repo evidence are reported as "not evidenced" and excluded from the score rather than awarded a number a static scan cannot justify.
Per-dimension blind spots
- D9 Test Distribution: The test-pyramid shape is inferred from project/folder naming and references, with a single test host bucketed per-file by its path tier and content signals — a suite that names tiers unconventionally and gives no per-file signal can still be mis-bucketed.
- D12 Dependency Hygiene: Dependency health reads manifests and lockfiles — a vulnerability in a vendored/copied dependency, or risk from how a dependency is actually used, is outside this view.
- D13 Secret Scanning: Secret detection is signature- and entropy-based on the current tree — a secret that does not match a known pattern, or one already rotated, will not be flagged (a clean scan is "nothing matched", not "no secrets exist").
- D14 License Compliance: License compatibility is checked against declared package metadata and a policy — mislabelled or missing license metadata, and obligations that depend on how you distribute, are not resolved here.
- D16 Bus Factor: Bus-factor is a time-decayed model of commit attribution (who has recently, repeatedly worked a file), not comprehension — pairing, review and reading-without-committing spread knowledge it can't see; bot commits and shared accounts still distort it.
- D17 Explicit Debt: Acknowledged-debt signals (TODO/FIXME, suppressions, dead code) are textual — undocumented debt that nobody marked, and debt that lives in design rather than annotations, is invisible. Committed machine-written code (scaffolded migrations, designer/codegen output, generated stubs) is excluded — it is never the team's dead code to delete.
- D19 Documentation Quality: Documentation quality is judged by an LLM over a bounded sample of docs — it reads what is written, not whether the docs match the running system, and it is advisory, not a measurement. Its critique rows are drawn from a closed category vocabulary and each row means the same thing in every run, so two scans can be compared row by row; the SET that fires is still a sample, and does not repeat exactly. Measured on one frozen input, six scans at one engine SHA: 2-5 critique rows per scan, 8 distinct rows across the six, 3 of those 8 seen in only one scan. So a D19 row is evidence about the documentation, but a COUNT of D19 rows is not a quantity — never read a change in it as an improvement or a regression.
- D20 ADR Quality: ADR quality is an LLM read of the decision records present — it cannot know about decisions made and never recorded, and its verdict is sampled and advisory.
- D21 Naming Consistency: Naming quality is an LLM judgement over a bounded sample — it assesses clarity/consistency of the names it sees, not domain-correctness, and is advisory.
- D29 Static Analysis (SAST): SAST findings are pattern-based (semgrep) — it finds classes of bug it has rules for; logic flaws, auth/authorization gaps and issues needing runtime context are out of reach (and clean means "no rule matched").
- D30 Dependency Vulnerabilities: CVE matching depends on accurate package/version metadata and on the advisory databases — a vulnerability with no published advisory, or in code not declared as a dependency, is not seen. Coverage needs a RESOLVED graph: an unpinned requirements.txt, or a pom without a resolved build, yields partial coverage rather than a clean verdict. An ecosystem the analyzer cannot scan is reported as unmeasured, never as clean.
- D31 IaC & Container Security: IaC scanning checks Dockerfiles/Terraform/Kubernetes against best-practice rules — it cannot see the live cloud account, runtime configuration, or drift between the committed config and what is actually deployed.
- D34 Knowledge Freshness: Freshness is decayed commit RECENCY, not comprehension — code read often but rarely committed reads as orphaned, and stable code that genuinely needs no changes is penalised the same as forgotten code; bot/squash commits distort it like the bus factor.
- D35 Change Coupling: Change coupling is co-change in COMMITS — files split across separate commits, or coupled only through a shared config/build step, read as uncoupled, and a sweeping commit (rename/format) is excluded so it doesn't couple everything. It shows that files change together, not WHY: a high coupling can be a healthy cohesive pair as readily as a hidden leak.
- D43 Malicious Dependencies: Only packages some vulnerability database has already NAMED as malicious are seen — a compromise published in the last hours, or never reported at all, is invisible here, and this dimension reading 10 is not evidence that a dependency is trustworthy. There is no typosquat or dependency-confusion analysis: a package nobody has reported is simply absent from the feeds. Coverage is the dependency scan's: an ecosystem that could not be scanned is disclosed as unmeasured, never as clean.
- D44 Platform End-of-Life: The support table is FROZEN, so it goes out of date by losing RECALL: a release that ended support after the table was written is missed until the table is refreshed, and this dimension reading 10 is not evidence that a platform is current. Only platforms the repository DECLARES in a place this pass reads are seen — a runtime named only in a Dockerfile (D31's subject), in a CI workflow (D29's), or in a file this pass does not parse (REDACTED, a Gemfile ruby directive) is invisible here, which is why a repository declaring none of them abstains rather than scoring. Only frameworks with a PUBLISHED support policy are tracked: React, Flask and Express publish none, so their age cannot be judged and their absence from a report is not a statement that they are supported.
- AX10 Code composition: Role is inferred from namespace/folder convention, not semantics — a domain concept living in a folder named "Services" reads as application, and the split is lines-of-code, not business value. The business-logic-share score is a SOFT, FLOORED signal: it contributes to the Architecture lens but is floored at the Critical gate, so an infrastructure-heavy design (a gateway, an ETL, a driver) is legitimately low without being nuked to zero.
- M4 Documentation accuracy: Onboarding quality is an LLM read of the docs/setup present — it cannot run the onboarding or measure how long a real new joiner takes; the verdict is sampled and advisory.
- P4 Deployment & Rollback: Approval/branch-protection rules live in repository settings the scan cannot see — only their in-repo evidence (config files, workflows) is checked, so a control enforced purely in the host's settings reads as "not evidenced".
- P5 DR & Backup: Backup/restore and disaster-recovery readiness is judged from in-repo evidence — a config that exists is not a tested restore, so the absence of positive evidence is reported as "not evidenced", never scored as present.
- P6 Release Hygiene: Rollback/observability controls are inferred from repo artefacts (pipelines, dashboards-as-code) — controls configured in external tooling, with no in-repo trace, cannot be credited.
The LLM boundary
Dimensions
D9 · Test Distribution
1295 test methods: 1117 unit, 178 integration, 0 BDD, 0 e2e. The Go suite contributes 1295 test case(s) across 207 `_test.go` file(s) declaring at least one — every `func Test…(t *testing.T)` that `go test` would collect, plus the suite methods a testify-style runner reaches; a table-driven case list counts once, so this is a floor. Its tier split is INFERRED from file names, paths and build constraints, not declared: 26 of those file(s) use Go's external test package (`package x_test`), which is a visibility boundary rather than a pyramid tier and was not read as one.
D12 · Dependency Hygiene
1 outdated, 0 author-deprecated direct Go module(s), 2 pinning or checksum defect(s). 65 of 65 direct requirement(s) were graded against proxy.golang.org (0 not served there, 9 publishing no tagged release to be behind). Whether any of these modules is UNMAINTAINED is not graded — proxy.golang.org publishes no maintenance status, and release age does not stand in for one. Whether any is UNUSED is not graded either: that is a source question, not a registry one. Known CVEs in this module graph are D30's question, read from REDACTED and go.sum there.
What to do
- Resolve the 2 Dependency pinned to a stale untagged commit finding(s) in Dependency Hygiene. — One of this dimension's main actionable groups (2 warning-level).
- Enforce Dependency Hygiene in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Verified — provenance only; does not change the score.
D13 · Secret Scanning
Secret scan ran and found no leaked secrets.
D14 · License Compliance
0 of 236 required Go module(s) use a banned license. Licences were read per module version from the licence files pkg.go.dev detects (via api.deps.dev), over every module this repository's REDACTED requires, direct and indirect, at the version the build uses. Go records no test-only scope at module level, so modules only this repository's own tests import are included. 1 of them carry no licence file that matches a known SPDX licence; that is missing data, not a violation, and none of them is charged. ★ COVERAGE OF THIS VERDICT: it grades this repository's Go module dependencies and nothing else. The repository also declares a Python pyproject.toml/requirements.txt (pip/uv/Poetry), and the licences of those dependencies were NOT read by this pass — a gap in this engine's coverage, not a statement about them. So this result says the graded closure carries no banned licence; it does NOT say this repository's licensing is clear.
D16 · Bus Factor
87 source file(s) have their living knowledge concentrated in one author (≥90% of recent, decayed contribution). The largest is hscontrol/state/state.go. Counted over 147 of the 206 production source files in this repository: the rest are under the ~2,400-byte size floor this dimension measures over.
What to do
- Resolve the 1 Off-boarding risk finding(s) in Bus Factor. — One of this dimension's main actionable groups (1 recommendation-level).
D17 · Explicit Debt
107 deducted task-comment markers across 54075 LoC (0.2/KLoC) → score 9.6. Task comments only: this repository's language is read without a compiler, so D17's suppression, dead-code and commented-out-code arms did not run and this score counts fewer marker kinds than a .NET repository's would.
What to do
- Resolve the 107 TodoComment finding(s) in Explicit Debt — start with db_test.go (11), state.go (8), migrate_credentials.go (7). — One of this dimension's main actionable groups (107 warning-level).
- Enforce Explicit Debt in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Prevented — provenance only; does not change the score.
D19 · Documentation Quality
The repository's root README (README.md) gives a strong overview of what Tailscale is and its design goal, plus links to stable and development documentation; the integration/README.md documents how to write integration tests with a running test framework and scaffolding rules; nix/README.md explains the NixOS module and test kit for VMs; cmd/dev/README.md describes local dev mode with flags, state, and useful endpoints; hi/README.md is the main test runner with commands, flags, and a doctor step; hscontrol/api/v2/README.md documents v2 API conventions including Tailscale compatibility and auth; all four README files are directory-specific (integration/, nix/, packaging/, cmd/dev/) and document their own directories rather than the repository. The only unifying element is that each README states what it documents, so there is no single missing overview, installation, or usage section across them.
D20 · ADR Quality
No architecture decision records were found.
What to do
- Resolve the 1 No ADRs found finding(s) in ADR Quality. — One of this dimension's main actionable groups (1 recommendation-level).
D21 · Naming Consistency
0 naming inconsistencies across 0 sampled symbols.
D29 · Static Analysis (SAST)
19 finding(s): 0 critical, 9 high, 5 medium, 5 low. 2 unpinned-GitHub-Actions row(s) are reported here but scored by D36 (supply-chain provenance), which measures that posture as `pinned_actions` — one pinning decision is charged once, not once per lens. semgrep hit a parse error in 5 file(s) — `hscontrol/api/v1/types.go` (line 16), `hscontrol/policy/v2/types.go` (line 1064, line 1066, line 1068, …), `hscontrol/state/state.go` (line 678, line 680, line 709, …), `REDACTED` (line 1750), `integration/tsic/tsic.go` (lines 1036–1044, line 1054) — so no absence of findings in the named regions is evidence of anything; rows reported elsewhere in those files are real. Fix the syntax error (or exclude the file deliberately) and re-scan to cover them. Separately, one or more rules could not re-parse an embedded snippet in 6 file(s) (e.g. a workflow `run:` block read as shell). Those files WERE scanned and their other rows are unaffected; only those rules' view of those snippets is missing.
What to do
- Resolve the 3 REDACTED finding(s) in Static Analysis (SAST) — start with REDACTED, REDACTED, REDACTED. — One of this dimension's main actionable groups (3 issue-level).
- Resolve the 2 REDACTED finding(s) in Static Analysis (SAST) — start with REDACTED, REDACTED. — One of this dimension's main actionable groups (2 issue-level).
- No action in Static Analysis (SAST) — all 2 REDACTED finding(s) are reported here at file:line but scored by D36 (supply-chain provenance), so none is charged to this dimension. — One of this dimension's main actionable groups (2 issue-level, 0 of them charged here).
D30 · Dependency Vulnerabilities
6 finding(s): 0 critical, 3 high, 3 medium, 0 low.
What to do
- Resolve the 3 High CVE finding(s) in Dependency Vulnerabilities — start with REDACTED (3). — One of this dimension's main actionable groups (3 issue-level).
- Resolve the 2 Medium CVE finding(s) in Dependency Vulnerabilities — start with REDACTED (2). — One of this dimension's main actionable groups (2 warning-level).
- Resolve the 1 Medium vulnerability finding(s) in Dependency Vulnerabilities — start with REDACTED. — One of this dimension's main actionable groups (1 warning-level).
D31 · IaC & Container Security
23 finding(s): 0 critical, 6 high, 15 medium, 2 low.
What to do
- Resolve the 15 Medium IaC finding(s) in IaC & Container Security — start with REDACTED (3), REDACTED (3), REDACTED (3). — One of this dimension's main actionable groups (15 warning-level).
- Resolve the 6 High IaC finding(s) in IaC & Container Security — start with REDACTED, REDACTED, REDACTED. — One of this dimension's main actionable groups (6 issue-level).
- Resolve the 2 Low IaC finding(s) in IaC & Container Security — start with REDACTED, REDACTED. — One of this dimension's main actionable groups (2 recommendation-level).
D34 · Knowledge Freshness
Every significant source file has living knowledge — recently and meaningfully worked. Counted over 147 of the 206 production source files in this repository: the rest are under the ~2,400-byte size floor this dimension measures over.
D35 · Change Coupling
No strong hidden change-coupling between production files.
D36 · Supply-chain Provenance & Signing
0/4 supply-chain integrity signals present (provenance, signing, SBOM, pinned actions).
What to do
- Resolve the 4 REDACTED finding(s) in Supply-chain Provenance & Signing — start with REDACTED, REDACTED, REDACTED. — One of this dimension's main actionable groups (4 warning-level).
- Resolve the 4 REDACTED finding(s) in Supply-chain Provenance & Signing — start with REDACTED, REDACTED, REDACTED. — One of this dimension's main actionable groups (4 warning-level).
- Resolve the 1 REDACTED finding(s) in Supply-chain Provenance & Signing. — One of this dimension's main actionable groups (1 warning-level).
D43 · Malicious Dependencies
No dependency in any ecosystem this repository declares is published as malicious.
D44 · Platform End-of-Life
0 end-of-life runtime(s) and 0 end-of-life framework(s), read from 1 platform declaration(s) and 0 dependency declaration(s). This dimension reads what the repository says about ITSELF — a pinned target framework, a version file, a capped requires-python, a Rust toolchain pin, a framework major a constraint cannot move off. A FLOOR is deliberately never charged: `requires-python = ">=3.8"` states what the package SUPPORTS, not what it runs on, and a well-maintained library declares exactly that while running its own CI on a current release. The end-of-life facts are FROZEN and dated, so this dimension needs no network and answers identically inside a closed scan fence; as the table ages it loses recall and never precision, because a statement about support that ended in the past cannot become false. The OS layer of a container image is D31's question and the toolchain a CI workflow installs is D29's; this row is neither.
Frontend & cross-cutting dimensions
AX10 · Code composition
What to do
- The domain core is a small share of production code, but most of the rest matched no layer vocabulary at all — so this is not yet an anemic-domain finding. The namespace/path convention could not place that code, which makes the composition above a statement about the naming, not about the design. Name the layers (or check that the repository's conventions differ from the ones this check knows) before reading a thin domain into it.
AX3 · Project dependency cycles
AX4 · Dependency direction
M1 · Documentation (README)
M2 · Architecture documentation
- No Architecture Decision Records found — no conventional ADR directory, no numbered `NNNN-title` documents in any markup this check reads, and nothing ADR-shaped by content. Design rationale recorded elsewhere (a design-notes tree, a mailing list, pull-request discussion) is not visible to this check and is not re-findable per decision, so a future maintainer cannot ask why one choice was made and get an answer.
What to do
- Record your significant design decisions. Write one short document per decision, giving its date, the situation, the decision and its consequences, and keep them together with your other design documents. A docs/adr folder with each file named by number and title is the easiest place to find them.
M3 · Folder & project structure
M4 · Documentation accuracy
- integration/README.md names `hsic/options.go`, but no file or folder `hsic/options.go` exists. Checked without a model against the repository: its files and folders, the scripts and dependencies of every package.json, the projects, namespaces, package references and target frameworks of the .NET build, the SDK and Node pins, and the identifiers of every file that is not a document; the documents' own text never counts. A footprint generated at build time, read only by a platform, or living outside this repository is not seen, and this row is then wrong. — integration/README.md:107
- integration/README.md names `tsic/options.go`, but no file or folder `tsic/options.go` exists. Checked without a model against the repository: its files and folders, the scripts and dependencies of every package.json, the projects, namespaces, package references and target frameworks of the .NET build, the SDK and Node pins, and the identifiers of every file that is not a document; the documents' own text never counts. A footprint generated at build time, read only by a platform, or living outside this repository is not seen, and this row is then wrong. — integration/README.md:107
- nix/README.md documents the environment variable `CAP_NET_ADMIN`, but no code, script or configuration file names it. Checked without a model against the repository: its files and folders, the scripts and dependencies of every package.json, the projects, namespaces, package references and target frameworks of the .NET build, the SDK and Node pins, and the identifiers of every file that is not a document; the documents' own text never counts. A footprint generated at build time, read only by a platform, or living outside this repository is not seen, and this row is then wrong. — nix/README.md:126
- docs/ref/debug.md documents the environment variable `TS_DEBUG_KEY_PATH`, but no code, script or configuration file names it. Checked without a model against the repository: its files and folders, the scripts and dependencies of every package.json, the projects, namespaces, package references and target frameworks of the .NET build, the SDK and Node pins, and the identifiers of every file that is not a document; the documents' own text never counts. A footprint generated at build time, read only by a platform, or living outside this repository is not seen, and this row is then wrong. — docs/ref/debug.md:95
- docs/ref/debug.md documents the environment variable `TS_ALLOW_DEBUG_IP`, but no code, script or configuration file names it. Checked without a model against the repository: its files and folders, the scripts and dependencies of every package.json, the projects, namespaces, package references and target frameworks of the .NET build, the SDK and Node pins, and the identifiers of every file that is not a document; the documents' own text never counts. A footprint generated at build time, read only by a platform, or living outside this repository is not seen, and this row is then wrong. — docs/ref/debug.md:110
- docs/ref/policy.md links to `Headscale`, but `docs/ref/Headscale` does not exist. Checked without a model against the repository: its files and folders, the scripts and dependencies of every package.json, the projects, namespaces, package references and target frameworks of the .NET build, the SDK and Node pins, and the identifiers of every file that is not a document; the documents' own text never counts. A footprint generated at build time, read only by a platform, or living outside this repository is not seen, and this row is then wrong. — docs/ref/policy.md:246
- docs/ref/policy.md links to `Other`, but `docs/ref/Other` does not exist. Checked without a model against the repository: its files and folders, the scripts and dependencies of every package.json, the projects, namespaces, package references and target frameworks of the .NET build, the SDK and Node pins, and the identifiers of every file that is not a document; the documents' own text never counts. A footprint generated at build time, read only by a platform, or living outside this repository is not seen, and this row is then wrong. — docs/ref/policy.md:249
- docs/setup/requirements.md links to `The`, but `docs/setup/The` does not exist. Checked without a model against the repository: its files and folders, the scripts and dependencies of every package.json, the projects, namespaces, package references and target frameworks of the .NET build, the SDK and Node pins, and the identifiers of every file that is not a document; the documents' own text never counts. A footprint generated at build time, read only by a platform, or living outside this repository is not seen, and this row is then wrong. — docs/setup/requirements.md:46
- docs/setup/install/official.md documents the environment variable `HEADSCALE_VERSION`, but no code, script or configuration file names it. Checked without a model against the repository: its files and folders, the scripts and dependencies of every package.json, the projects, namespaces, package references and target frameworks of the .NET build, the SDK and Node pins, and the identifiers of every file that is not a document; the documents' own text never counts. A footprint generated at build time, read only by a platform, or living outside this repository is not seen, and this row is then wrong. — docs/setup/install/official.md:15
- docs/setup/install/official.md documents the environment variable `HEADSCALE_ARCH`, but no code, script or configuration file names it. Checked without a model against the repository: its files and folders, the scripts and dependencies of every package.json, the projects, namespaces, package references and target frameworks of the .NET build, the SDK and Node pins, and the identifiers of every file that is not a document; the documents' own text never counts. A footprint generated at build time, read only by a platform, or living outside this repository is not seen, and this row is then wrong. — docs/setup/install/official.md:16
What to do
- Reconcile the README with reality: integration/README.md names `hsic/options.go`, but no file or folder `hsic/options.go` exists; integration/README.md names `tsic/options.go`, but no file or folder `tsic/options.go` exists; nix/README.md documents the environment variable `CAP_NET_ADMIN`, but no code, script or configuration file names it; docs/ref/debug.md documents the environment variable `TS_DEBUG_KEY_PATH`, but no code, script or configuration file names it; docs/ref/debug.md documents the environment variable `TS_ALLOW_DEBUG_IP`, but no code, script or configuration file names it.
P1 · CI/CD gates
P2 · Observability
P3 · Security & performance tooling
What to do
- Enable Dependabot/Renovate or a dependency-review gate.
- Add gitleaks/trufflehog in CI to block PRs that introduce committed secrets.
P4 · Deployment & Rollback
P5 · DR & Backup
What to do
- Document RTO/RPO and a tested restore procedure (a backup config alone isn't disaster recovery).
- Enable purge protection / soft-delete (and prevent_destroy on critical resources) so data stores can't be lost to an accidental or malicious delete.
P6 · Release Hygiene
P7 · Outbound HTTP resilience
- `http.Client{` makes an outbound HTTP call, and nothing bounds it: no timeout, deadline, retry or circuit breaker is set for it here, and the client has no process-wide default. A slow or failing dependency will hold this service's request, thread or connection until the call gives up on its own — or never, for a client with no default timeout. — REDACTED:346
What to do
- Give every `http.Client` an explicit `Timeout` (never call `http.Get`/`http.Post` or `http.DefaultClient`, which have none), or build each request with `http.NewRequestWithContext` under a `context.WithTimeout`; add retry with back-off (`hashicorp/go-retryablehttp`) and a breaker (`sony/gobreaker`) around dependencies that fail.
P8 · Schema migrations
- GORM AutoMigrate builds the schema from the model at startup and keeps no migration history, so there is no reviewed, repeatable upgrade path for an existing production database — a renamed column is dropped and re-added rather than migrated. Adopt a versioned migration tool such as golang-migrate, goose or Atlas, so every schema change is a versioned file applied the same way in every environment. (×4) — hscontrol/db/versioncheck.go:101, hscontrol/db/db.go:182, hscontrol/db/db.go:292, …
What to do
- Replace GORM AutoMigrate with a versioned migration tool such as golang-migrate, goose or Atlas so the production schema can evolve safely and reproducibly.
PF1 · Benchmark discipline
PF2 · Allocation hygiene
What to do
- Raise allocation-aware density on the hot paths — currently 111 use(s) across 64,661 production line(s) (~1.7/1k). More of the idioms below on the allocation-heavy paths climbs this toward 10.
- Go: on hot paths, reuse buffers and objects through sync.Pool, preallocate slices and maps with make([]T, 0, n) / make(map[K]V, n), size builders with Grow, append with strconv.Append*, and reslice with buf[:0] instead of allocating anew.
X14 · Bypassable address classification
X15 · Unvalidated length from an untrusted reader
X2 · Cancellation propagation
- Only 8/9 functions that make a cancellable request (net/http, net.Dial) accept a context.Context or pass one on, so a request keeps running after whatever wanted it has given up — a cancelled request, a shutdown, an expired deadline. Take `ctx context.Context` as the first parameter and build the request with it (`http.NewRequestWithContext`, `DialContext`); where nothing could ever cancel the call, omitting it is a deliberate choice — judge against how the function is used.
- `loadDERPMapFromURL` calls `http.NewRequestWithContext(…)` but takes no context.Context and reaches none its caller controls, so its caller cannot cancel the request once it has started. Take `ctx context.Context` as the first parameter and build the request with it: `http.NewRequestWithContext(ctx, …)`, `(&net.Dialer{}).DialContext(ctx, …)`. — hscontrol/derp/derp.go:43
What to do
- Thread a context.Context through functions that make requests, so the work stops when its caller gives up.
X26 · Unsynchronised callback handoff
X28 · Index access outside its own emptiness guard
X3 · Exception handling
- `if err != nil` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter. (×37) — cmd/hi/run.go:115, cmd/hi/doctor.go:350, hscontrol/api/v2/api.go:234, …
- `if splitErr != nil` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter. — hscontrol/realip.go:97
- `if authErr != nil` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter. — hscontrol/state/state.go:2957
- `if err := json.Unmarshal(body, &listing); err != nil` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter. — tools/bump/registry.go:181
What to do
- Swallowed exception (caught, then discarded)
X30 · Support guard that admits what it rejects
Reference — by lens
| Lens | Score | Rating | Impact |
|---|---|---|---|
| Code Health | 85% | Strong | Strongest area. |
| Maturity | 63% | Adequate — gated by M2 | Capped at Fair by a Critical contributor — resolve it before relying on this lens. |
| Readiness | 50% | Adequate — gated by P7, P8 | Capped at Fair by a Critical contributor — resolve it before relying on this lens. |
| Security | 60% | Adequate — gated by D29, D36 | Capped at Fair by a Critical contributor — resolve it before relying on this lens. |
| Performance | 80% | Strong | Solid. |
Unscored — 1 check(s) recorded observations but carry no score
- X10 Duplicated predicate — 5 observation(s) recorded · Advisory — this card reports evidence and never carries a score.
Not evidenced — 3 control(s) we could not find positive evidence for
- C3 Audit Trail — Not assessed: these audit controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) that was not loaded for this repository — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of an idiom this check recognises is NOT evidence that this repository lacks audit controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
- C4 Data Retention — Not assessed: these retention controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) that was not loaded for this repository — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of an idiom this check recognises is NOT evidence that this repository lacks retention controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
- C5 Data-Subject Rights — Not assessed: these data-subject rights controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) that was not loaded for this repository — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of an idiom this check recognises is NOT evidence that this repository lacks data-subject rights controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
Not included — 75 check(s) not relevant to this codebase
- AC1 Text alternatives — No web markup found — accessibility is not applicable to this repository.
- AC2 Forms & labels — No web markup found — accessibility is not applicable to this repository.
- AC3 Page structure — No web markup found — accessibility is not applicable to this repository.
- AC4 Keyboard semantics — No web markup found — accessibility is not applicable to this repository.
- AC5 ARIA correctness — No web markup found — accessibility is not applicable to this repository.
- AC6 Visual & motion safety — No web markup found — accessibility is not applicable to this repository.
- AC7 A11y enforcement — No web markup found — accessibility is not applicable to this repository.
- AX1 Captive dependencies — Not applicable: this repository's Go imports no dependency-injection container and defines no container of its own — nothing that both registers and resolves bindings, and nothing that names two lifetimes — so nothing holds one lifetime's instance while handing out another's.
- AX2 Stateful singletons — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- AX5 Architecture & structure — not assessed — architecture style/structure is computed from a project graph (projects, types, module namespaces) that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- AX6 Interface segregation — not assessed — interface segregation is computed over a type surface that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- AX7 Slice cohesion — not applicable — not a vertical-slice architecture
- AX8 Test isolation — no test/production split to check
- AX9 CQS / query purity — no CQRS query handlers detected — query purity is not applicable to this codebase
- AXB2 Runtime readiness — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
- AXR1 Runtime accessibility — docker build failed (exit 1) — DEPRECATED: The legacy builder is deprecated and will be removed in a future release. Install the buildx component to build images with BuildKit: https://docs.docker.com/go/bui…; runtime evidence skipped This is a statement about this run, not a statement about your application: nothing here says the surface is inaccessible, only that it was never rendered.
- C1 Data Protection — Not assessed: these personal data controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) that was not loaded for this repository — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of an idiom this check recognises is NOT evidence that this repository lacks personal data controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
- C2 Access Controls — Not assessed: these authorization controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) that was not loaded for this repository — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of an idiom this check recognises is NOT evidence that this repository lacks authorization controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
- D1 Cyclomatic Complexity — cyclomatic complexity not measured — .go exposed no member bodies
- D10 Test Quality — ~104230 lines of test source are present (.go) but no test cases reached the test census for this repository — no test root we could resolve declared them, or the files we read declare no cases in a test framework we recognise — so skipped/assertion-free tests couldn't be counted. Not scored — this is a gap in the analyzer, not a finding about this repository.
- D11 Test Reliability — Test reliability not included — the .go suite was found but not re-run
- D15 Churn × Complexity Hotspots — complexity unreadable for .go — churn × complexity hotspots could not be measured
- D18 Solution Shape — D18 scores the shape of a .NET solution; this repository has no .NET solution or project files, so the dimension does not apply.
- D2 Cognitive Complexity — cognitive complexity not measured — .go exposed no member bodies
- D22 Internal API Consistency — The exposed public-API surface could not be collected — no C#/VB projects loaded.
- D23 Boundary Type-Coupling — No bounded-context organisation was detected either — neither a context-shaped layout, nor 2+ sibling source directories each declaring an aggregate root, nor 2+ projects each declaring an entity of their own. Declaring this codebase's bounded contexts (≥2) would let cross-boundary type coupling be assessed. Declare them in `.codehealth/config.yaml` at the repository root (create it if absent), mapping each context name to the module-path or namespace prefixes that belong to it — e.g. `architecture:` → `contexts:` → `Billing: ["src/billing", "Acme.Billing"]`, `Catalog: ["src/catalog", "Acme.Catalog"]`.
- D24 Comment Value — No inline comments to assess — comment value is not applicable here.
- D25 ADR Conformance — no ADRs to check
- D26 Project Cohesion — D26 measured no build unit over this repository's .go source. Not scored: this is a gap in the analyzer, not a verdict about this repository.
- D27 Navigability — No calls could be sampled, so navigability was not assessed — tracing effort is measured over resolved call sites and this target exposed none. Not scored — this is a gap in the analyzer's reach, not a verdict about this repository.
- D28 Secrets (history) — Scanner output unparseable — not a clean result
- D3 God Classes — Most of this repository's production source (.go) was not read by god-class detection, so type and module size was not assessed for the languages that are the product — whatever else this pass did read is not this repository's type and module size. Not scored — this is a gap in the analyzer, not a verdict about this repository.
- D32 Data Compliance (PII/GDPR) — 5 file(s) were not parsed by semgrep — the PII/GDPR ruleset never ran over them
- D37 Vulnerability-disclosure Policy — No vulnerability-disclosure policy file found (SECURITY.md/.markdown/.rst/.txt at root or under .github/.forgejo/.gitea/docs, .well-known/security.txt). A coordinated-disclosure policy may live off-repo, so this is not evidenced rather than failed.
- D39 IL Efficiency — D39 measures the IL emitted by a .NET build; this repository has no .NET solution or project files, so the dimension does not apply.
- D4 Code Duplication — Duplication not measured — .go not exposed to the token comparison
- D40 Network Egress Confinement — No Kubernetes/orchestration workloads found in the repository manifests; network egress policy is a cluster-native control that may live at the platform/firewall layer, so there is nothing to assess here.
- D41 Kernel & Syscall Confinement — No Kubernetes/orchestration workloads found in the repository manifests; seccomp/AppArmor/SELinux confinement is a workload-level control, so there is nothing to assess here.
- D42 Runtime Threat Enforcement — No Kubernetes/orchestration workloads found in the repository manifests; runtime threat-detection and admission-control policy are cluster-level controls, so there is nothing to assess here.
- D5 Coupling — Not applicable — this Go build ships 1 production module(s), so there is no coupling BETWEEN modules to measure. (Its test and non-production modules are not part of the shipped graph.)
- D6 Cohesion (LCOM4) — No production classes were analyzable, so cohesion (LCOM4) was not measured (the solution likely failed to load or has no production code).
- D7 Architectural Integrity — no checkable ADRs, and no project-reference graph for the cycle pass to read — so this dimension makes no claim about dependency cycles in either direction (where this repository's language has an import-cycle lens, cycles are reported there). Architectural integrity not assessed
- D8 Code Coverage — Coverage not included — suite not readable by the collector
- DM1 Domain Modelling — not scored — this repository shows none of the 3 signals this lens looks for
- ED1 Event-Driven — not scored — this repository shows none of the 3 signals this lens looks for
- ED5 Idempotency — This check finds retry-prone mutations (command handlers and message/event consumers) by walking the repository's declared types, and none was loaded here, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
- ES1 Event Sourcing — not scored — this repository shows none of the 3 signals this lens looks for
- GD1 Unfinished & placeholder code — no source files were read — this check reads C#, F#, JavaScript/TypeScript, Dart, Ruby and Scala, and none was read for this repository's product. That is a limit of the analyzer, not a finding about your code.
- IC1 Incompleteness & stubs — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- P12 CI test-gate honesty — Reported, not scored — and nothing was matched here. The coverage check applies to any stack, and the automatic-re-run check to any GitHub-Actions workflow, but the checks for excluded tests, skipped tests and sleep-based synchronisation currently recognise only some ecosystems' test-runner idioms, so on a repository built with another stack the zeros below mean 'not checked', not 'clean'.
- P9 Domain vs controller coverage — no coverage report found on disk — produce a coverage report in a standard format (`go test -coverprofile=coverage.out ./...`) and commit it — a hosted scan measures a clone of the repository, so a report that exists only in a working tree, a CI runner's or your own, never reaches it; the artefact is commonly gitignored, so `git add -f` that one file (or un-ignore its path) and commit it alongside the code it measures, or wire coverage collection into CI, to enable this cross-layer check
- PF3 Async & latency hygiene — Performance was not assessed: this lens reads a source model that was not loaded for this repository, because the repository is written in a language this lens does not yet model or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository — in particular it is NOT a statement that this repo is unpackaged or performance-careless.
- S1 Web-Security Posture — Not assessed: these web-security controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) that was not loaded for this repository — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of an idiom this check recognises is NOT evidence that this repository lacks web-security controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
- SC1 Supply-chain hygiene — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
- X1 Async correctness — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- X12 Unreachable branch — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- X13 Undrained process stream — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- X16 Unfloored truncation loop — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- X17 Uncapped recursion over a caller-supplied document — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- X18 Disposal-pattern correctness — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- X19 Unrestored process-global state — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- X20 Mistyped argument guard — This check asks whether an argument guard reports an EMPTY value as a NULL one, which needs a language that throws a null-specific argument exception — .NET's ArgumentNullException, the JVM's NullPointerException, Dart's ArgumentError.notNull. This repository contains none of those languages: the ones it is written in have a single exception for a bad argument, so there is no pair of exceptions to confuse and nothing here for it to assess. Not a gap in the analyzer and not a finding about your code.
- X21 Side-effecting pattern guard — Not applicable: this check looks for a pattern guard or `case` label that increments, decrements or assigns while the switch is deciding whether it matches, and in this repository's languages none can. Go's `++`, `--` and assignments are STATEMENTS, not expressions, so none of them can appear in a `case` expression or anywhere else in a condition, and a type switch's cases are types. Not a gap in the analyzer and not a finding about your code.
- X22 Contradicted release guard — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- X23 Unguarded diagnostic materialisation — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- X24 Document value interpolated into markup unescaped — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- X25 Inert configuration knob — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- X27 Collection changed while being enumerated — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- X29 Per-element action decided by a fixed element — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- X32 Type resolved by simple name across every loaded assembly — This check is about how a .NET program searches the assemblies loaded into its process for a type, and this repository contains no .NET source, so there is nothing here for it to assess. Not a gap in the analyzer and not a finding about your code.
- X4 Structured logging — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- X5 Nullable reference types — Not applicable: this check asks whether the null-typed discipline a language offers is switched on, and how much of that the assertion operator takes back, and in this repository's languages there is no such switch and no such operator. Go's type system has no nullable and non-nullable types — every pointer, map, slice and interface is nil-able at every position, there is no switch that turns null checking on, and the compiler produces no nullability warning for an operator to silence. Not a gap in the analyzer and not a finding about your code.
- X6 Hand-rolled structured-format parsing — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
- X7 Silent fallback defaults — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- X9 Subsumed condition operand — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
Appendix A — Findings (grouped)
Critical — 18 finding(s)
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
Serious — 189 finding(s)
- TodoComment hscontrol/poll.go:303
- TodoComment hscontrol/oidc.go:232
- TodoComment hscontrol/oidc.go:233
- TodoComment hscontrol/oidc.go:316
- TodoComment hscontrol/oidc.go:347
- TodoComment hscontrol/oidc.go:649
- TodoComment hscontrol/noise.go:573
- TodoComment hscontrol/auth.go:177
- TodoComment hscontrol/auth.go:451
- TodoComment REDACTED:225
- TodoComment hscontrol/api/v1/apikeys.go:244
- TodoComment hscontrol/db/preauth_keys_test.go:154
- TodoComment hscontrol/db/preauth_keys.go:206
- TodoComment hscontrol/db/preauth_keys.go:234
- TodoComment hscontrol/db/api_key_test.go:181
- TodoComment hscontrol/db/api_key.go:17
- TodoComment hscontrol/db/api_key.go:192
- TodoComment hscontrol/db/api_key.go:209
- TodoComment hscontrol/db/api_key.go:228
- TodoComment hscontrol/types/api_key.go:41
- TodoComment hscontrol/db/versioncheck.go:31
- TodoComment hscontrol/db/secret.go:44
- TodoComment hscontrol/db/secret.go:59
- TodoComment hscontrol/db/secret.go:116
- TodoComment hscontrol/db/secret.go:176
- Swallowed exception (caught, then discarded) cmd/hi/run.go:115
- Swallowed exception (caught, then discarded) cmd/hi/doctor.go:350
- Swallowed exception (caught, then discarded) hscontrol/realip.go:97
- Swallowed exception (caught, then discarded) hscontrol/api/v2/api.go:234
- Swallowed exception (caught, then discarded) hscontrol/derp/server/derp_server.go:95
- Swallowed exception (caught, then discarded) hscontrol/mapper/mapper.go:242
- Swallowed exception (caught, then discarded) hscontrol/policy/policyutil/reduce.go:70
- Swallowed exception (caught, then discarded) hscontrol/policy/v2/sshtest.go:611
- Swallowed exception (caught, then discarded) hscontrol/policy/v2/policy.go:1297
- Swallowed exception (caught, then discarded) hscontrol/policy/v2/policy.go:1315
- Swallowed exception (caught, then discarded) hscontrol/policy/v2/policy.go:1463
- Swallowed exception (caught, then discarded) hscontrol/policy/v2/compiled.go:570
- Swallowed exception (caught, then discarded) hscontrol/policy/v2/compiled.go:897
- Swallowed exception (caught, then discarded) hscontrol/state/state.go:2957
- Swallowed exception (caught, then discarded) hscontrol/types/node.go:798
- Swallowed exception (caught, then discarded) hscontrol/types/config.go:541
- Swallowed exception (caught, then discarded) hscontrol/types/config.go:1189
- Swallowed exception (caught, then discarded) hscontrol/util/util.go:99
- Swallowed exception (caught, then discarded) hscontrol/util/dns.go:119
- Swallowed exception (caught, then discarded) hscontrol/util/dns.go:143
- Swallowed exception (caught, then discarded) hscontrol/util/dns.go:193
- Swallowed exception (caught, then discarded) integration/helpers.go:209
- Swallowed exception (caught, then discarded) integration/helpers.go:217
- Swallowed exception (caught, then discarded) integration/helpers.go:225
- Swallowed exception (caught, then discarded) integration/helpers.go:395
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- Schema created by GORM AutoMigrate (no migration path) hscontrol/db/versioncheck.go:101
- Schema created by GORM AutoMigrate (no migration path) hscontrol/db/db.go:182
- Schema created by GORM AutoMigrate (no migration path) hscontrol/db/db.go:292
- Schema created by GORM AutoMigrate (no migration path) hscontrol/db/db.go:302
- Dependency pinned to a stale untagged commit: github.com/davecgh/go-spew
- Dependency pinned to a stale untagged commit: github.com/tcnksm/go-latest
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- Outbound HTTP without resilience REDACTED:346
- Function without context.Context: loadDERPMapFromURL hscontrol/derp/derp.go:43
Minor — 30 finding(s)
- README/code drift integration/README.md:107
- README/code drift integration/README.md:107
- README/code drift nix/README.md:126
- README/code drift docs/ref/debug.md:95
- README/code drift docs/ref/debug.md:110
- README/code drift docs/ref/policy.md:246
- README/code drift docs/ref/policy.md:249
- README/code drift docs/setup/requirements.md:46
- README/code drift docs/setup/install/official.md:15
- README/code drift docs/setup/install/official.md:16
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- Duplicated predicate hscontrol/state/debug.go:316
- Duplicated predicate hscontrol/api/v2/users.go:166
- Duplicated predicate hscontrol/policy/v2/compiled.go:237
- Duplicated predicate hscontrol/api/v1/nodes.go:434
- Duplicated predicate cmd/hi/docker.go:640
- REDACTED
- REDACTED
- Off-boarding risk: anonymized user #1
- No ADRs found
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- No ADRs
- Not all functions that make a request accept a context.Context
Minor — 1 finding(s)
- Outdated: github.com/oapi-codegen/runtime
Appendix B — Reproduction & audit trail
| Dimension | Tool | Version | Command | Findings | Raw output |
|---|---|---|---|---|---|
| D28 · Secrets (history) | gitleaks | — | gitleaks detect --no-banner --config /opt/gitleaks-rules/watchdog-gitleaks.toml --report-format json --report-path /tmp/watchdog-gitleaks-a6d1dd408d934754b5c6534b42941405/history.json --exit-code 0 --source . | 0 | — |
| D28 · Secrets (history) | gitleaks | — | gitleaks detect --no-git --no-banner --config /opt/gitleaks-rules/watchdog-gitleaks.toml --report-format json --report-path /tmp/watchdog-gitleaks-a6d1dd408d934754b5c6534b42941405/tree.json --exit-code 0 --source . | 0 | artifacts/raw/gitleaks-tree.json |
| D29 · Static Analysis (SAST) | semgrep | — | semgrep --config /opt/semgrep-rules/security-audit.yml --config /opt/semgrep-rules/owasp-top-ten.yml --config /opt/semgrep-rules/watchdog-sast.yml --json --quiet --timeout 10 --timeout-threshold 3 --metrics off . | 19 | artifacts/raw/semgrep.json |
| D30 · Dependency Vulnerabilities | osv-scanner | — | osv-scanner --format json --recursive --experimental-disable-plugins transitivedependency/requirements --experimental-disable-plugins dotnet/csproj --experimental-disable-plugins dotnet/nugetcpm . /tmp/codehealth-osv-sbom-1fbc602bda304e18bbbe95e6e883a3ac | 6 | artifacts/raw/osv-scanner.json |
| D31 · IaC & Container Security | trivy | — | trivy config --format json --quiet . | 23 | artifacts/raw/trivy-config.json |
| D32 · Data Compliance (PII/GDPR) | semgrep | — | semgrep: not applicable — No personal data was found crossing a boundary the PII/GDPR ruleset checks — nothing written to a log or console sink, placed in a URL or query string, or persisted to browser storage. That is a clean result for the LEAK surface only: this ruleset detects personal data escaping, it does not inventory the personal data a repository holds, so it is not evidence that this repository has no personal-data surface. The personal-data map (Appendix C) and the C1-C5 compliance cards are what speak to that. semgrep could not parse 5 file(s) — `hscontrol/api/v1/types.go`, `hscontrol/policy/v2/types.go`, `hscontrol/state/state.go`, `REDACTED`, `integration/tsic/tsic.go` — so the PII/GDPR sweep did not cover the unparsed regions of them; rows reported elsewhere in those files are real. | 0 | — |
| D37 · Vulnerability-disclosure Policy | disclosure | — | disclosure: not applicable — No vulnerability-disclosure policy file found (SECURITY.md/.markdown/.rst/.txt at root or under .github/.forgejo/.gitea/docs, .well-known/security.txt). A coordinated-disclosure policy may live off-repo, so this is not evidenced rather than failed. | 0 | — |
| D40 · Network Egress Confinement | runtime-hardening | — | runtime-hardening: not applicable — No Kubernetes/orchestration workloads found in the repository manifests; network egress policy is a cluster-native control that may live at the platform/firewall layer, so there is nothing to assess here. | 0 | — |
| D41 · Kernel & Syscall Confinement | runtime-hardening | — | runtime-hardening: not applicable — No Kubernetes/orchestration workloads found in the repository manifests; seccomp/AppArmor/SELinux confinement is a workload-level control, so there is nothing to assess here. | 0 | — |
| D42 · Runtime Threat Enforcement | runtime-hardening | — | runtime-hardening: not applicable — No Kubernetes/orchestration workloads found in the repository manifests; runtime threat-detection and admission-control policy are cluster-level controls, so there is nothing to assess here. | 0 | — |
| D43 · Malicious Dependencies | osv-scanner | — | osv-scanner --format json --recursive --experimental-disable-plugins transitivedependency/requirements --experimental-disable-plugins dotnet/csproj --experimental-disable-plugins dotnet/nugetcpm . /tmp/codehealth-osv-sbom-1fbc602bda304e18bbbe95e6e883a3ac | 0 | artifacts/raw/osv-scanner.json |