Public report — warpgate, published 29 Sep 2026. Concrete security findings (which rule fired, in which file, on which line; CVE IDs, secret matches, dependency versions) are REDACTED in this version; ask the repo owner for the full report.
Public
Codebase survey Measured under the Code Assurance Index · rubric rubric-2026.09.17 (frozen) · verify this survey Filed cd_7b4a29fda97c48709d054b86b97b3941 Filed 29 September 2026, 10:42 UTC Public

Warp-Tech/warpgate

Measured 29 September 2026, 10:33 UTC

60% Adequate
CriticalWeakAdequateStrongExemplary

Medium · 79,882 LoC · 28 projects · rebuild ~0.6 person-years · weakest lens: Code Health (49%)

Findings by grade

28 critical 334 serious 23 minor 31 could not be resolved — could be critical — see Limitations

This survey was produced by

Watchdog
Producer
Canine Development
Analyzer
Watchdog engine 1.0.0
Measured
29 September 2026, 10:33 UTC

A measurement, not a certificate. The Code Assurance Index does not certify, approve or guarantee this codebase; it records a reproducible number and the evidence it was computed from. The standard is authored by Canine Development, who also build Watchdog — its only implementation today. That is said here so the number is checked rather than believed.

Grounded in facts. Every number here is computed, not narrated — reproducible, tool-backed, and traceable to a line of code. How to trust this ▸

60/64dimensions tool-verifieddeterministic · confidence 1.0 · 4 LLM-assisted, advisory
345findings with an exact file:lineof 385 — the remainder are repo-wide signals (a dimension-level measurement, not a single line); open any file:line and verify
64/138dimensions across the health lenses79882 LoC · 28 projects — wide & deep
Chapters

Executive summary

The system holds an adequate standing with a health score of 60%, indicating a workable asset that carries real, manageable risk. While the domain logic is sound, the underlying code quality creates friction that threatens long-term delivery speed and maintenance costs. This is not a fragile system, but it is one that requires immediate attention to prevent technical debt from compounding into operational delays.

The value at stake is significant, with nearly 80,000 lines of production code representing a substantial business asset. Rebuilding this from scratch would cost approximately €88,000 and require six months of engineering effort, highlighting the importance of preserving and improving the existing foundation. The codebase is dense with logic, leaving little room for boilerplate, which means every line of code directly impacts business functionality and future development velocity.

The primary risk lies in code health, which scores poorly at 49%. This weakness means the code is difficult to maintain, increasing the likelihood of defects and slowing down feature delivery. High complexity and poor structure create a ripple effect, where small changes require disproportionate effort and testing, ultimately inflating costs and delaying time-to-market. This is the most critical area to address to protect the business from escalating maintenance burdens.

A second concern is architectural cohesion, scoring 69%. While not critical, the architecture shows signs of drift, with oversized files and unclear boundaries that could lead to integration issues as the team scales. The system’s maturity and production readiness are stronger, suggesting that operational stability is currently secure, but this could erode if code quality continues to degrade. Security exposure is moderate, requiring vigilance but not immediate crisis management.

What is genuinely good is the strong domain modeling and event sourcing implementation, which provide a solid logical foundation. The system is well-tested and observable, ensuring that changes can be deployed with confidence. These strengths offer a stable base upon which to build improvements, reducing the risk of introducing new bugs during remediation efforts.

Focus first on deleting dead files and unused exports. This action offers the highest leverage, as it immediately reduces maintenance costs and rebuild estimates without requiring significant engineering effort. By removing zero-value code, the team can clear the path for more impactful improvements, ensuring that future investments in code health and architecture yield the best possible return.

How the score is built — each lens's share of the headline Width is the lens's weight in the worst-heaviest fold (the weakest area pulls hardest); colour is that lens's own band. A lens fixes the score in proportion to its width.
Code Health 49% · 46% weightMaturity 65% · 25% weightSecurity 68% · 14% weightArchitecture 69% · 8% weightReadiness 79% · 4% weightDomain Modelling 100% · 2% weightEvent Sourcing 100% · 1% weight

Raise Code Health 49 → 70 (the Healthy floor) ⇒ headline 60 → ~68.

Code composition — where the lines go
Tests 100%
New since the last scan (60+)

60 finding(s) are new versus the previous scan (2026-09-13) — surfaced by this scheduled scan itself, no pull request required.

  • D1 · warpgate_core::credential_encryption::rewrite_all (cyclomatic 16) warpgate-core/src/credential_encryption.rs
  • D2 · Connector::authenticate_session (cognitive 24) warpgate-protocol-ssh/src/client/mod.rs
  • D2 · Connector::_handle_auth_result (cognitive 19) warpgate-protocol-ssh/src/client/mod.rs
  • D2 · warpgate_protocol_kubernetes::server::handlers::_handle_websocket_request_inner (cognitive 16) warpgate-protocol-kubernetes/src/server/handlers.rs
  • D3 · ClassTooLong: AuditEvent warpgate-common/src/audit.rs
  • D3 · MethodTooLong: Connector.authenticate_session warpgate-protocol-ssh/src/client/mod.rs
  • D3 · FileTooLong: src/audit.rs warpgate-common/src/audit.rs
  • D3 · FunctionTooLong: warpgate_protocol_kubernetes::server::handlers::_handle_websocket_request_inner warpgate-protocol-kubernetes/src/server/handlers.rs
  • D3 · FunctionTooLong: warpgate_protocol_http::proxy::proxy_ws_inner warpgate-protocol-http/src/proxy.rs
  • D4 · Members sharing a duplicated core (4 members, 50+ identical tokens) warpgate-common/src/auth/state.rs
  • D4 · Duplicated block (13 lines × 2) warpgate-protocol-mysql/src/client.rs
  • D4 · Duplicated block (9 lines × 2) warpgate-common/src/audit.rs
  • D4 · Duplicated block (9 lines × 2) warpgate-common/src/audit.rs
  • D4 · Duplicated block (8 lines × 6) warpgate-common/src/audit.rs
  • D4 · Duplicated block (14 lines × 2) warpgate-common/src/audit.rs
  • D5 · Unstable project warpgate-web-desktop
  • D5 · Unstable project warpgate-web-ssh
  • D5 · Off the main sequence: warpgate-aws
  • D5 · Off the main sequence: warpgate-ca
  • D5 · Off the main sequence: warpgate-sso
  • D5 · Off the main sequence: warpgate-admin
  • D5 · Off the main sequence: warpgate-db-entities
  • D5 · Off the main sequence: warpgate-common-http
  • D5 · Off the main sequence: warpgate-database-protocols
  • D5 · Off the main sequence: warpgate-desktop-ui
  • D5 · Off the main sequence: warpgate-ldap
  • D5 · Off the main sequence: warpgate-tls
  • D5 · Off the main sequence: warpgate-common
  • D15 · Hotspot: warpgate-common/src/error.rs warpgate-common/src/error.rs
  • D15 · Hotspot: warpgate-core/src/credential_encryption.rs warpgate-core/src/credential_encryption.rs
  • D22 · Inconsistent naming for standard I/O operations. `FramedRead` uses `read` (standard Rust `Read` trait name), while `FramedWrite` uses `write_all` (standard Rust `Write` trait method for full buffer writes). This creates asymmetry in the API surface.
  • D22 · Inconsistent constructor patterns for wrapping streams. `StreamWrapper` uses a static factory method `from_inner`, while `Framed` uses `new` and `new_with_leftover`. This forces users to remember different instantiation patterns for similar wrapper types.
  • D22 · Inconsistent return types for `into_inner`. `StreamWrapper.into_inner` returns the inner type directly, while `Framed.into_inner` returns a tuple `(InnerStream, BytesMut)`. This breaks the expectation that `into_inner` always returns the wrapped inner component in a consistent shape, forcing users to handle the tuple unpacking for `Framed` specifically.
  • D22 · Inconsistent return types for `get_inner`/`get_inner_mut`. `StreamWrapper` returns the inner stream directly, while `Framed` returns a tuple of references. This inconsistency requires different handling code depending on which wrapper type is being used.
  • D30 · REDACTED
  • D30 · REDACTED
  • D31 · REDACTED
  • D44 · End-of-life runtime: .NET net6.0
  • R10 · Duplicated block (28 lines × 2 locations) warpgate-web/src/gateway/WebDesktop.svelte
  • R10 · Duplicated block (23 lines × 2 locations) warpgate-web/src/admin/config/AccessRoles.svelte
  • R10 · Duplicated block with local edits (19 matched lines × 2 locations) warpgate-web/src/admin/config/Parameters.svelte
  • R10 · Duplicated block (17 lines × 2 locations) warpgate-web/src/admin/player/DesktopRecordingPlayer.svelte
  • R10 · Duplicated block (16 lines × 3 locations) warpgate-web/src/admin/config/AccessRoles.svelte
  • R10 · Duplicated block (16 lines × 2 locations) warpgate-web/src/admin/config/ldap/CreateLdapServer.svelte
  • R10 · Duplicated block (15 lines × 2 locations) warpgate-web/src/admin/config/AccessRole.svelte
  • R10 · Duplicated block (15 lines × 3 locations) warpgate-web/src/admin/config/AccessRole.svelte
  • R10 · Duplicated block (11 lines × 2 locations) REDACTED
  • R10 · Duplicated block (11 lines × 2 locations) warpgate-web/src/gateway/lib/certificateStore.ts
  • R10 · Duplicated block (9 lines × 2 locations) warpgate-web/src/admin/lib/api.ts
  • R10 · Duplicated block (7 lines × 2 locations) warpgate-web/src/admin/status/Session.svelte
  • R10 · Duplicated block (5 lines × 2 locations) REDACTED
  • R2 · Complex function reset (cyclomatic 12, cognitive 7) warpgate-web/src/admin/config/secret-backends/SecretBackendModal.svelte
  • R2 · Complex function recordingMetadataToFieldSet (cyclomatic 12, cognitive 5) warpgate-web/src/common/recordings.ts
  • R7 · Dead file (~500 LoC) warpgate-web/src/admin/log-viewer/LogViewer.svelte
  • R7 · Dead file (~372 LoC) REDACTED
  • R7 · Dead file (~221 LoC) warpgate-web/src/common/SecretRefInput.svelte
  • R7 · Dead file (~160 LoC) warpgate-web/src/common/recordings.ts
  • R7 · Dead file (~135 LoC) warpgate-web/src/common/duration.ts
  • R7 · Dead file (~126 LoC) warpgate-web/src/admin/config/targets/Target.svelte
  • R7 · Dead file (~111 LoC) warpgate-web/src/admin/CreateOtpModal.svelte

A full-fidelity diff against the previous run's complete recorded findings — line-move tolerant: a finding that only shifted line counts as unchanged, only genuinely new titles/files surface here.

Rebuild cost & value ~ Modeled — €29,000–€150,000
Cost to rebuild€29,000–€150,000 (0.3–0.9 person-years (489–1,552 h), ~1–2 engineers)
Domain complexityLow — harder problems cost more per line
Quality factor0.8× (at 60% quality) — the last 20% of quality is most of the work
Size & shapeMedium · effort split not classified (source measured from disk; the effort-tier breakdown is a C#-only syntax walk)

This codebase represents roughly ~0.6 person-years of build effort (about ~€88,000 to rebuild). Its weakest lens is Code Health at 49% — the part of that asset most exposed by the findings below.

How we model this: boilerplate at a scaffolding rate + logic × domain Low (×0.9) — library/CLI × a 0.8× quality factor, at €60–95/h; indicative, ±~30% · size measured directly from source · effort from total production LoC as straight-line logic (the tier split is a C#-only syntax walk), a conservative lower bound. Indicative only — most sensitive to the hourly rate and the domain tier (both tunable in config).

Top priorities

The highest-leverage moves; the full ranked list is in the Roadmap below.

1
Delete the dead files and unused exports — every line is maintenance cost and rebuild-estimate inflation with zero runtime value.
+9.6 pts · Medium effort · Dead Code
2
Enable <Nullable>enable</Nullable> across all projects and resolve warnings rather than suppressing with `!`.
+9.6 pts · Medium effort · Nullable reference types
3
Split each oversized file along the responsibilities already in it, into smaller focused modules in the same package.
+8.2 pts · Medium effort · Large Files

Diagnosis — what's actually going on

Value concentrated against a weak lens · Medium · Value at risk
This is a Medium asset (~0.6 person-years to rebuild), and its weakest lens is Code Health at 49%. The operational and business risk on an asset this size concentrates there — that's where remediation buys the most protection.
Evidence: valuation: Medium, ~0.6 person-years rebuild (79,882 LoC) · weakest lens: Code Health 49%
→ Direct remediation budget at Code Health first — highest risk-reduction per euro on an asset this size.
Highest-leverage move · Medium · Leverage
Of everything flagged, the best return on effort is: Delete the dead files and unused exports — every line is maintenance cost and rebuild-estimate inflation with zero runtime value. The rest can wait behind it.
Evidence: priority ranking: top of 5 ranked by impact/effort
→ Delete the dead files and unused exports — every line is maintenance cost and rebuild-estimate inflation with zero runtime value.

Architecture — module dependency graph

Project dependencies, layered top-to-bottom; arrows show direction. Any dashed red edge points upward or sideways — a layering smell or cycle. A clean layered graph has none.

arch warpgate warpgate warpgate-ca warpgate-ca warpgate->warpgate-ca warpgate-common warpgate-common warpgate->warpgate-common warpgate-core warpgate-core warpgate->warpgate-core warpgate-db-entities warpgate-db-entities warpgate->warpgate-db-entities warpgate-protocol-http warpgate-protocol-http warpgate->warpgate-protocol-http warpgate-protocol-kubernetes warpgate-protocol-kubernetes warpgate->warpgate-protocol-kubernetes warpgate-protocol-mysql warpgate-protocol-mysql warpgate->warpgate-protocol-mysql warpgate-protocol-postgres warpgate-protocol-postgres warpgate->warpgate-protocol-postgres warpgate-protocol-rdp warpgate-protocol-rdp warpgate->warpgate-protocol-rdp warpgate-protocol-ssh warpgate-protocol-ssh warpgate->warpgate-protocol-ssh warpgate-protocol-vnc warpgate-protocol-vnc warpgate->warpgate-protocol-vnc warpgate-tls warpgate-tls warpgate->warpgate-tls warpgate-aws warpgate-aws warpgate-common->warpgate-aws warpgate-common->warpgate-ca warpgate-common->warpgate-tls warpgate-common-http warpgate-common-http warpgate-common-http->warpgate-common warpgate-common-http->warpgate-core warpgate-common-http->warpgate-db-entities warpgate-core->warpgate-aws warpgate-core->warpgate-ca warpgate-core->warpgate-common warpgate-core->warpgate-db-entities warpgate-db-migrations warpgate-db-migrations warpgate-core->warpgate-db-migrations warpgate-core->warpgate-tls warpgate-db-entities->warpgate-aws warpgate-db-entities->warpgate-common warpgate-db-entities->warpgate-tls warpgate-db-migrations->warpgate-ca warpgate-db-migrations->warpgate-common warpgate-db-migrations->warpgate-db-entities warpgate-desktop-auth warpgate-desktop-auth warpgate-desktop-auth->warpgate-common warpgate-desktop-auth->warpgate-common-http warpgate-desktop-auth->warpgate-core warpgate-protocol-http->warpgate-aws warpgate-protocol-http->warpgate-ca warpgate-protocol-http->warpgate-common warpgate-protocol-http->warpgate-common-http warpgate-protocol-http->warpgate-core warpgate-protocol-http->warpgate-db-entities warpgate-protocol-http->warpgate-tls warpgate-web-clients-common warpgate-web-clients-common warpgate-protocol-http->warpgate-web-clients-common warpgate-web-desktop warpgate-web-desktop warpgate-protocol-http->warpgate-web-desktop warpgate-web-ssh warpgate-web-ssh warpgate-protocol-http->warpgate-web-ssh warpgate-protocol-kubernetes->warpgate-aws warpgate-protocol-kubernetes->warpgate-ca warpgate-protocol-kubernetes->warpgate-common warpgate-protocol-kubernetes->warpgate-common-http warpgate-protocol-kubernetes->warpgate-core warpgate-protocol-kubernetes->warpgate-db-entities warpgate-protocol-kubernetes->warpgate-tls warpgate-protocol-mysql->warpgate-aws warpgate-protocol-mysql->warpgate-common warpgate-protocol-mysql->warpgate-common-http warpgate-protocol-mysql->warpgate-core warpgate-protocol-mysql->warpgate-tls warpgate-protocol-postgres->warpgate-aws warpgate-protocol-postgres->warpgate-common warpgate-protocol-postgres->warpgate-common-http warpgate-protocol-postgres->warpgate-core warpgate-protocol-postgres->warpgate-db-entities warpgate-protocol-postgres->warpgate-tls warpgate-protocol-rdp->warpgate-common warpgate-protocol-rdp->warpgate-core warpgate-protocol-rdp->warpgate-db-entities warpgate-protocol-rdp->warpgate-desktop-auth warpgate-protocol-rdp->warpgate-tls warpgate-protocol-ssh->warpgate-aws warpgate-protocol-ssh->warpgate-common warpgate-protocol-ssh->warpgate-common-http warpgate-protocol-ssh->warpgate-core warpgate-protocol-ssh->warpgate-db-entities warpgate-protocol-ssh->warpgate-tls warpgate-protocol-vnc->warpgate-common warpgate-protocol-vnc->warpgate-common-http warpgate-protocol-vnc->warpgate-core warpgate-protocol-vnc->warpgate-db-entities warpgate-protocol-vnc->warpgate-desktop-auth warpgate-protocol-vnc->warpgate-tls warpgate-tls->warpgate-ca warpgate-web-clients-common->warpgate-common warpgate-web-clients-common->warpgate-core warpgate-web-clients-common->warpgate-db-entities warpgate-web-desktop->warpgate-common warpgate-web-desktop->warpgate-common-http warpgate-web-desktop->warpgate-core warpgate-web-desktop->warpgate-db-entities warpgate-web-desktop->warpgate-protocol-rdp warpgate-web-desktop->warpgate-protocol-vnc warpgate-web-desktop->warpgate-web-clients-common warpgate-web-ssh->warpgate-common warpgate-web-ssh->warpgate-common-http warpgate-web-ssh->warpgate-core warpgate-web-ssh->warpgate-db-entities warpgate-web-ssh->warpgate-protocol-ssh warpgate-web-ssh->warpgate-web-clients-common __more__ +8 more projects

Architecture — module dependency matrix

Rows and columns are the same modules, ordered so that a module only depends on ones above it. A cell means the row depends on the column, and its number is how many type pairs create that dependency. Read one thing: is anything above the diagonal? A mark there is a dependency cycle. (A cycle is all this shows — an unusual but cycle-free dependency sits below the diagonal like any other.)

685 modules, 1072 dependencies. 14 dependency cycles across 56 modules, marked above the diagonal.

Showing the 40 most-connected modules; 645 more are not drawn.

Module dependency matrix. The row depends on the column; the number is how many type pairs create the dependency. A cell above the diagonal is part of a dependency cycle.
depends on →1 vnc_rs.config2 vnc_rs.event3 warpgate_common.secrets4 warpgate_common.state5 warpgate_common.types.aliases6 warpgate_common.types.listen_endpoint7 warpgate_core.protocols.desktop8 warpgate_database_protocols.mysql.protocol.capabilities9 warpgate_db_entities.AdminRole10 warpgate_tls.cert11 picky.key12 warpgate_common.auth.cred13 warpgate_core.recordings14 warpgate_database_protocols.mysql.protocol.text.query15 sspi.secret16 sspi.auth_identity17 warpgate_common.config.target18 sspi19 warpgate_common.config20 warpgate_db_entities.Target21 ironrdp_connector22 picky.signature23 sspi.kerberos24 sspi.ntlm25 warpgate_common.auth.state26 ironrdp_server.display27 picky.x509.certificate28 warpgate_core.config_providers29 ironrdp_server.server30 warpgate_core.protocols.handle31 warpgate_core.recordings.desktop32 warpgate_core.services33 warpgate_common_http.auth34 warpgate_protocol_mysql.session35 warpgate_protocol_ssh.client36 warpgate_web_clients_common37 warpgate_admin.api.admin_scheme38 warpgate_protocol_http.api.auth_scheme39 warpgate_protocol_ssh.server.session40 warpgate_web_ssh.session
1 vnc_rs.config
2 vnc_rs.event
3 warpgate_common.secrets
4 warpgate_common.state
5 warpgate_common.types.aliases
6 warpgate_common.types.listen_endpoint
7 warpgate_core.protocols.desktop
8 warpgate_database_protocols.mysql.protocol.capabilities
9 warpgate_db_entities.AdminRole
10 warpgate_tls.cert
11 picky.key1
12 warpgate_common.auth.cred1
13 warpgate_core.recordings212
14 warpgate_database_protocols.mysql.protocol.text.query1
15 sspi.secret1
16 sspi.auth_identity312
17 warpgate_common.config.target17111
18 sspi112
19 warpgate_common.config1792341
20 warpgate_db_entities.Target1
21 ironrdp_connector2
22 picky.signature31
23 sspi.kerberos14
24 sspi.ntlm114
25 warpgate_common.auth.state461
26 ironrdp_server.display21
27 picky.x509.certificate42
28 warpgate_core.config_providers31154
29 ironrdp_server.server231
30 warpgate_core.protocols.handle42113
31 warpgate_core.recordings.desktop2521
32 warpgate_core.services121111112
33 warpgate_common_http.auth11111
34 warpgate_protocol_mysql.session111121
35 warpgate_protocol_ssh.client23113
36 warpgate_web_clients_common41131
37 warpgate_admin.api.admin_scheme241
38 warpgate_protocol_http.api.auth_scheme15
39 warpgate_protocol_ssh.server.session3122122213
40 warpgate_web_ssh.session2111112
Dependency, pointing down the layeringAbove the diagonal — part of a cycleThe module itself
vnc_rs.configvnc_rs.event…rpgate_common.secretswarpgate_common.state…_common.types.aliases…types.listen_endpoint…ore.protocols.desktop…protocol.capabilities…db_entities.AdminRolewarpgate_tls.certpicky.key…gate_common.auth.cred…pgate_core.recordings…l.protocol.text.querysspi.secretsspi.auth_identity…_common.config.targetsspiwarpgate_common.config…te_db_entities.Targetironrdp_connectorpicky.signaturesspi.kerberossspi.ntlm…ate_common.auth.stateironrdp_server.displaypicky.x509.certificate…core.config_providersironrdp_server.server…core.protocols.handle…re.recordings.desktopwarpgate_core.services…gate_common_http.auth…rotocol_mysql.session…e_protocol_ssh.client…te_web_clients_common…dmin.api.admin_scheme…_http.api.auth_scheme…ol_ssh.server.session…pgate_web_ssh.sessionvnc_rs.config1vnc_rs.event2…rpgate_common.secrets3warpgate_common.state4…_common.types.aliases5…types.listen_endpoint6…ore.protocols.desktop7…protocol.capabilities8…db_entities.AdminRole9warpgate_tls.cert10picky.key11…gate_common.auth.cred12…pgate_core.recordings13…l.protocol.text.query14sspi.secret15sspi.auth_identity16…_common.config.target17sspi18warpgate_common.config19…te_db_entities.Target20ironrdp_connector21picky.signature22sspi.kerberos23sspi.ntlm24…ate_common.auth.state25ironrdp_server.display26picky.x509.certificate27…core.config_providers28ironrdp_server.server29…core.protocols.handle30…re.recordings.desktop31warpgate_core.services32…gate_common_http.auth33…rotocol_mysql.session34…e_protocol_ssh.client35…te_web_clients_common36…dmin.api.admin_scheme37…_http.api.auth_scheme38…ol_ssh.server.session39…pgate_web_ssh.session4011212113121711111217923411231141144612142311542314211325211211111121111111112123113411312411531221222132111112+645 more modules (most-connected shown)

At a glance — Code Health · 49% · Weak · gated by R7, X5 ·

At a glance — Architecture · 69% · Adequate · gated by AX10 ·

At a glance — Maturity · 65% · Adequate · gated by M2 ·

At a glance — Readiness · 79% · Strong ·

At a glance — Security · 68% · Adequate · gated by D29, D30 ·

At a glance — Domain Modelling · 100% · Exemplary ·

At a glance — Event Sourcing · 100% · Exemplary ·

Security & Compliance — OWASP Top-10 mapping

Findings mapped to OWASP categories; the specific CVEs/secrets are in the Security dimension cards below and findings.md (redacted only on the public version of this report).

OWASP categoryFindingsSeverity
A05:2021 — Security Misconfiguration23High / Critical
A06:2021 — Vulnerable & Outdated Components18High / Critical
A03:2021 — Injection14High / Critical
A02:2021 — Cryptographic Failures1High / Critical

Roadmap

First, eliminate dead code and unused exports to reduce maintenance overhead and rebuild times. Next, enable nullable reference types across all projects and resolve warnings directly instead of suppressing them. Then, split large files into smaller, focused modules that align with their existing responsibilities. Finally, document significant architectural decisions in dated records and ensure these are discoverable within your design documentation structure.

Ranked by impact ÷ effort. "Helps" is the estimated gain on the 0–100 health score.

Do thisHelpsEffortDimension
Delete the dead files and unused exports — every line is maintenance cost and rebuild-estimate inflation with zero runtime value.+9.6 ptsMediumDead Code
Enable <Nullable>enable</Nullable> across all projects and resolve warnings rather than suppressing with `!`.+9.6 ptsMediumNullable reference types
Split each oversized file along the responsibilities already in it, into smaller focused modules in the same package.+8.2 ptsMediumLarge Files
Resolve the 1 No ADRs found finding(s) in ADR Quality.+2.4 ptsLowADR Quality
Record significant decisions one document per decision — dated, stating the context, the decision and its consequences — and keep them together wherever your design docs already live (a conventional `docs/adr/` tree, with each file named `NNNN-title` in whatever markup those docs already use, is the most discoverable form).+2.5 ptsMediumArchitecture documentation
Add a 'Testing' section to the root README — how to run the test suite.+2.2 ptsMediumDocumentation (README)
Resolve the 3 ServerSession finding(s) in Cyclomatic Complexity — start with session.rs (3).+0.5 ptsLowCyclomatic Complexity
Resolve the 5 ServerSession finding(s) in Cognitive Complexity — start with session.rs (5).+0.5 ptsLowCognitive Complexity

File quality

Per-file score 0–10 — a quality signature. Of 114 files carrying findings, judged against the Production bar: 4% slop · 49% mixed · 47% near-clean.

FileScoreBandWorst signal
REDACTED0.3SlopIaC & Container Security: High IaC: REDACTED
REDACTED1.4SlopStatic Analysis (SAST): High: REDACTED
REDACTED2.7SlopDependency Vulnerabilities: Critical CVE: REDACTED
REDACTED3.0SlopDependency Vulnerabilities: High CVE: REDACTED
REDACTED5.7MixedStatic Analysis (SAST): High: REDACTED
warpgate-admin/src/api/parameters.rs5.8MixedChange Coupling: Boundary-crossing change coupling: parameters.rs ↔ lib.rs
warpgate-protocol-mysql/src/lib.rs5.8MixedChange Coupling: Boundary-crossing change coupling: lib.rs ↔ lib.rs
warpgate-protocol-ssh/src/server/session.rs7.0MixedCyclomatic Complexity: ServerSession::handle_remote_event (cyclomatic 47)
warpgate-common/src/audit.rs7.0MixedGod Classes: MethodTooLong: AuditEvent.emit
warpgate-db-migrations/src/m00044_ticket_requests.rs7.1MixedGod Classes: MethodTooLong: Migration.up
warpgate-protocol-kubernetes/src/server/handlers.rs7.1MixedCyclomatic Complexity: warpgate_protocol_kubernetes::server::handlers::_handle_normal_request_inner (cyclomatic 24)
warpgate-protocol-rdp/src/server/mod.rs7.2MixedCyclomatic Complexity: warpgate_protocol_rdp::server::control_loop (cyclomatic 34)
warpgate-protocol-vnc/src/server/protocol.rs7.2MixedCyclomatic Complexity: warpgate_protocol_vnc::server::protocol::read_client_messages (cyclomatic 20)
warpgate-protocol-mysql/src/client.rs7.2MixedCyclomatic Complexity: MySqlClient::connect (cyclomatic 19)
warpgate-core/src/ticket_requests.rs7.2MixedCyclomatic Complexity: warpgate_core::ticket_requests::create_ticket_request (cyclomatic 17)
warpgate-protocol-ssh/src/client/mod.rs7.2MixedCognitive Complexity: Connector::authenticate_session (cognitive 24)
warpgate-core/src/config_providers/db.rs7.2MixedGod Classes: ClassTooLong: DatabaseConfigProvider
warpgate-admin/src/api/users.rs7.2MixedGod Classes: FileTooLong: api/users.rs
warpgate-protocol-http/src/api/credentials.rs7.2MixedGod Classes: FileTooLong: api/credentials.rs
warpgate-db-migrations/src/m00078_assignment_composite_pks.rs7.2MixedCode Duplication: Near-duplicate member pair (50 shared lines)

How the grades work

Every finding carries one of four grades. Three say how serious it is. The fourth says this survey could not settle it — and it is a grade, not a gap.

Critical — 28

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.

Serious — 334

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.

Minor — 23

Recorded, with no effect on how the codebase functions. Present so the survey is complete, not because it needs doing.

Could not be resolved — 31

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. 60 of 64 evaluated dimensions are computed purely by tools and static analysis (confidence 1.0); 4 documentation/naming judgement(s) are LLM-assisted and labelled advisory. Overall confidence is 0.9 — 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.

Every figure here is one of three kinds, and we label which: ✓ Measured — a deterministic fact (LoC, complexity, coverage); ~ Modeled — an estimate from a stated model (cost, effort, value-at-risk), always a range with its assumptions, never a precise fact; ◐ Advisory — an LLM prose judgement. We never present a modelled estimate as if it were measured. Perfect or absent scores carry their provenance too (ADR-0011): ✓ Tool-verified means the property itself was measured across the surface; ○ Nothing flagged means the probes came back clean — a claim bounded by what a repository can show; ⊘ Not evidenced means a working control (a tested restore, an automated rollback) showed no positive evidence — absence of evidence is not evidence of a control, so it's excluded from the score rather than awarded a spurious 10; ◐ Sampled · advisory marks an LLM verdict over a bounded sample — advisory, never a deterministic measurement.

What we checked — 64 dimensions across the health lenses
D1D2D3D4D5D6D9D10D13D14D15D17D19D20D21D22D26D28D29D30D31D34D35D36D37D40D41D43D44AX10AX3AX4AX5AX8AX9DM1DM2DM4DM5DM6ES1ES2GD1IC1M1M2M3M4P1P2P3P4P5P6R1R10R2R3R5R6R7R8R9X5

Each chip is a dimension scored from real signals across architecture, testing, dependencies, security & compliance, documentation, git-history and code quality — in one coherent pass. A surface report typically covers a handful.

How to trust any code-health report — three questions
  1. 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, 345 of 385 do; the remainder are repo-wide signals — a dimension-level measurement, not a single line. (Every path in this report is repo-relative by construction: paths are normalized at the producer and the report is rejected if any rooted path leaks through.)
  2. 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.
  3. 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.

This report answers yes to all three. That's the bar to hold any assessment to.

Tools & methods

The actual versions used this run (captured at analysis time) — re-run on the same commit for the identical score.

MethodBacksVersionEvaluator
Roslyn static analysisComplexity, cohesion, coupling, dead code, API surface, layering5.3.0✓ deterministic
Native secret scannerHardcoded secrets / credentials1.0.0✓ deterministic
Watchdog duplication detector (in-process)Code duplication1.0.0✓ deterministic
Coverage (coverlet / dotnet-coverage)Line & branch coverage10.0.400✓ deterministic
NuGet / dotnetOutdated, vulnerable & deprecated dependencies10.0.400✓ deterministic
git / LibGit2SharpChurn hotspots, knowledge concentration, history2.43.0 · 0.31.0✓ deterministic
gitleaks · semgrep · trivy · checkovSecrets in history, SAST, CVEs, IaC & container, PII / GDPR1.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 measurementLocal LLM◐ LLM · sampled · advisory

Every finding is locatable in findings.md. Run 01a0ecb9-c7ba-7872-b3a7-d40bb823ad7a.

The exact command behind every deep-scan dimension — tool, version, invocation and retained raw output — is in Appendix B — Reproduction & audit trail.

Run transparency — what happened this run

What ran differently this time — a tool absent, degraded, or that fell back to an estimate. Named openly, not folded silently into the scores. A degraded run also records its exact cause in diagnostics.md.

  • 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: the analyzer environment could not build/run this repository's test suite, whose production source is .rs, .ts. This is OUR limitation, not a defect in the repo — coverage is excluded from the score rather than counted as a near-zero. We track the analyzer-image gap so it can be closed; in the meantime, produce a coverage report in a standard format (lcov — `cargo install cargo-llvm-cov`, then `cargo llvm-cov --lcov --output-path lcov.info`, or lcov — `vitest --coverage`, `jest --coverage`, `bun test --coverage --coverage-reporter=lcov`, or `nyc`) 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 and real coverage will be read. You can widen what we reach: optional: commit the Cobertura/OpenCover/lcov report your CI already produces, and the real number is read on the next scan.
  • D10 Test Quality — 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. The 4 test(s) behind this row are the ones the C# collector could read, and this repository also carries at least 76 test source file(s) (.py, .rs) that it cannot: it parses C# syntax and matches C# test attributes, so a vitest/jest/JUnit/pytest-style suite is invisible to it. Skipped tests, zero-assertion tests and the other quality signals on this row are UNMEASURED in that suite — their absence from the counts above is a gap in this analyzer's language coverage, not a finding that those tests are sound.
  • 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 reliability NOT SCORED: this repository's production source spans .rs, and the built-in reliability runner cannot re-run the .rs test suite(s) — so reliability was not measured for the repository as a whole. The .NET suite did build and re-run, and came back with 0 flaky across 1 measured tier(s) (unit: measured (0 flaky)) — but that is a figure for one half of the product, and we do not publish a partial one as if it were complete. This is OUR limitation, not a defect in the repo — test reliability is excluded from the score rather than counted.
  • D12 Dependency 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. This repository's production source is .rs, .ts, and no dependency manifest was found alongside it. Zero packages read is NOT a clean dependency tree, so this is NOT SCORED — a gap in the analyzer, not a verdict about this repository. The manifests this pass reads are: a Python pyproject.toml/requirements.txt (pip/uv/Poetry), a Cargo manifest, a Go module (go.mod/go.sum), an OSGi MANIFEST.MF/target platform, a Maven POM, a Gradle version catalogue, an sbt build (build.sbt), composer.json, package.json, a Dart pubspec.yaml, a Swift Package.swift/Package.resolved, an Elixir mix.exs/mix.lock (Hex), a rebar.config / erlang.mk DEPS (Hex), a Ruby Gemfile/Gemfile.lock or .gemspec (Bundler/RubyGems). A source tree carrying none of them either declares its dependencies somewhere this pass does not look, or vendors them into the tree.
  • 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 Cargo manifest, but the licence verdict published here was taken over its NuGet package dependencies. Nothing was read about its Cargo dependencies' licensing in either direction, and a clean score on this card must not be read as covering them.
  • 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 package.json, but the licence verdict published here was taken over its NuGet package dependencies. Nothing was read about its npm dependencies' licensing in either direction, and a clean score on this card must not be read as covering them.
  • 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 NuGet package 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.
  • D16 Bus Factor — not measured this run — This is a true statement about the repository that carries nothing for its owner to act on, so it is reported here rather than as a defect in their code. Single-maintainer repository — bus factor is not applicable (72 contributor(s) across 1814 commit(s) sampled, automation and bot accounts excluded). One of them holds 88% of the history; the other 71 hold 0.2% each on average, below the 5% at which there is somebody to hand the work to. That is a single maintainer with drive-by contributors, not a team whose knowledge has concentrated — so the bus factor is not applicable and there is nothing here for the owner to act on.
  • D17 Explicit Debt — 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. The 0 deducted marker(s) and the 0.0/KLoC density on this row were taken over this repository's .NET projects ALONE: .rs (77,069 lines, 96% of production source) went unread, because every marker collector on this path is reached through a C# workspace. A read-only sweep of that source finds at least 11 task marker(s) (TODO/FIXME/HACK/XXX) across 10 file(s) that this score does not count — a floor, since only line comments are read there and D17's other eight marker kinds (suppressions, NoWarn, editorconfig severities, empty catches, commented-out code, Obsolete, dead code, preprocessor branches) need a compiler we do not have for that language. The debt in that source is UNMEASURED — its absence from the score above is a gap in this analyzer's language coverage, not a finding that the code carries none.
  • D23 Boundary Type-Coupling — 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. 4 bounded context(s) were resolved, but of the 1543 public type(s) this run scanned, none could be attributed to any of them — so no cross-boundary leak was reachable and an empty result was guaranteed regardless of the code. This happens when the scored code model is a non-.NET (sidecar) primary while the contexts were resolved from .NET project directories, which key on assembly name. Not scored: this is a gap in the analyzer, not a verdict about this repository. You can widen what we reach: declare this codebase's bounded contexts by module-path or namespace prefix so they resolve against the languages actually scanned. 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"]`.
  • 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. `warpgate-web/src/common/desktopCanvas.ts` 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.
  • DM3 Integration-event coupling — 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. Not scored — a domain type leaking across a crate boundary cannot be told apart from source alone from a legitimate shared-kernel crate. Reported as guidance rather than measured.
  • DM7 Repository granularity — 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. Not scored — detecting 'a repository per CHILD entity' needs the aggregate-root structure, which is not resolvable from source alone here. Reported as guidance rather than measured.
  • P8 Schema migrations — 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. The schema may be created by a runner, a deploy script or a config file outside what this check reads, so an absence here is our blind spot rather than a missing migration strategy. The card abstains instead of scoring. You can widen what we reach: if the schema is created and evolved by a tool this check does not name, naming it lets us teach the detector to read it.
  • R7 Dead Code — 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. 106 further occurrence(s) are not listed individually; the score already reflects all 146.
  • 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 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.
  • 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 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.
  • 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 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.
  • X14 Bypassable address classification — 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.
  • X15 Unvalidated length from an untrusted reader — 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.
  • 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 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.
  • 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 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.
  • 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 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.
  • 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 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.
  • X2 Cancellation propagation — 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.
  • X20 Mistyped argument 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 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.
  • X21 Side-effecting pattern 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 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.
  • 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 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.
  • 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 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.
  • 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 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.
  • 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 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.
  • X26 Unsynchronised callback handoff — 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.
  • 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 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.
  • X28 Index access outside its own emptiness 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 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.
  • 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 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.
  • X3 Exception handling — 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.
  • X30 Support guard that admits what it rejects — 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.
  • X32 Type resolved by simple name across every loaded assembly — 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.
  • 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 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.

Repo exclusion declarations (.gitattributes linguist-generated/vendored, .editorconfig generated_code): none declared — every source file was scored.

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

For each dimension that was measured, what a static, repo-only scan structurally cannot see — the honest edge of the measurement, not a failure of it.

  • D1 Cyclomatic Complexity: Cyclomatic complexity counts branches statically — it cannot tell an essential decision tree from accidental tangle, nor see complexity that lives in data or configuration (large switch-case token tables, DSL lexers/parsers, data-as-code rule tables) rather than control flow: a tokenizer's many single-character cases read as high complexity though each branch is trivial.
  • D2 Cognitive Complexity: Cognitive-complexity heuristics approximate how hard code is to follow; genuine domain difficulty and well-named intent that eases reading are not captured.
  • D3 God Classes: "God class" is sized by members and responsibilities visible in the type — a deliberately broad facade over a coherent subsystem can read the same as an accidental grab-bag. For front-end JS the file-length check is cohesion-aware (a single-responsibility module — one class/IIFE — earns a 3× threshold), but cohesion is approximated from top-level declarations, not true dependency structure.
  • D4 Code Duplication: Duplication is token-similarity — an in-process token-stream comparison over sliding windows, with type-aware normalization — so it finds copy-paste, not semantic duplication expressed differently. Committed machine-written code (scaffolded migrations, designer/codegen output, protobuf/OpenAPI stubs, model snapshots) is EXCLUDED — its repetition is the tool's, not the team's — so the score reflects hand-written duplication only.
  • D5 Coupling: Coupling is measured between projects/assemblies — runtime coupling through DI, reflection, messaging or shared databases is invisible to a static reference graph.
  • D6 Cohesion (LCOM4): LCOM4 cohesion is syntactic — it infers connectivity from which methods touch which fields/methods by name, not from real runtime behaviour or intent.
  • 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.
  • D10 Test Quality: Assertion density is structural — it cannot tell a meaningful behavioural assertion from a trivial one, only that an assertion is present.
  • 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.
  • D15 Churn × Complexity Hotspots: Churn hotspots come from git history — a freshly imported or squashed repository has no churn signal, and recent rewrites can mask a historically risky file.
  • 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.
  • D22 Internal API Consistency: API-surface coherence is an LLM judgement over a sample of the public surface — consistency of intent across the whole API is approximated, not exhaustively verified.
  • D26 Project Cohesion: Project focus is sized from members/namespaces per project — a project that is broad by deliberate design reads the same as one that has sprawled.
  • D28 Secrets (history): Secret-history scanning sweeps the git log for known patterns — a secret that predates the available history, or never matched a signature, is not found (clean means "nothing matched in the history we can see").
  • 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.
  • D40 Network Egress Confinement: Egress confinement is read from committed Kubernetes manifests — a policy applied out-of-band (cluster-default deny, a service mesh, or a cloud firewall/security group off-repo) is invisible, and a present NetworkPolicy is declared config, not proof the cluster admission-controller actually enforces it at runtime.
  • D41 Kernel & Syscall Confinement: Syscall/MAC confinement is read from committed manifests — a profile applied by a cluster-wide PodSecurity default or a mutating webhook off-repo isn't seen, and a declared seccomp/AppArmor profile is config presence, not proof the node's kernel actually loaded and enforced it.
  • 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 REDACTED (D31's subject), in a CI workflow (D29's), or in a file this pass does not parse (go.mod, 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.
  • AX9 CQS / query purity: Handlers are found by interface/name convention — a query handler using neither is not seen. Mutation is a resolved write/publish invocation (SaveChanges/repository/bus), so a write hidden behind a hand-rolled wrapper, reflection, or a string-keyed service locator resolves to a non-persistence type and isn't flagged; it detects that a query writes state, not whether the write is a legitimate read-side cache update. Clean means "no resolved write/publish in a query body", not a proof of CQS purity.
  • DM4 Rich vs anemic domain model: Behaviour is detected as state mutation inside a method body — a method that enforces an invariant by validating-and-throwing without mutating reads as a query, and mutation delegated through an interface the scan can't resolve isn't credited; entities with zero public properties still drop out of the population. It detects that state changes, not whether the rule is correct.
  • DM6 Domain ↔ infrastructure boundary: Infrastructure reached through a hand-rolled wrapper, a domain-named facade, reflection, or a string-keyed service locator resolves to a non-infra type and isn't seen; the body scan is symbol resolution over syntax, not full dataflow. A clean result means "no resolved infra reference in a domain body", not a proof of purity.
  • 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

LLM-set scores this run (4): D19, D21, D22, M4 (model: Local LLM). For these, a model reads a bounded sample and sets the numeric score; each names its own sample and method on its card. They are sampled and advisory by design: they vary at the margins between runs and are never a deterministic measurement. Every other score in this report is tool-computed at confidence 1.0.

Dimensions

D1 · Cyclomatic Complexity6.9 / 10Adequate✓ Tool-verified

What it measures: How tangled the control flow is — methods with many branches are hard to test and change.

Method: Cyclomatic complexity per method (1 + decision points), computed exhaustively across production source; test projects separated by convention. Deterministic.

Maturity: Documented → Verified → Prevented · effective 6.9 / 10 · rule-coverage 100% · ceiling Prevented

23 method(s) exceeded the cyclomatic complexity threshold of 15; the worst was warpgate::commands::setup::command at 49. A further 14 method(s) were over the threshold but excluded as flat dispatchers (a long switch/match over independent cases: many branches, almost no nesting), the largest being Collation::from_str at 225 — they are counted neither in the figure above nor in this dimension's score. 8 files carry no cyclomatic complexity row at all for this reason — every one of their over-threshold functions was excluded, so the exclusion is disclosed nowhere in the file itself: warpgate-database-protocols/src/mysql/collation.rs (Collation::from_str at 225), warpgate-protocol-rdp/src/client/input.rs (warpgate_protocol_rdp::client::input::keysym_to_scancode at 71), warpgate-database-protocols/src/mysql/protocol/text/column.rs (ColumnType::name at 38), warpgate-common/src/audit.rs (AuditEvent::emit at 22), warpgate-common/src/error.rs (WarpgateError::user_facing_reason at 21), and 3 more not listed here. They are named here because the per-file figures other dimensions report are taken BEFORE this exclusion, so such a file can show a high maximum complexity elsewhere in this report and nothing here, with nothing to reconcile the two.

ServerSession::handle_remote_event (cyclomatic 47) · ×3warpgate-protocol-ssh/src/server/session.rs:1260
warpgate_core::db_auth::authorize_user (cyclomatic 19) · ×3warpgate-core/src/db_auth.rs:189
warpgate::commands::setup::command (cyclomatic 49) · ×2warpgate/src/commands/setup.rs:52
warpgate_protocol_rdp::server::control_loop (cyclomatic 34) · ×2warpgate-protocol-rdp/src/server/mod.rs:209
warpgate_protocol_vnc::server::protocol::read_client_messages (cyclomatic 20) · ×2warpgate-protocol-vnc/src/server/protocol.rs:266

+ 11 more group(s) — more in Appendix A; the complete list is findings.md.

What to do

  1. Resolve the 3 ServerSession finding(s) in Cyclomatic Complexity — start with session.rs (3). — One of this dimension's main actionable groups (3 warning-level).
  2. Resolve the 3 warpgate_core finding(s) in Cyclomatic Complexity — start with db_auth.rs, ticket_requests.rs, credential_encryption.rs. — One of this dimension's main actionable groups (3 warning-level).
  3. Resolve the 2 warpgate finding(s) in Cyclomatic Complexity — start with setup.rs, run.rs. — One of this dimension's main actionable groups (2 warning-level).
  4. Enforce Cyclomatic Complexity in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Prevented — provenance only; does not change the score.

Detailed fixes: d1_recommendation.md · top locations in Appendix A, every location in findings.md.

D2 · Cognitive Complexity6.0 / 10Adequate✓ Tool-verified

What it measures: How hard the code is for a person to follow, beyond raw branching.

Method: Cognitive complexity per method (Sonar-style nesting-penalized score), computed exhaustively over production code, excluding test projects. Deterministic.

Maturity: Documented → Verified → Prevented · effective 6.0 / 10 · rule-coverage 100% · ceiling Prevented

50 method(s) exceeded the cognitive complexity threshold of 15; the worst was warpgate::commands::setup::command at 97.

ServerSession::handle_remote_event (cognitive 61) · ×5warpgate-protocol-ssh/src/server/session.rs:1260
warpgate_core::db_auth::authorize_user (cognitive 40) · ×4warpgate-core/src/db_auth.rs:189
warpgate_protocol_kubernetes::server::handlers::_handle_normal_request_inner (cognitive 34) · ×4warpgate-protocol-kubernetes/src/server/handlers.rs:229
warpgate::commands::setup::command (cognitive 97) · ×3warpgate/src/commands/setup.rs:52
warpgate_protocol_rdp::server::control_loop (cognitive 78) · ×3warpgate-protocol-rdp/src/server/mod.rs:209

+ 23 more group(s) — more in Appendix A; the complete list is findings.md.

What to do

  1. Resolve the 5 ServerSession finding(s) in Cognitive Complexity — start with session.rs (5). — One of this dimension's main actionable groups (5 warning-level).
  2. Resolve the 4 warpgate_core finding(s) in Cognitive Complexity — start with db_auth.rs, credential_encryption.rs, sso_user.rs. — One of this dimension's main actionable groups (4 warning-level).
  3. Resolve the 4 warpgate_protocol_kubernetes finding(s) in Cognitive Complexity — start with handlers.rs (2), correlator.rs, auth.rs. — One of this dimension's main actionable groups (4 warning-level).
  4. Enforce Cognitive Complexity in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Prevented — provenance only; does not change the score.

Detailed fixes: d2_recommendation.md · top locations in Appendix A, every location in findings.md.

D3 · God Classes8.2 / 10Strong✓ Tool-verified

What it measures: Over-large classes that try to do too much ("god classes").

Method: God-class detection by line and method-count thresholds per logical type (partial classes unified), filtered for generated code and registration/contract false positives. Deterministic.

Maturity: Documented → Verified → Prevented · effective 8.2 / 10 · rule-coverage 100% · ceiling Prevented

39 god class(es) detected.

MethodTooLong: AuditEvent.emit · ×11warpgate-common/src/audit.rs:216
FunctionTooLong: warpgate::commands::setup::command · ×11warpgate/src/commands/setup.rs:52
FileTooLong: server/session.rs · ×9warpgate-protocol-ssh/src/server/session.rs
ClassTooLong: ServerSession · ×4warpgate-protocol-ssh/src/server/session.rs:129
TooManyFields: Model · ×3warpgate-db-entities/src/Parameters.rs:185

+ 1 more group(s) — more in Appendix A; the complete list is findings.md.

What to do

  1. Resolve the 11 MethodTooLong finding(s) in God Classes — start with session.rs (2), client.rs (2), audit.rs. — One of this dimension's main actionable groups (11 warning-level).
  2. Resolve the 11 FunctionTooLong finding(s) in God Classes — start with mod.rs (2), handlers.rs (2), setup.rs. — One of this dimension's main actionable groups (11 warning-level).
  3. Resolve the 9 FileTooLong finding(s) in God Classes — start with mod.rs (3), session.rs, db.rs. — One of this dimension's main actionable groups (9 warning-level).
  4. Enforce God Classes in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Prevented — provenance only; does not change the score.

Detailed fixes: d3_recommendation.md · top locations in Appendix A, every location in findings.md.

D4 · Code Duplication9.5 / 10Stronggated by 84 serious findings✓ Tool-verified

What it measures: Copy-pasted code that should be shared instead.

Method: Code duplication via token-stream sliding windows with type-aware normalization (locals masked, type names preserved), density-scored per KLoC of production code. Deterministic.

Maturity: Documented → Verified → Prevented · effective 9.5 / 10 · rule-coverage 100% · ceiling Verified

82 duplicated block group(s) detected. A further 2 rows report members as variants of one another; they aggregate block groups already counted above and are not themselves counted.

Duplicated block (10 lines × 2) · ×13warpgate-common/src/eventhub.rs:56
Duplicated block (13 lines × 2) · ×8warpgate-admin/src/api/otp_credentials.rs:149
Duplicated block (8 lines × 2) · ×7warpgate-admin/src/api/ldap_servers.rs:347
Duplicated block (7 lines × 2) · ×7warpgate-core/src/ticket_requests.rs:173
Duplicated block (14 lines × 2) · ×5warpgate-protocol-rdp/src/server/mod.rs:140

+ 29 more group(s) — more in Appendix A; the complete list is findings.md.

What to do

  1. Resolve the 13 Duplicated block (10 lines × 2) finding(s) in Code Duplication — start with session.rs (2), m00058_analytics.rs (2), credentials.rs (2). — One of this dimension's main actionable groups (13 warning-level).
  2. Resolve the 8 Duplicated block (13 lines × 2) finding(s) in Code Duplication — start with session.rs (2), otp_credentials.rs, client.rs. — One of this dimension's main actionable groups (8 warning-level).
  3. Resolve the 7 Duplicated block (8 lines × 2) finding(s) in Code Duplication — start with users.rs (3), ldap_servers.rs, web_desktop.rs. — One of this dimension's main actionable groups (7 warning-level).
  4. Enforce Code Duplication in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Verified — provenance only; does not change the score.

Detailed fixes: d4_recommendation.md · top locations in Appendix A, every location in findings.md.

D5 · Coupling6.7 / 10Adequate✓ Tool-verified

What it measures: Whether volatile projects sit underneath others that depend on them (so their churn ripples upward), and whether project dependencies form cycles. A widely-depended-on but stable shared/kernel project is healthy, not penalised.

Method: Dependency cycles via elementary-DFS over real .csproj references, plus Martin instability (afferent/efferent) per project. Exhaustive over the reference graph, deterministic.

Coverage: Exhaustive · type-level: afferent/efferent coupling + cycles computed over every production type — the population is all types, not a name convention.

Maturity: Documented → Verified → Prevented · effective 6.7 / 10 · rule-coverage 100% · ceiling Prevented

28 production modules (Cargo+npm+Python), 0 dependency cycle(s), 2 unstable depended-on module(s). Read from the build's own module declarations; 11 module(s) off the main sequence, with abstractness counted on 26 of the 28 (the rest declare no modelled class or interface, export only macros, or have no source directory of their own).

Off the main sequence: warpgate-aws · ×11
Unstable project warpgate-web-desktop
Unstable project warpgate-web-ssh

What to do

  1. Resolve the 11 Off the main sequence finding(s) in Coupling. — One of this dimension's main actionable groups (11 warning-level).
  2. Resolve the 1 Unstable project warpgate-web-desktop finding(s) in Coupling. — One of this dimension's main actionable groups (1 warning-level).
  3. Resolve the 1 Unstable project warpgate-web-ssh finding(s) in Coupling. — One of this dimension's main actionable groups (1 warning-level).
  4. Enforce Coupling in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Prevented — provenance only; does not change the score.

Detailed fixes: d5_recommendation.md · top locations in Appendix A, every location in findings.md.

D6 · Cohesion (LCOM4)10.0 / 10Exemplary✓ Tool-verified

What it measures: Whether a class's methods are focused on a single responsibility.

Method: LCOM4 cohesion per production class with at least two methods: connected components of methods sharing state or calls, computed syntactically. Deterministic, not a proxy.

Coverage: Exhaustive · type-level: LCOM4 cohesion computed over every production class — the population is all types, not a name convention.

Maturity: Documented → Verified → Prevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Verified

0 of 126 classes have LCOM4 above 3.

✓ On the Gold path — maintain.

Detailed fixes: d6_recommendation.md.

D9 · Test Distribution10.0 / 10Exemplary✓ Tool-verified

What it measures: Whether the test suite has a healthy mix of unit / integration / end-to-end tests.

Method: Test projects classified (Unit/Integration/BDD/E2E) from compiled metadata; test methods counted exhaustively across projects with placement-agnostic disk fallback. Deterministic.

Maturity: Documented → Verified → Prevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Documented

716 test methods: 700 unit, 16 integration, 0 BDD, 0 e2e. The Rust suite contributes 476 `#[test]` function(s) across 96 file(s) declaring at least one; its unit/integration split is Cargo's own — 0 of those file(s) are integration-test targets under a crate's tests/ directory, and the rest are #[test] functions compiled into the crate they test. The Python suite contributes 236 test function(s) across 65 file(s) declaring at least one — every `def test…` in a file pytest or unittest would collect, which is those frameworks' own definition of a case; a parametrize table counts once, so this is a floor. Its tier split is read from file names and paths only.

✓ On the Gold path — maintain.

Detailed fixes: d9_recommendation.md.

D10 · Test Quality10.0 / 10Exemplary✓ Tool-verified

What it measures: Whether the tests truly assert behaviour rather than just running the code.

Method: Per-test assertions, skips, and mock references analyzed via Roslyn; structured skip-reason tags (BUG:/ENV:) separate documented deferrals from debt. Deterministic.

Maturity: Documented → Verified → Prevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Prevented

0 skipped, 0 zero-assertion, no mocking-framework packages referenced (hand-written doubles or no mocking) across 4 tests. Measured on the C# suite only — at least 76 test source file(s) (.py, .rs) went unread, so its test quality is unmeasured and is not in these counts.

✓ On the Gold path — maintain.

Detailed fixes: d10_recommendation.md.

D13 · Secret Scanning5.0 / 10Adequate✓ Tool-verified

What it measures: Whether any secrets (keys, tokens, passwords) have leaked into the code.

Method: In-process native secret scanner (entropy plus signature patterns) across all tracked files; no external tool. A clean result is a measured 10, not no-data zero. Deterministic.

Maturity: Documented → Verified → Prevented · effective 5.0 / 10 · rule-coverage 100% · ceiling Prevented

1 secret(s) detected.

REDACTED

What to do

  1. Resolve the 1 Leaked secret finding(s) in Secret Scanning — start with REDACTED. — One of this dimension's main actionable groups (1 issue-level).
  2. Enforce Secret Scanning in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Prevented — provenance only; does not change the score.

Detailed fixes: d13_recommendation.md · top locations in Appendix A, every location in findings.md.

D14 · License Compliance10.0 / 10Exemplary○ Nothing flagged

What it measures: Whether the licenses of third-party packages are compatible with your policy.

Method: Third-party package licenses resolved from declared package metadata and checked against the configured policy (allow/deny/copyleft). Deterministic; clean = no incompatible license found at metadata depth.

Maturity: Documented → Verified → Prevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Verified

0 of 154 packages use a banned license. ★ DEPTH: this repository's MSBuild projects declare 6 direct `PackageReference`(s), and 148 further package(s) were reached beyond them by closing the graph over nuget.org's own nuspec dependency graph — so a banned licence pulled in only by a dependency's OWN dependencies is inside this verdict. A package whose licence nuget.org could not be asked for is not graded, and version ranges are taken at their lower bound, so this is the closure as that graph states it rather than a restored consumer's exact resolution. ★ COVERAGE OF THIS VERDICT: it grades this repository's NuGet package dependencies and nothing else. The repository also declares a Cargo manifest, package.json and a Python pyproject.toml/requirements.txt (pip/uv/Poetry), and the licences of those dependency graphs 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.

✓ On the Gold path — maintain.

Detailed fixes: d14_recommendation.md.

D15 · Churn × Complexity Hotspots9.8 / 10Stronggated by 26 serious findings✓ Tool-verified

What it measures: Files that change often and are also complex — the riskiest hotspots.

Method: Per production file churn times cyclomatic complexity over a rolling window, computed from git and Roslyn/JS/Razor analysis. Exhaustive, deterministic per commit date.

Maturity: Documented → Verified → Prevented · effective 9.8 / 10 · rule-coverage 100% · ceiling Documented

Top hotspots: warpgate-protocol-ssh/src/server/session.rs (34×47=1598); warpgate-protocol-rdp/src/server/mod.rs (14×34=476); warpgate/src/commands/setup.rs (9×49=441) Repeated repair below the complexity floor: warpgate-web/src/admin/config/Parameters.svelte (13 of 24 changes were fixes); warpgate-admin/src/api/parameters.rs (12 of 22 changes were fixes); warpgate-core/src/protocols/desktop.rs (4 of 5 changes were fixes)

Hotspot: warpgate-protocol-ssh/src/server/session.rs · ×20warpgate-protocol-ssh/src/server/session.rs:1260
Repeated repair: warpgate-web/src/admin/config/Parameters.svelte · ×6warpgate-web/src/admin/config/Parameters.svelte:114

What to do

  1. Resolve the 20 Hotspot finding(s) in Churn × Complexity Hotspots — start with mod.rs (2), client.rs (2), api.rs (2). — One of this dimension's main actionable groups (20 warning-level).
  2. Resolve the 6 Repeated repair finding(s) in Churn × Complexity Hotspots — start with Parameters.svelte, parameters.rs, desktop.rs. — One of this dimension's main actionable groups (6 warning-level).

Detailed fixes: d15_recommendation.md · top locations in Appendix A, every location in findings.md.

D17 · Explicit Debt10.0 / 10Exemplary○ Nothing flagged

What it measures: Acknowledged debt left in the code — TODOs, dead code, suppressed warnings.

Method: Roslyn syntactic debt markers (suppressions/TODO/FIXME/HACK/empty-catch/commented-code/Obsolete) plus SymbolFinder dead-code analysis; weighted-debt-per-KLoC density deducted 2.0x per unit. Deterministic, exhaustive.

Maturity: Documented → Verified → Prevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Prevented

0 deducted debt markers + 0 dead symbols across 977 LoC in the .NET projects (0.0/KLoC) → score 10.0. Measured on the .NET source only: .rs (96% of production source) was not read, and carries at least 11 uncounted task marker(s) in 10 file(s).

✓ On the Gold path — maintain.

Detailed fixes: d17_recommendation.md.

D19 · Documentation QualityExemplary◐ Sampled · advisory

What it measures: Whether the project's documentation is clear, complete, and useful.

Method: Judged by language model at low temperature (0.0-0.1) on a deterministic doc sample (READMEs plus first 25 architecture docs), with two-pass stability filtering. Advisory, sampled.

Maturity: Documented → Verified → Prevented · effective Exemplary / 10 · rule-coverage 100% · ceiling Documented

Warpgate's root README and several subdirectories are well written: the repository-level README is a clear, multi-paragraph overview of what Warpgate does (transparent bastion host for SSH/HTTPS/K8s/MySQL/RDP/VNC) with an image, links to releases, downloads, Ko-fi, and a full outline; each feature directory's README documents itself rather than the root repo. The architecture/design docs are absent from this summary, so any architectural guidance would fall under 'missing-architecture-docs'. Coverage is 7 XML-docs at 6% of 116 total (only one of those is shown), but the visible content is clear and complete for its scope.

XML-doc coverage: AADJoinvendor/sspi/tools/aadjoin/AADJoin/AADJoin.csproj

✓ On the Gold path — maintain.

Detailed fixes: d19_recommendation.md · top locations in Appendix A, every location in findings.md.

D20 · ADR Quality0.0 / 10Critical✓ Tool-verified

What it measures: Whether architecture decisions are recorded well (context, decision, consequences).

Method: Per-ADR judgment by language model at low temperature with two-pass stability; confidence is share of ADRs evaluated; enforcement-field presence detected deterministically. Advisory.

Maturity: Documented → Verified → Prevented · effective 0.0 / 10 · rule-coverage 100% · ceiling Documented

No architecture decision records were found.

No ADRs found

What to do

  1. Resolve the 1 No ADRs found finding(s) in ADR Quality. — One of this dimension's main actionable groups (1 recommendation-level).

Detailed fixes: d20_recommendation.md · top locations in Appendix A, every location in findings.md.

D21 · Naming ConsistencyAdequate◐ Sampled · advisory

What it measures: Whether names — types, methods, variables — are clear and consistent.

Method: Judged by language model at low temperature (0.0-0.1) on a deterministic random symbol sample (fixed size, not exhaustive), with disclosed confidence band. Advisory, sampled.

Maturity: Documented → Verified → Prevented · effective Adequate / 10 · rule-coverage 100% · ceiling Verified

4 naming inconsistencies across 168 sampled symbols.

Inconsistent abbreviation for the same concept. 'MembershipChgs' is used as a nested type name for specific SIDs, while 'MembershipChanges' is used as the property name for the collection. 'Chgs' is a non-standard abbreviation for 'Changes'.
Typo in method name. 'DecryptCeritficate' contains a typo ('Ceritficate' instead of 'Certificate'). Other methods in the same class use correct spelling ('PemCsrToFile', 'PemCrtToFile').
Inconsistent casing for factory/parse methods. 'AuthResponse.fromString' uses lowercase 'f', while 'JoinDeviceResponse.FromString', 'TenantAuthResponse.FromString', and 'P2PCertificatesResponse.FromString' use PascalCase 'F'.
Inconsistent abbreviation for 'User'. The type and property are named 'Usr', while other credentials use 'User' (e.g., 'AADJoin.Creds.UserCreds', 'AADJoin.Messages.JoinDeviceRequest.User' is not present but 'UserCreds' is). 'Usr' is a non-standard abbreviation.

What to do

  1. Resolve the 1 Inconsistent abbreviation for the same concept. 'MembershipChgs' is used… finding(s) in Naming Consistency. — One of this dimension's main actionable groups (1 recommendation-level).
  2. Resolve the 1 Typo in method name. 'DecryptCeritficate' contains a typo ('Ceritficate'… finding(s) in Naming Consistency. — One of this dimension's main actionable groups (1 recommendation-level).
  3. Resolve the 1 Inconsistent casing for factory/parse methods. 'AuthResponse.fromString'… finding(s) in Naming Consistency. — One of this dimension's main actionable groups (1 recommendation-level).

Detailed fixes: d21_recommendation.md · top locations in Appendix A, every location in findings.md.

D22 · Internal API ConsistencyStrong◐ Sampled · advisory

What it measures: Whether the internal API surface is consistent and coherent.

Method: Judged by language model at low temperature over a sample of the public API surface (IsPackable or .Contracts types). Sampled, advisory; confidence discounted by model uncertainty.

Maturity: Documented → Verified → Prevented · effective Strong / 10 · rule-coverage 100% · ceiling Verified

4 API inconsistencies across a 400-member sample of 417 exposed types.

Inconsistent naming for standard I/O operations. `FramedRead` uses `read` (standard Rust `Read` trait name), while `FramedWrite` uses `write_all` (standard Rust `Write` trait method for full buffer writes). This creates asymmetry in the API surface.
Inconsistent constructor patterns for wrapping streams. `StreamWrapper` uses a static factory method `from_inner`, while `Framed` uses `new` and `new_with_leftover`. This forces users to remember different instantiation patterns for similar wrapper types.
Inconsistent return types for `into_inner`. `StreamWrapper.into_inner` returns the inner type directly, while `Framed.into_inner` returns a tuple `(InnerStream, BytesMut)`. This breaks the expectation that `into_inner` always returns the wrapped inner component in a consistent shape, forcing users to handle the tuple unpacking for `Framed` specifically.
Inconsistent return types for `get_inner`/`get_inner_mut`. `StreamWrapper` returns the inner stream directly, while `Framed` returns a tuple of references. This inconsistency requires different handling code depending on which wrapper type is being used.

What to do

  1. Resolve the 1 Inconsistent naming for standard I/O operations. `FramedRead` uses… finding(s) in Internal API Consistency. — One of this dimension's main actionable groups (1 warning-level).
  2. Resolve the 1 Inconsistent constructor patterns for wrapping streams. `StreamWrapper`… finding(s) in Internal API Consistency. — One of this dimension's main actionable groups (1 warning-level).
  3. Resolve the 1 Inconsistent return types for `into_inner`. `StreamWrapper.into_inner`… finding(s) in Internal API Consistency. — One of this dimension's main actionable groups (1 warning-level).

Detailed fixes: d22_recommendation.md · top locations in Appendix A, every location in findings.md.

D26 · Project Cohesion10.0 / 10Exemplary✓ Tool-verified

What it measures: Whether each project is a focused, coherent unit rather than an oversized grab-bag.

Method: Project size overshoot penalties (LoC / public-type count / namespace count, 2-of-3 flag) weighted by log magnitude. Exhaustive across projects, deterministic, LLM-independent.

Maturity: Documented → Verified → Prevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Documented

0 of 2 projects flagged as possibly oversized/incoherent.

✓ On the Gold path — maintain.

Detailed fixes: d26_recommendation.md.

D28 · Secrets (history)10.0 / 10Exemplary○ Nothing flagged

What it measures: Whether any secrets were ever committed — scanned across the full git history, not just now.

Method: Secret scan via TWO gitleaks detect passes in an isolated checkout — the full git history, then a second --no-git pass over the working tree as it stands — merged and de-duplicated by (rule, file, line); each match flagged High. Both invocations are recorded in the audit trail. Exhaustive; when the tool is absent, or when its output cannot be parsed into the expected shape, the dimension is WITHHELD as an explicit measurement gap on our side — unscored and excluded from the lens, never a hedged middling score.

Maturity: Documented → Verified → Prevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Documented

gitleaks scanned the full history AND the current working tree and found no secrets.

✓ On the Gold path — maintain.

Detailed fixes: d28_recommendation.md.

D29 · Static Analysis (SAST)1.6 / 10Critical✓ Tool-verified

What it measures: Real static-analysis (SAST) findings — likely security bugs in the code, any language.

Method: Polyglot static analysis via semgrep across the repo using the pinned, image-baked p/security-audit + p/owasp-top-ten rulesets (no scan-time registry fetch); severity rules (ERROR/WARNING/INFO) map to a full-band severity-weighted score. Exhaustive, deterministic; degrades on parse failure.

Coverage: semgrep pattern rules over all files — exhaustive for the rule set, blind to classes of bug without a rule (clean = no rule matched).

Maturity: Documented → Verified → Prevented · effective 1.6 / 10 · rule-coverage 100% · ceiling Documented

14 finding(s): 0 critical, 12 high, 2 medium, 0 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 15 file(s) — `REDACTED`, `helm/warpgate/templates/configmap.yaml`, `REDACTED`, `helm/warpgate/templates/extra-manifests.yaml`, `helm/warpgate/templates/httproute.yaml`, … (+10 more) — 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 4 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.

REDACTED
REDACTED
REDACTED
REDACTED
REDACTED

+ 2 more group(s) — more in Appendix A; the complete list is findings.md.

What to do

  1. Resolve the 7 REDACTED finding(s) in Static Analysis (SAST) — start with REDACTED (2), REDACTED, REDACTED. — One of this dimension's main actionable groups (7 issue-level).
  2. Resolve the 1 REDACTED finding(s) in Static Analysis (SAST) — start with REDACTED. — One of this dimension's main actionable groups (1 issue-level).
  3. 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).

Detailed fixes: d29_recommendation.md · top locations in Appendix A, every location in findings.md.

D30 · Dependency Vulnerabilities3.4 / 10Weak✓ Tool-verified

What it measures: Whether any dependency has a known published vulnerability (CVE), direct or transitive, in ANY ecosystem the repository declares — Dart pub, Elixir and Erlang via Hex, Go modules, Java and Kotlin via Maven/Gradle, JavaScript/npm, .NET/NuGet, PHP/Composer, Python/PyPI, RubyGems, Rust/Cargo and Swift.

Method: Dependency-CVE scan across every ecosystem the repository declares, scored ONCE. Three sources are unioned and deduplicated by advisory identity (rule id + alias closure, CVE<->GHSA) scoped to package+version, keeping the worst severity: `osv-scanner --recursive` over osv.dev for Dart pub, Elixir/Hex (and Erlang, whose `rebar.lock` syft first converts to a CycloneDX SBOM the scanner reads, with rows attributed back to the lock), Go, Java and Kotlin via Maven/Gradle (and Scala, whose sbt build's pinned direct declarations are written into a CycloneDX SBOM the scanner reads, with rows attributed back to the build file), npm, PHP/Composer, Python/PyPI, RubyGems, Rust/Cargo and Swift; `trivy fs --scanners vuln` for npm lockfiles; and `dotnet list package --vulnerable --include-transitive` for NuGet (with per-advisory collapse of the project x target-framework fan-out), plus a DECLARED-dependency arm that resolves a published gem's gemspec against rubygems.org where no Gemfile.lock is committed. `SeverityScore(c,h,m,l, normalizer 8.0)`. NotApplicable only when NO ecosystem is readable; if any applicable ecosystem could not be scanned the findings are REPORTED and the score is withheld. Supersedes the npm and OSV arms, retired 2026-09-05.

Maturity: Documented → Verified → Prevented · effective 3.4 / 10 · rule-coverage 100% · ceiling Documented

18 finding(s): 1 critical, 5 high, 12 medium, 0 low.

REDACTED
REDACTED
REDACTED
REDACTED
REDACTED

+ 1 more group(s) — more in Appendix A; the complete list is findings.md.

What to do

  1. Resolve the 5 High CVE finding(s) in Dependency Vulnerabilities — start with REDACTED, REDACTED. — One of this dimension's main actionable groups (5 issue-level).
  2. Resolve the 1 Critical CVE finding(s) in Dependency Vulnerabilities — start with REDACTED. — One of this dimension's main actionable groups (1 issue-level).
  3. Resolve the 5 Medium advisory (unmaintained) finding(s) in Dependency Vulnerabilities — start with REDACTED (5). — One of this dimension's main actionable groups (5 warning-level).

Detailed fixes: d30_recommendation.md · top locations in Appendix A, every location in findings.md.

D31 · IaC & Container Security7.3 / 10Adequategated by 5 critical findings✓ Tool-verified

What it measures: Whether Dockerfiles / Terraform / Kubernetes config follow security best practices.

Method: IaC/container misconfiguration scan via trivy config (REDACTED/Terraform/K8s/Helm/CloudFormation); severity rules to 0-10 moderate normalizer. NotApplicable without manifests. Exhaustive, deterministic.

Maturity: Documented → Verified → Prevented · effective 7.3 / 10 · rule-coverage 100% · ceiling Documented

23 finding(s): 0 critical, 5 high, 8 medium, 10 low.

REDACTED
REDACTED
REDACTED

What to do

  1. Resolve the 5 High IaC finding(s) in IaC & Container Security — start with REDACTED (2), REDACTED (2), REDACTED. — One of this dimension's main actionable groups (5 issue-level).
  2. Resolve the 10 Low IaC finding(s) in IaC & Container Security — start with REDACTED (10). — One of this dimension's main actionable groups (10 recommendation-level).
  3. Resolve the 8 Medium IaC finding(s) in IaC & Container Security — start with REDACTED (6), REDACTED, REDACTED. — One of this dimension's main actionable groups (8 warning-level).

Detailed fixes: d31_recommendation.md · top locations in Appendix A, every location in findings.md.

D34 · Knowledge Freshness9.8 / 10Exemplary✓ Tool-verified

What it measures: Whether anyone still has living knowledge of each file, or it has been orphaned — last understood long ago by someone now gone quiet. The sibling of the bus factor: D16 asks who owns it, D34 asks whether anyone still knows it.

Method: File orphaning as total living-knowledge decay below one focused-commit's worth within a year, computed per-file from the D16 decay model. Exhaustive, deterministic over fixed history.

Maturity: Documented → Verified → Prevented · effective 9.8 / 10 · rule-coverage 100% · ceiling Documented

5 of 270 significant source file(s) are orphaned — their living knowledge has decayed to nothing, so no one currently understands them. The largest is warpgate-db-migrations/src/m00044_ticket_requests.rs. Counted over 270 of the 496 production source files in this repository: the rest are under the ~2,400-byte size floor this dimension measures over.

Orphaned files with no living knowledge

✓ On the Gold path — maintain.

Detailed fixes: d34_recommendation.md · top locations in Appendix A, every location in findings.md.

D35 · Change Coupling9.8 / 10Adequategated by 4 critical findings✓ Tool-verified

What it measures: Whether files that change together actually belong together — pairs that repeatedly co-change in git history despite having no explicit code dependency, surfacing the hidden/logical coupling (and boundaries in the wrong place) a static scan can't see.

Method: Pairwise co-occurrence over the per-commit file sets in git history (production source only — tests and generated dropped): Degree-of-Coupling = shared ÷ min individual revisions, reported above noise floors (each file ≥10 revisions, ≥5 shared commits, ≥50% strength); sweeping commits excluded. Deterministic over fixed history.

Coverage: Population: PRODUCTION source files only — test and generated files are dropped before pairing, so a class co-changing with its own test (trivially ~100%) can't drown the real production↔production coupling. Pairs ranked by Degree-of-Coupling. A non-source file is never a coupling PARTICIPANT either: documentation, schemas, config and data files are dropped with the rest, so a code↔docs pair — a command and the reference page that restates it — is not reported however strongly the two co-change; nor is coupling that runs THROUGH a build step or config file.

Maturity: Documented → Verified → Prevented · effective 9.8 / 10 · rule-coverage 100% · ceiling Documented

Strongest change-coupling: parameters.rs↔lib.rs 86%; lib.rs↔lib.rs 77%; handler.rs↔russh_handler.rs 75%

Boundary-crossing change coupling: parameters.rs ↔ lib.rs · ×4warpgate-admin/src/api/parameters.rs
Change coupling: handler.rs ↔ russh_handler.rs · ×2warpgate-protocol-ssh/src/client/handler.rs

What to do

  1. Resolve the 4 Boundary-crossing change coupling finding(s) in Change Coupling — start with parameters.rs, lib.rs, session.rs. — One of this dimension's main actionable groups (4 issue-level).
  2. Resolve the 2 Change coupling finding(s) in Change Coupling — start with handler.rs (2). — One of this dimension's main actionable groups (2 warning-level).

Detailed fixes: d35_recommendation.md · top locations in Appendix A, every location in findings.md.

D36 · Supply-chain Provenance & Signing7.5 / 10Strong✓ Tool-verified

What it measures: Whether the build pipeline provides supply-chain integrity — generated provenance/attestation, signed artifacts (cosign/sigstore), an SBOM, and pinned build actions. Presence of the configuration, not a runtime guarantee.

Method: Supply-chain provenance/signing read deterministically from CI/build config (.github/workflows, .gitlab-ci.yml, azure-pipelines, Jenkinsfile, .circleci) + the release surface: four signals — generated provenance/attestation (SLSA/in-toto/actions-attest), artifact signing (cosign/sigstore/gitsign), an SBOM (syft/sbom-action/*.spdx.json/*.cdx.json), and SHA-pinned build actions — scored 10·present/denom. NotApplicable without a build pipeline. Detects configuration presence, not runtime enforcement.

Maturity: Documented → Verified → Prevented · effective 7.5 / 10 · rule-coverage 100% · ceiling Documented

3/4 supply-chain integrity signals present (provenance, signing, SBOM, pinned actions).

REDACTED
REDACTED
REDACTED
REDACTED

What to do

  1. Resolve the 1 REDACTED finding(s) in Supply-chain Provenance & Signing. — One of this dimension's main actionable groups (1 warning-level).
  2. Resolve the 1 REDACTED finding(s) in Supply-chain Provenance & Signing — start with REDACTED. — One of this dimension's main actionable groups (1 warning-level).
  3. Resolve the 1 REDACTED finding(s) in Supply-chain Provenance & Signing. — One of this dimension's main actionable groups (1 warning-level).

Detailed fixes: d36_recommendation.md · top locations in Appendix A, every location in findings.md.

D37 · Vulnerability-disclosure Policy10.0 / 10Exemplary✓ Tool-verified

What it measures: Whether the repository publishes a coordinated-vulnerability-disclosure policy (SECURITY.md or security.txt) with a reporting contact, so finders know how to report a vulnerability. Presence of a policy file with a contact, not whether the policy is adequate or honoured.

Method: Vulnerability-disclosure policy read deterministically from the repo: a SECURITY.md (root/.github/docs) or .well-known/security.txt / security.txt, regex-checked for a reporting contact (email / URL / mailto). Present + contact → 10; present without a contact → 4; NotApplicable when no policy file exists (it may live off-repo). Detects the policy file's presence + contact, not its adequacy.

Maturity: Documented → Verified → Prevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Documented

A vulnerability-disclosure policy (SECURITY.md) is published with a reporting contact.

✓ On the Gold path — maintain.

Detailed fixes: d37_recommendation.md.

D40 · Network Egress Confinement6.0 / 10Adequate✓ Tool-verified

What it measures: Whether Kubernetes workloads restrict network EGRESS with a NetworkPolicy (or Cilium policy), limiting where a compromised pod can send data or reach a command-and-control server. Presence of committed egress-restricting policy, not runtime enforcement.

Method: Deterministic YAML-manifest inspection (no external tool, no Roslyn — language-agnostic): Kubernetes workloads gate applicability; credits a NetworkPolicy / Cilium policy that restricts egress (policyTypes: [Egress] / egress rules). Reward-leaning (neutral floor climbing to 10, never a deduction — baseline misconfigs stay with D31). Deterministic.

Maturity: Documented → Verified → Prevented · effective 6.0 / 10 · rule-coverage 100% · ceiling Documented

0/2 network-egress controls present (network policy, egress restriction).

No network policy

What to do

  1. Resolve the 1 No network policy finding(s) in Network Egress Confinement. — One of this dimension's main actionable groups (1 recommendation-level).

Detailed fixes: d40_recommendation.md · top locations in Appendix A, every location in findings.md.

D41 · Kernel & Syscall Confinement6.0 / 10Adequate✓ Tool-verified

What it measures: Whether Kubernetes workloads confine the kernel boundary — a seccomp profile (RuntimeDefault/Localhost) plus an AppArmor/SELinux mandatory-access-control layer — shrinking the syscall attack surface a container escape would use. Presence of committed confinement config, not runtime enforcement.

Method: Deterministic YAML-manifest inspection (no external tool, no Roslyn): on Kubernetes workloads, credits a seccomp profile (RuntimeDefault/Localhost) and an AppArmor/SELinux MAC layer. Reward-leaning (neutral floor climbing to 10); NotApplicable without workloads. Deterministic.

Maturity: Documented → Verified → Prevented · effective 6.0 / 10 · rule-coverage 100% · ceiling Documented

0/2 syscall-confinement controls present (seccomp, AppArmor/SELinux).

No seccomp profile
No AppArmor/SELinux confinement

What to do

  1. Resolve the 1 No seccomp profile finding(s) in Kernel & Syscall Confinement. — One of this dimension's main actionable groups (1 recommendation-level).
  2. Resolve the 1 No AppArmor/SELinux confinement finding(s) in Kernel & Syscall Confinement. — One of this dimension's main actionable groups (1 recommendation-level).

Detailed fixes: d41_recommendation.md · top locations in Appendix A, every location in findings.md.

D43 · Malicious Dependencies10.0 / 10Exemplary✓ Tool-verified

What it measures: Whether any dependency the repository declares is published as MALICIOUS rather than merely vulnerable — a package that is an attacker's work, in any ecosystem osv-scanner reads. Scored apart from D30 because the answer is binary: there is no safe version to upgrade to, and the fix is to remove the package and rotate every credential it could have read.

Method: The same dependency scan D30 reads, partitioned on the scanner's own classification rather than rescanned: a row is MALICIOUS when its id is in the `MAL-` space (the ossf/malicious-packages feed) OR its `database_specific.cwe_ids` carries `CWE-506` ("Embedded Malicious Code"). Both channels are structural; the summary text is deliberately NOT read, because a malicious-package record whose summary says only "Critical severity vulnerability" is a real shape ([GHSA redacted]) and a text matcher misses it. Scored BINARY: any surviving row is 0, whatever its severity and however many CVEs sit beside it — a hostile dependency is not a quantity. Applicability and degradation are D30's: NotApplicable only when no ecosystem is readable, and an unscannable ecosystem degrades rather than reading clean. SCORED, not informational.

Maturity: Documented → Verified → Prevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Documented

No dependency in any ecosystem this repository declares is published as malicious.

✓ On the Gold path — maintain.

Detailed fixes: d43_recommendation.md.

D44 · Platform End-of-Life6.0 / 10Adequate✓ Tool-verified

What it measures: Whether anyone still ships security patches for the platform this repository RUNS ON — the runtime it pins and the framework majors its own constraints hold it to. Separate from D12 because the question differs: a current Django on an end-of-life Python is perfectly up to date and completely unsupported, and the fix is a migration rather than a version bump. What the repository says it merely SUPPORTS is never charged.

Method: End-of-life PLATFORM read from the repository's own declarations and graded against a FROZEN, dated table of vendor support dates — no network, no feed, no API, so this dimension answers identically inside a closed scan fence. Two subjects: a RUNTIME the project pins (a single or all-end-of-life TargetFramework, a .nvmrc or .python-version, a requires-python CAP) and a FRAMEWORK major a dependency constraint cannot move off (a caret, tilde or exact version; `vue@^2.7.16` pins Vue 2). A FLOOR is deliberately never charged — `requires-python = ">=3.8"` states what a package SUPPORTS, not what it runs on — and a multi-target project is charged only when EVERY target is out of support. Runtime 4.0/product capped 8.0, framework 1.5 capped 4.5. The table is safe to freeze because a statement about support that ended in the past cannot become false: it loses recall as it ages, never precision, and a test asserts every entry predates the freeze date. Disjoint from D31 (a container image's OS layer) and D29 (the toolchain a CI workflow installs). Abstains when the repository declares no platform this pass reads — never scores it clean.

Maturity: Documented → Verified → Prevented · effective 6.0 / 10 · rule-coverage 100% · ceiling Documented

1 end-of-life runtime(s) and 0 end-of-life framework(s), read from 2 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.

End-of-life runtime: .NET net6.0

What to do

  1. Resolve the 1 End-of-life runtime finding(s) in Platform End-of-Life. — One of this dimension's main actionable groups (1 warning-level).

Detailed fixes: d44_recommendation.md · top locations in Appendix A, every location in findings.md.

Frontend & cross-cutting dimensions

R = React/JS · M = Maturity · P = Readiness.

AX10 · Code composition0.0 / 10Critical✓ Tool-verified

Other · Architecture — How the codebase splits by code ROLE — domain, application, infrastructure, test, generated. The significance map behind the knowledge/coupling weighting, and a DDD signal in its own right: a thin domain core under fat infrastructure is the anemic-domain smell, quantified. How each file's role is decided, because the split is only as good as that: a generated name or a build-output tree makes it Generated, a test project makes it Test, and otherwise the file's NAMESPACE and PATH words are matched against fixed vocabularies in a fixed ORDER — domain, then infrastructure, then application — so a file whose words hit two layers is counted under the earlier one. A production file matching none of them counts as application, so that share reads 'application or unclassified' rather than a measured application layer. Roles come from naming convention, never from what the code does.

Method: Roslyn line-count by code ROLE: every source file classified Domain/Application/Infrastructure/Test/Generated by namespace + path convention (the shared CodeRoleClassifier), then significant lines summed per role. Deterministic; the advisory score is the business-logic (domain+application) share of production code.

Coverage: Population: ALL source files, each bucketed into ONE of five roles (Domain/Application/Infrastructure/Test/Generated) by namespace + path convention — a file whose layer isn't named in the convention falls to Application (the neutral default), and the split is line-count, not semantic depth or business value.

AX3 · Project dependency cycles10.0 / 10Exemplary✓ Tool-verified

Other · Architecture — Whether the project-reference graph is acyclic (cycles block independent build/deploy and signal eroding boundaries).

Method: Project reference cycles via elementary-DFS over real .csproj references, using the engine shared with D5/D7; cyclic versus acyclic. Exhaustive, deterministic.

AX4 · Dependency direction10.0 / 10Exemplary✓ Tool-verified

Other · Architecture — Whether dependencies point inward (Domain ← Application ← Infrastructure/Web) — the clean-architecture dependency rule, checked across the project graph.

Method: Layer violations by name-segment inference (Domain/Core to Application to Infrastructure/Web) over the project-reference graph. Exhaustive over all projects, deterministic.

AX5 · Architecture & structure10.0 / 10Exemplary✓ Tool-verified

Other · Architecture — Whether the codebase has a recognisable, scale-appropriate structure (a named architectural style, or modular enough for its size) rather than being an ad-hoc ball of mud.

Method: Roslyn plus csproj analysis: architecture style detection (DDD, clean, vertical-slice, CQRS) and structure fitness for repo size. Deterministic.

AX8 · Test isolation10.0 / 10Exemplary✓ Tool-verified

Other · Architecture — Whether production projects stay free of references to test projects — tests may depend on production, never the reverse.

Method: Csproj graph: each production project checked for references to test projects (identified by test-framework presence, not name). Zero violations is clean. Deterministic.

AX9 · CQS / query purity10.0 / 10Exemplary✓ Tool-verified

Other · Architecture — Whether read (query) handlers stay side-effect-free — a query that writes persistent state or raises events breaks CQS and makes reads unsafe to retry, cache, or route to a read replica.

Method: Roslyn scan: CQRS handlers classified query-vs-command by interface (IQueryHandler/ICommandHandler/IRequestHandler<TQuery,TResult>) and name convention (*Query/Get*/Find* vs *Command); each query handler's body checked for persistent-state writes (SaveChanges/repository Add-Update) or event publishes by resolved invocation. Deterministic, type-level, exhaustive over the detected handlers.

Coverage: Population: CQRS handlers identified by IQueryHandler/ICommandHandler/IRequestHandler interface + *Query/Get*/Find*/*Command NAME convention; query purity then checked exhaustively within that set — a query handler using neither convention is invisible, and mutation is a resolved persistence/publish CALL, not full dataflow.

DM1 · Aggregate boundaries10.0 / 10Exemplary✓ Tool-verified

Other · Domain Modelling — Whether an aggregate references another aggregate by identity rather than embedding it by object reference.

Method: Roslyn (DDD-gated): aggregate roots identified by convention; each aggregate field checked for direct references to other aggregates versus id-only. Deterministic, DDD-native.

Coverage: Population: aggregate roots identified by AggregateRoot/IAggregateRoot base/interface NAME convention; reference-by-identity then checked exhaustively within that set — a root not using those names is invisible.

DM2 · Strongly-typed ids10.0 / 10Exemplary✓ Tool-verified

Other · Domain Modelling — Whether domain identifiers are strongly typed (a newtype wrapper) rather than raw primitives — consistency once an idiom exists.

Method: Roslyn (DDD-gated): strongly-typed id adoption on domain entities/events; raw Guid/int/string ids counted versus wrapped types. An id wrapper is recognised by VALUE SEMANTICS, not by being a struct — a record struct, a record class (`record ApartmentId(Guid Value)`) or a class declared by a typed-id base (`class MemberId : TypedIdValueBase`) all count, while a plain mutable class (reference equality) and a verb-phrase query record (`GetCustomerById`) do not. Deterministic, adoption percentage.

Coverage: Population: id-like members by *Id/*Key NAME suffix; strongly-typed-ID shape then checked semantically — non-suffixed identifiers are not seen.

DM4 · Rich vs anemic domain model10.0 / 10Exemplary✓ Tool-verified

Other · Domain Modelling — Whether domain entities own their behaviour (invariant-enforcing commands) rather than being data-only structs driven by a foreign service.

Method: Roslyn (DDD-gated): entity method BODIES classified mutator-vs-query — only methods that mutate the entity's own declared state count as invariant-protecting behaviour, so a getter/passthrough doesn't rescue an anemic class. Deterministic, exhaustive over domain-layer entities.

Coverage: Population: entities by name/base convention; rich-vs-anemic judged by classifying each method body mutator-vs-query — logic-bearing domain types outside the convention are invisible.

DM5 · Encapsulated state10.0 / 10Exemplary✓ Tool-verified

Other · Domain Modelling — Whether a domain type's identity-bearing field stays immutable — a `pub` mutable field under a hand-rolled Hash/PartialEq breaks the value-identity invariant.

Method: Roslyn (DDD-gated): entities scanned for publicly writable state — public setters, and (C#/VB) own mutable collections handed out through an auto-property, a public field or a bare-field expression getter, where a computed/copying getter is never charged. One finding per entity; score softened when Marten/EF rehydration frameworks present. Deterministic, framework-aware.

Coverage: Population: entities by convention; encapsulation (setter shape) checked exhaustively within the set.

DM6 · Domain ↔ infrastructure boundary10.0 / 10Exemplary✓ Tool-verified

Other · Domain Modelling — Whether the domain layer stays free of infrastructure dependencies — a domain aggregate fused to a persistence ORM (diesel/sea-orm/sqlx) on its own declaration (active-record) couples the domain to infrastructure. The clean-architecture dependency rule.

Method: Roslyn (DDD-gated): domain-layer types scanned for infrastructure usage in member SIGNATURES and inside method/accessor BODIES — resolved calls and object-creations into EF/Marten/HTTP/Mongo/Redis/message-bus types (not just a namespace allowlist). Deterministic, symbol-resolved, exhaustive over domain-layer bodies, DDD-native.

Coverage: Domain layer identified by NAMESPACE heuristic; infrastructure then resolved by symbol in member SIGNATURES and method/accessor BODIES — rename the layer and the check evaporates.

ES1 · Fold determinism10.0 / 10Exemplary✓ Tool-verified

Other · Event Sourcing — Whether the recovery-replay fold is deterministic — state derived purely from each event's own fields, no clock/random/IO on the replay path.

Method: Roslyn syntax scan (event-sourcing gated): Apply/When folds checked for forbidden tokens (DateTime.Now, Guid.NewGuid, Random, IO), stripped of comments/strings. Deterministic, hard fact per fold.

ES2 · Immutable events10.0 / 10Exemplary✓ Tool-verified

Other · Event Sourcing — Whether domain events stay immutable (private fields, set once) rather than carrying mutable state.

Method: Roslyn scan (event-sourcing gated): persisted events checked for public setters; immutability verified per property/field. Deterministic, hard fact.

GD1 · Unfinished & placeholder code10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Unreviewed-generation residue: shipped members still throwing NotImplementedException, and placeholder string literals left in non-test, non-generated code. Scored as a quality signature, never as a claim about authorship.

Method: Roslyn syntax scan: NotImplementedException throws and placeholder string literals in non-test, non-generated shipped code. Deterministic, code-shape signature.

IC1 · Incompleteness & stubs10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Unfinished work detected by code SHAPE, not keywords: members that only throw a "not implemented" exception, methods that take inputs and return a constant, async methods that never await, dead `if (false)` / `#if false` branches, and skeleton types most of whose members are holes. A real, objective slice of technical debt.

Method: Roslyn syntax scan: incompleteness by code shape (constant-returning methods, async-never-await, #if false branches, guards that return what the code already falls through to, tests an earlier guard already decided, comparisons against NaN, skeleton types), not keyword-gated. Deterministic, code-shape heuristic.

M1 · Documentation (README)7.3 / 10Strong✓ Tool-verified

Maturity · Maturity — Whether the repo and its projects have a README, and whether it's substantive and current.

Method: Filesystem scan: README presence, word count, and headings for depth; git history for staleness. Exhaustive across root and project dirs, deterministic.

What to do

  • Add a 'Testing' section to the root README — how to run the test suite.
  • Add a README to the 2 of 2 project(s) that lack one — worth up to 2 pts.
M2 · Architecture documentation2.0 / 10Critical✓ Tool-verified

Maturity · Maturity — Whether key decisions (ADRs) and the high-level shape (C4/diagrams) are written down.

Method: Filesystem scan: ADR folder/naming conventions or content, plus Mermaid/PlantUML/C4/architecture.md discovery. Exhaustive, deterministic.

  • 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 significant decisions one document per decision — dated, stating the context, the decision and its consequences — and keep them together wherever your design docs already live (a conventional `docs/adr/` tree, with each file named `NNNN-title` in whatever markup those docs already use, is the most discoverable form).
M3 · Folder & project structure10.0 / 10Exemplary✓ Tool-verified

Maturity · Maturity — Whether the repo is organised deliberately — src/test separation and consistent project naming.

Method: Filesystem scan: src/test folder separation and namespace-prefix consistency (majority RootNamespace agreement). Exhaustive across projects, deterministic.

M4 · Documentation accuracy9.0 / 10Exemplary◐ Sampled · advisory

Maturity · Maturity — Whether the README actually describes the code that exists (LLM-judged, advisory).

Method: Judged by language model at low temperature: README accuracy versus actual projects, within a disclosed tolerance. Advisory, not a measured number.

P1 · CI/CD gates10.0 / 10Exemplary○ Nothing flagged

Readiness · Readiness — Whether an automated pipeline builds and tests every change.

Method: Filesystem scan: CI workflow files (.github/workflows, .gitlab-ci.yml, etc.) for build and test stages. Exhaustive, deterministic.

P2 · Observability8.0 / 10Strong✓ Tool-verified

Readiness · Readiness — Whether the code is diagnosable in production — structured logging, tracing/metrics, health checks.

Method: Filesystem/Roslyn scan: structured-logging frameworks (Serilog, NLog), OpenTelemetry, and health-check endpoint patterns. Exhaustive, deterministic.

What to do

  • Add OpenTelemetry tracing/metrics (opentelemetry with tracing-opentelemetry) so requests are traceable across the system, not just health-probable.
P3 · Security & performance tooling7.0 / 10Strong✓ Tool-verified

Readiness · Readiness — Whether SAST, secret/dependency scanning and performance benchmarking are wired in (presence, not runtime).

Method: Filesystem scan: SAST configuration, dependency-update automation, secret scanning, and a benchmark harness or benchmark step — in this repository's own ecosystem. Exhaustive, deterministic.

What to do

  • Add gitleaks/trufflehog in CI to block PRs that introduce committed secrets.
P4 · Deployment & Rollback10.0 / 10Exemplary✓ Tool-verified

Readiness · Readiness — Whether releases are automated and safely reversible (probes, rolling updates, approval gates) — from manifests/pipeline files, not the live environment.

Method: Filesystem scan: deployment manifests/IaC (K8s YAML, Helm, Terraform) for rolling updates, probes, approval gates, migration hooks. Exhaustive, deterministic.

P5 · DR & Backup7.0 / 10Strong✓ Tool-verified

Readiness · Readiness — Whether disaster recovery is planned and codified — backups, geo-recovery, RTO/RPO, persistence guarantees — from IaC + container manifests + docs, never the live cloud.

Method: Filesystem scan: disaster recovery, backup, geo-recovery, RTO/RPO, persistence guarantees from IaC, manifests, and docs. Exhaustive, deterministic, never a live environment.

What to do

  • Document RTO/RPO and a tested restore procedure (a backup config alone isn't disaster recovery).
P6 · Release Hygiene10.0 / 10Exemplary✓ Tool-verified

Readiness · Readiness — Whether releases are traceable — a maintained changelog and explicit version stamping.

Method: Filesystem scan: changelog file presence and version tags in csproj or git tags. Exhaustive, deterministic.

R1 · Type Safety10.0 / 10Exemplary✓ Tool-verified

React / JS · Code Health — How much of the frontend is typed TypeScript vs untyped JavaScript.

Method: Frontend file inventory: the share of typed TypeScript vs untyped JavaScript across the source tree. Deterministic, exhaustive over frontend files.

R10 · Code Duplication9.5 / 10Exemplary✓ Tool-verified

React / JS · Code Health — Near-exact copy-pasted blocks of substantial extent across the frontend (the D4 clone algorithm over JS/TS tokens, D-386): a block is reported only where its copies still agree on most of their own identifiers and literals, or were renamed as they were pasted but kept most of their constants, and where the copies carry enough code to stand on their own or the copied extent reaches 30 lines — so a re-implementation sharing neither names nor values, and a small pasted declaration, are both found and deliberately not reported, and a clean R10 is not a claim that nothing was copied.

Method: Near-exact copy-pasted blocks of substantial extent across the frontend (the D4 clone algorithm run over JS/TS tokens). Masking finds the candidates; a block is reported when its copies still agree on most of their own identifiers and literals, or when a renamed copy still agrees on most of its constants, AND the copies carry enough code to stand on their own — or when the copied extent reaches 30 lines. So a re-implementation sharing neither names nor values, and a small pasted declaration, are deliberately not counted. Deterministic.

  • warpgate-web/src/gateway/WebDesktop.svelte:446 · warpgate-web/src/gateway/WebSsh.svelte:258 — the 2 copies sit in sibling files in one directory, so check first whether one of them (or an existing module there) already owns this behaviour and the others should call it; otherwise extract it into one module in that directory and have each site call it. — warpgate-web/src/gateway/WebDesktop.svelte:446
  • warpgate-web/src/admin/config/AccessRoles.svelte:12 · warpgate-web/src/admin/config/users/Users.svelte:21 — the 2 copies are spread across 2 directories, so the shared home is a decision rather than an obvious spot: check first whether one of them already owns this behaviour, and otherwise put the extracted module somewhere all of the sites already reach rather than making one of them depend on another. — warpgate-web/src/admin/config/AccessRoles.svelte:12
  • warpgate-web/src/admin/config/Parameters.svelte:80 · warpgate-web/src/admin/config/Policies.svelte:16 — the two spans are one implementation copied and then locally edited — 93 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one. — warpgate-web/src/admin/config/Parameters.svelte:80
  • warpgate-web/src/admin/player/DesktopRecordingPlayer.svelte:140 · warpgate-web/src/admin/player/TerminalRecordingPlayer.svelte:202 — the 2 copies are spread across 2 files, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — warpgate-web/src/admin/player/DesktopRecordingPlayer.svelte:140
  • warpgate-web/src/admin/config/AccessRoles.svelte:19 · warpgate-web/src/admin/config/target-groups/TargetGroups.svelte:12 · warpgate-web/src/admin/config/users/Users.svelte:28 — the 3 copies are spread across 3 files, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — warpgate-web/src/admin/config/AccessRoles.svelte:19
  • warpgate-web/src/admin/config/ldap/CreateLdapServer.svelte:48 · warpgate-web/src/admin/config/ldap/LdapServer.svelte:82 — the 2 copies sit in sibling files in one directory, so check first whether one of them (or an existing module there) already owns this behaviour and the others should call it; otherwise extract it into one module in that directory and have each site call it. — warpgate-web/src/admin/config/ldap/CreateLdapServer.svelte:48
  • warpgate-web/src/admin/config/AccessRole.svelte:27 · warpgate-web/src/admin/config/AccessRole.svelte:43 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. — warpgate-web/src/admin/config/AccessRole.svelte:27
  • warpgate-web/src/admin/config/AccessRole.svelte:62 · warpgate-web/src/admin/config/AdminRole.svelte:127 · warpgate-web/src/admin/config/targets/Target.svelte:81 — the 3 copies are spread across 3 files, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — warpgate-web/src/admin/config/AccessRole.svelte:62
  • REDACTED:203 · REDACTED:224 — all 2 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — REDACTED:203
  • warpgate-web/src/gateway/lib/certificateStore.ts:24 · warpgate-web/src/gateway/lib/certificateStore.ts:48 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. — warpgate-web/src/gateway/lib/certificateStore.ts:24
  • warpgate-web/src/admin/lib/api.ts:8 · warpgate-web/src/gateway/lib/api.ts:4 — the 2 copies are spread across 2 directories, so the shared home is a decision rather than an obvious spot: check first whether one of them already owns this behaviour, and otherwise put the extracted module somewhere all of the sites already reach rather than making one of them depend on another. — warpgate-web/src/admin/lib/api.ts:8
  • warpgate-web/src/admin/status/Session.svelte:64 · warpgate-web/src/admin/status/Session.svelte:78 — all 2 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — warpgate-web/src/admin/status/Session.svelte:64
  • REDACTED:100 · REDACTED:126 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. — REDACTED:100

What to do

  • Act on each finding's own remediation rather than one rule: the move depends on what recurs. Where the copies are executable blocks, give the shared part one home and call it from each site; where they are declarations, a listing, a specialisation already delegating to its base, or one shape repeated per entity, there is no call site and the move is a shared type, a generated set or a factory — sometimes there is nothing to extract.
R2 · Cyclomatic Complexity9.0 / 10Exemplary✓ Tool-verified

React / JS · Code Health — Per-function cyclomatic/cognitive complexity from the token-level function scanner (D-386) — real branching, not a regex heuristic.

Method: Per-function cyclomatic/cognitive complexity from a token-level function scanner (real branching, not a regex heuristic), computed over every frontend function. Deterministic.

  • mfaEnforcedFactor has cyclomatic complexity 14 and cognitive complexity 14; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — warpgate-web/src/admin/config/users/AuthPolicyEditor.svelte:113
  • parseHumantimeDuration has cyclomatic complexity 13 and cognitive complexity 12; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — warpgate-web/src/common/duration.ts:35
  • getEffectivePossibleCredentials has cyclomatic complexity 12 and cognitive complexity 18; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — REDACTED:331
  • (anonymous) has cyclomatic complexity 12 and cognitive complexity 11; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — warpgate-web/src/admin/player/DesktopRecordingPlayer.svelte:121
  • reset has cyclomatic complexity 12 and cognitive complexity 7; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — warpgate-web/src/admin/config/secret-backends/SecretBackendModal.svelte:46
  • onMessage has cyclomatic complexity 12 and cognitive complexity 6; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — warpgate-web/src/gateway/WebSsh.svelte:152
  • recordingMetadataToFieldSet has cyclomatic complexity 12 and cognitive complexity 5; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — warpgate-web/src/common/recordings.ts:63
  • updateActiveSectionFromScroll has cyclomatic complexity 11 and cognitive complexity 18; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — warpgate-web/src/admin/lib/SectionedForm.svelte:23
  • onWsMessage has cyclomatic complexity 11 and cognitive complexity 11; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — warpgate-web/src/gateway/WebDesktop.svelte:134
  • save has cyclomatic complexity 11 and cognitive complexity 10; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — warpgate-web/src/admin/config/Parameters.svelte:114

What to do

  • Break down the listed branch-heavy functions; aim P95 cyclomatic ≤ 5.
R3 · Large Files7.7 / 10Strong✓ Tool-verified

React / JS · Code Health — How many source files exceed the large-file threshold.

Method: Components/modules exceeding the large-file threshold, counted exhaustively across the frontend source tree. Deterministic.

What to do

  • Split each oversized file along the responsibilities already in it, into smaller focused modules in the same package.
R5 · Dependency Freshness10.0 / 10Exemplary✓ Tool-verified

React / JS · Readiness — How outdated the npm dependencies are (a maturity signal). JS/npm CVEs are scored separately in D30 (JS/npm Dependency Vulnerabilities).

Method: npm dependency staleness from manifest/registry metadata (a maturity signal; JS/npm CVEs are scored separately in D30, which answers dependency vulnerabilities for every ecosystem). Deterministic.

R6 · Tooling10.0 / 10Exemplary✓ Tool-verified

React / JS · Readiness — Whether the project wires up test, lint and typecheck — detected from each package.json script's COMMAND (eslint / tsc / vitest / jest / playwright), not just its name, and corroborated against CI-workflow invocations so a tool run only in CI still counts.

Method: package.json scanned for test/lint/typecheck script wiring. Deterministic presence check.

R7 · Dead Code0.0 / 10Critical✓ Tool-verified

React / JS · Code Health — Files unreachable from every application/tooling/test entry point, and exports nothing imports (module-graph reachability, D-386).

Method: Dead code: files unreachable from every application/tooling/test entry point plus exports nothing imports, via module-graph reachability. Deterministic, exhaustive over the import graph.

  • Unreachable from the 2 application, 4 tooling and 1 test entry point(s) detected in this repo. Gate removals on `npm run build` — an undetected custom entry would make these reachable.
  • no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 2 in-repo import(s) from 2 other file(s) do name it (warpgate-web/src/admin/Log.svelte, warpgate-web/src/admin/status/Session.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it — warpgate-web/src/admin/log-viewer/LogViewer.svelte
  • no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 2 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/gateway/Root.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it (×2) — warpgate-web/src/gateway/WebDesktop.svelte, warpgate-web/src/gateway/WebSsh.svelte
  • no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 4 in-repo import(s) from 4 other file(s) do name it (warpgate-web/src/admin/config/users/AuthPolicyEditor.svelte, warpgate-web/src/admin/config/users/CredentialEditor.svelte, warpgate-web/src/admin/status/Session.svelte and 1 more) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it — REDACTED
  • no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/gateway/WebSsh.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it — warpgate-web/src/gateway/WebSshTab.svelte
  • no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 2 in-repo import(s) from 2 other file(s) do name it (warpgate-web/src/admin/player/DesktopRecordingPlayer.svelte, warpgate-web/src/gateway/WebDesktop.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it (×2) — warpgate-web/src/common/desktopInput.ts, warpgate-web/src/common/desktopCanvas.ts
  • no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/admin/status/Recording.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it (×2) — warpgate-web/src/admin/player/TerminalRecordingPlayer.svelte, warpgate-web/src/admin/player/DesktopRecordingPlayer.svelte
  • no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/admin/config/Config.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it (×6) — warpgate-web/src/admin/config/users/User.svelte, warpgate-web/src/admin/config/Parameters.svelte, warpgate-web/src/admin/config/AdminRole.svelte, …
  • no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 2 in-repo import(s) from 2 other file(s) do name it (warpgate-web/src/admin/config/users/AuthPolicyEditor.svelte, warpgate-web/src/admin/config/users/User.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it — warpgate-web/src/admin/config/users/CredentialEditor.svelte
  • no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 2 in-repo import(s) from 2 other file(s) do name it (warpgate-web/src/admin/player/DesktopRecordingPlayer.svelte, warpgate-web/src/admin/player/TerminalRecordingPlayer.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it — warpgate-web/src/admin/player/playbackController.ts
  • no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 7 in-repo import(s) from 7 other file(s) do name it (warpgate-web/src/admin/config/ClientKeyModal.svelte, warpgate-web/src/admin/config/SSHKeys.svelte, warpgate-web/src/admin/config/secret-backends/SecretBackends.svelte and 4 more) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it — warpgate-web/src/common/SecretRefInput.svelte
  • no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 2 in-repo import(s) from 2 other file(s) do name it (warpgate-web/src/admin/config/Policies.svelte, warpgate-web/src/admin/config/users/CredentialEditor.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it — warpgate-web/src/admin/config/users/AuthPolicyEditor.svelte
  • no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 5 in-repo import(s) from 5 other file(s) do name it (warpgate-web/src/admin/config/CreateTicket.svelte, warpgate-web/src/admin/config/targets/Target.svelte, warpgate-web/src/gateway/TargetList.svelte and 2 more) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it — warpgate-web/src/common/ConnectionInstructions.svelte
  • no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/gateway/App.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it (×2) — warpgate-web/src/gateway/TicketRequests.svelte, warpgate-web/src/gateway/TargetList.svelte
  • no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 13 in-repo import(s) from 13 other file(s) do name it (warpgate-web/src/admin/config/AccessRole.svelte, warpgate-web/src/admin/config/AccessRoles.svelte, warpgate-web/src/admin/config/AdminRole.svelte and 10 more) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it — warpgate-web/src/common/ItemList.svelte
  • no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/admin/config/targets/ProtocolDocs.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it — warpgate-web/src/admin/config/targets/protocolInfo.ts
  • no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/admin/status/Status.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it — warpgate-web/src/admin/status/Requests.svelte
  • no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/admin/status/Session.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it — warpgate-web/src/common/recordings.ts
  • no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 3 in-repo import(s) from 3 other file(s) do name it (warpgate-web/src/admin/config/users/CredentialEditor.svelte, warpgate-web/src/common/ConnectionInstructions.svelte, warpgate-web/src/gateway/CredentialManager.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it — warpgate-web/src/admin/CertificateCredentialModal.svelte
  • no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/admin/config/targets/ssh/Options.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it — warpgate-web/src/admin/config/targets/ssh/KeyChecker.svelte
  • no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 29 in-repo import(s) from 29 other file(s) do name it (warpgate-web/src/admin/App.svelte, warpgate-web/src/admin/config/AccessRole.svelte, warpgate-web/src/admin/config/AccessRoles.svelte and 26 more) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it — warpgate-web/src/admin/lib/store.ts
  • no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/gateway/WebDesktop.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it — warpgate-web/src/common/desktopClipboard.ts
  • no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 6 in-repo import(s) from 6 other file(s) do name it (warpgate-web/src/admin/config/Tickets.svelte, warpgate-web/src/admin/status/Requests.svelte, warpgate-web/src/common/DurationInput.svelte and 3 more) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it — warpgate-web/src/common/duration.ts
  • no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/gateway/Root.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it — warpgate-web/src/gateway/App.svelte
  • no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 3 in-repo import(s) from 3 other file(s) do name it (warpgate-web/src/admin/config/Parameters.svelte, warpgate-web/src/admin/config/targets/Target.svelte, warpgate-web/src/admin/config/users/User.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it (×2) — warpgate-web/src/admin/lib/SectionedForm.svelte, warpgate-web/src/common/RateLimitInput.svelte
  • no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/gateway/ProfileCredentials.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it — warpgate-web/src/gateway/CredentialManager.svelte
  • no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/admin/player/playbackController.ts) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it — warpgate-web/src/common/liveRecordingStream.ts
  • no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 3 in-repo import(s) from 3 other file(s) do name it (warpgate-web/src/admin/config/users/CredentialEditor.svelte, warpgate-web/src/gateway/CredentialManager.svelte, warpgate-web/src/gateway/MfaSetup.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it — warpgate-web/src/admin/CreateOtpModal.svelte
  • no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 3 in-repo import(s) from 3 other file(s) do name it (warpgate-web/src/admin/player/DesktopRecordingPlayer.svelte, warpgate-web/src/admin/player/TerminalRecordingPlayer.svelte, warpgate-web/src/admin/player/playbackController.ts) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it — warpgate-web/src/admin/player/rangeStream.ts
  • no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/admin/index.ts) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it — warpgate-web/src/admin/App.svelte

What to do

  • Delete the dead files and unused exports — every line is maintenance cost and rebuild-estimate inflation with zero runtime value.
R8 · Dependency Hygiene8.0 / 10Strong✓ Tool-verified

React / JS · Readiness — npm dependency truthfulness (D-386): unused dependencies, imports not declared anywhere, and type-/test-only packages shipped as production deps.

Method: npm dependency truthfulness: unused dependencies, imports declared nowhere, and type-/test-only packages shipped as production deps — from the manifest + import graph. Deterministic.

  • Declared in warpgate-web/package.json but never imported anywhere in that package or its workspace members — no static import reaches it. Usually that is dead weight and attack surface, but two shapes are indistinguishable from source and are NOT dead: an optional or native peer that another dependency loads dynamically at runtime, and a package a build, docs or test step installs and invokes separately. Confirm which of the three this is before removing it. (×3)

What to do

  • Remove unused dependencies, declare unlisted imports explicitly, and demote type-/test-only packages to devDependencies.
R9 · Circular Imports10.0 / 10Exemplary✓ Tool-verified

React / JS · Architecture — Import cycles in the module graph (D-386) — files that can only be understood and changed together.

Method: Import cycles in the module graph, detected exhaustively over JS/TS imports (the same cycle detection as the .NET coupling dimension). Deterministic.

X5 · Nullable reference types2.0 / 10Critical✓ Tool-verified

Other · Code Health — Whether nullable reference types are enabled and not undermined by heavy `!` suppression.

Method: Roslyn compiler-options scan: NullableContextOptions per project; null-forgiving (!) suppression density per 1k syntax nodes. Deterministic, adoption plus suppression penalty.

  • 0/1 NRT-eligible project(s) enable <Nullable>enable</Nullable> (projects targeting a pre-C#-8 framework are excluded — NRTs aren't available there). NRTs catch a whole class of null-deref bugs at compile time.

What to do

  • Enable <Nullable>enable</Nullable> across all projects and resolve warnings rather than suppressing with `!`.

Reference — by lens

The score is the rank-weighted fold of these lenses (worst-heaviest), each including its meta-dimensions; a lens with a Critical contributor is capped at Fair (its band reads "gated by …") and is never the strongest area however high its average.

LensScoreRatingImpact
Code Health49%Weak — gated by R7, X5Capped at Fair by a Critical contributor — resolve it before relying on this lens.
Architecture69%Adequate — gated by AX10Capped at Fair by a Critical contributor — resolve it before relying on this lens.
Maturity65%Adequate — gated by M2Capped at Fair by a Critical contributor — resolve it before relying on this lens.
Readiness79%StrongSolid.
Security68%Adequate — gated by D29, D30Capped at Fair by a Critical contributor — resolve it before relying on this lens.
Domain Modelling100%ExemplaryStrongest area.
Event Sourcing100%ExemplarySolid.
Unscored — 2 check(s) recorded observations but carry no score

These checks ran and found something, but they do not carry a score — either by design (an advisory check reports evidence rather than grading it) or because they could not be scored here. They are excluded from the score for that reason, not because there was nothing to see.

  • P12 CI test-gate honesty — 1 observation(s) recorded · Reported, not scored — this card publishes what the CI gate does with the test inventory rather than grading it. The findings above are its output.
  • SC1 Supply-chain hygiene — 1 observation(s) recorded · Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
Not included — 72 check(s) not relevant to this codebase

These checks had nothing to measure here (no tests, no git history, the codebase is small, or the architecture style doesn't apply), so they're omitted above rather than scored low.

  • AC1 Text alternatives — No user-facing web UI (the repo is a library/CLI/worker/headless service) — accessibility is not applicable.
  • AC2 Forms & labels — No user-facing web UI (the repo is a library/CLI/worker/headless service) — accessibility is not applicable.
  • AC3 Page structure — No user-facing web UI (the repo is a library/CLI/worker/headless service) — accessibility is not applicable.
  • AC4 Keyboard semantics — No user-facing web UI (the repo is a library/CLI/worker/headless service) — accessibility is not applicable.
  • AC5 ARIA correctness — No user-facing web UI (the repo is a library/CLI/worker/headless service) — accessibility is not applicable.
  • AC6 Visual & motion safety — No user-facing web UI (the repo is a library/CLI/worker/headless service) — accessibility is not applicable.
  • AC7 A11y enforcement — No user-facing web UI (the repo is a library/CLI/worker/headless service) — accessibility is not applicable.
  • AX1 Captive dependencies — no DI registrations detected
  • AX2 Stateful singletons — no singleton implementations detected
  • AX6 Interface segregation — no public interfaces
  • AX7 Slice cohesion — not applicable — not a vertical-slice architecture
  • AXB2 Runtime readiness — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
  • AXR1 Runtime accessibility — compose up failed (exit 1 — a container did not start, exited, or never became healthy) — container docker-warpgate-1 exited (1); 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 — No personal data detected in the analyzed source — no PII-typed entity/column names (Email, FirstName, DateOfBirth, …), no ASP.NET Identity / user-account model, and no stored user credentials. GDPR data-protection controls are therefore N/A here. If this is intentional, record the no-PII posture in an ADR; if the app does process personal data, name those fields conventionally so this dimension activates.
  • C2 Access Controls — No access-control surface detected in the analyzed source — no web/app surface to authorize (no HTTP API or web-UI project) and no authorization code at all (no [Authorize]/policies, no imperative guard methods). Access control is therefore N/A here — this is a library/CLI, which is authorized by its CALLER, not by itself. If this codebase grows request handlers, the dimension reactivates and a default-deny posture is expected then.
  • C3 Audit Trail — No personal data detected in the analyzed source — no PII-typed entity/column names (Email, FirstName, DateOfBirth, …), no ASP.NET Identity / user-account model, and no stored user credentials. GDPR data-protection controls are therefore N/A here. If this is intentional, record the no-PII posture in an ADR; if the app does process personal data, name those fields conventionally so this dimension activates.
  • C4 Data Retention — No personal data detected in the analyzed source — no PII-typed entity/column names (Email, FirstName, DateOfBirth, …), no ASP.NET Identity / user-account model, and no stored user credentials. GDPR data-protection controls are therefore N/A here. If this is intentional, record the no-PII posture in an ADR; if the app does process personal data, name those fields conventionally so this dimension activates.
  • C5 Data-Subject Rights — No personal data detected in the analyzed source — no PII-typed entity/column names (Email, FirstName, DateOfBirth, …), no ASP.NET Identity / user-account model, and no stored user credentials. GDPR data-protection controls are therefore N/A here. If this is intentional, record the no-PII posture in an ADR; if the app does process personal data, name those fields conventionally so this dimension activates.
  • D11 Test Reliability — Test reliability not scored — polyglot repository, one half has no runner
  • D12 Dependency Hygiene — Dependency hygiene not measured — this repository's dependencies are not NuGet
  • D16 Bus Factor — single-maintainer repository — bus factor is not applicable
  • D18 Solution Shape — D18 scores the shape of a C#/VB .NET solution, but this repository's production source is mostly .rs, .ts, which the C#/VB workspace does not load — the projects that loaded are an immaterial minority, so solution shape was not assessed for this repository. Not scored — this is a gap in the analyzer's reach, not a verdict about this repository.
  • D23 Boundary Type-Coupling — Cross-context type coupling was not assessed: no type reached this dimension's context map.
  • D24 Comment Value — No inline comments to assess — comment value is not applicable here.
  • D25 ADR Conformance — no ADRs to check
  • D27 Navigability — symbol resolution incomplete — navigability not assessed
  • D32 Data Compliance (PII/GDPR) — 1 file(s) were not parsed by semgrep — the PII/GDPR ruleset never ran over them
  • 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.
  • D42 Runtime Threat Enforcement — The repository ships application workloads but no cluster-governance resources (CRDs, admission webhooks, or a committed policy engine). Runtime threat-detection (Falco/Tetragon) and admission control (Kyverno/OPA-Gatekeeper/PodSecurity) are cluster-OPERATOR controls owned by the platform, not shipped by an application repo/chart — nothing for this repo to assess.
  • D7 Architectural Integrity — no checkable ADRs and no dependency cycles — architectural integrity not assessed
  • D8 Code Coverage — Coverage not measured — analyzer environment
  • DM3 Integration-event coupling — not scored — a domain type leaking across a crate boundary cannot be told apart from source alone from a legitimate shared-kernel crate. Reported as guidance rather than measured
  • DM7 Repository granularity — not scored — detecting 'a repository per CHILD entity' needs the aggregate-root structure, which is not resolvable from source alone here. Reported as guidance rather than measured
  • ED2 Event/command shape — not scored — deciding whether a command has more than one competing handler requires resolving the call graph, and a call made through an inferred or generic receiver has no resolvable owner in the source. Reported as guidance rather than measured
  • ED5 Idempotency — no mutating command handlers or message consumers detected — idempotency check not applicable
  • P7 Outbound HTTP resilience — not applicable — this isn't a service/API/worker
  • P8 Schema migrations — SeaORM, sqlx is declared, but the schema-migration mechanism could not be identified. Our limit, not a verdict on this repository.
  • P9 Domain vs controller coverage — no coverage report found on disk — produce a coverage report in a standard format (lcov — `cargo install cargo-llvm-cov`, then `cargo llvm-cov --lcov --output-path lcov.info`) 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
  • PF1 Benchmark discipline — Performance is assessed only for perf-relevant repos — a packaged library, one that ships benchmarks, or one already using allocation-aware APIs. This repo isn't one, so the Performance lens is not applicable and is excluded from the score.
  • PF2 Allocation hygiene — Performance is assessed only for perf-relevant repos — a packaged library, one that ships benchmarks, or one already using allocation-aware APIs. This repo isn't one, so the Performance lens is not applicable and is excluded from the score.
  • PF3 Async & latency hygiene — Performance is assessed only for perf-relevant repos — a packaged library, one that ships benchmarks, or one already using allocation-aware APIs. This repo isn't one, so the Performance lens is not applicable and is excluded from the score.
  • R11 Import Boundaries — No recognizable feature-sliced/layered src layout — boundary rules not applicable.
  • R4 Test Coverage — 1 test file(s) reach none of 158 production file(s) via imports — exercised outside the JS import graph (integration/bundled), not import-reachable
  • S1 Web-Security Posture — No web surface detected in the analyzed source — no HTTP API or web-UI project (no controllers/minimal-API endpoints, no Razor/Blazor views) and no web middleware (HTTPS redirection, HSTS, security headers, cookies). Transport security, security headers, secure cookies, CSRF/input-validation and middleware-order controls are therefore N/A here — this is a library/CLI/worker, not a web app. Crypto hygiene was still checked and found nothing to flag. If this codebase becomes web-facing, the dimension reactivates automatically.
  • 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
  • X10 Duplicated predicate — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
  • X12 Unreachable branch — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
  • X13 Undrained process stream — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
  • X14 Bypassable address classification — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
  • X15 Unvalidated length from an untrusted reader — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
  • X16 Unfloored truncation loop — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
  • X17 Uncapped recursion over a caller-supplied document — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
  • X18 Disposal-pattern correctness — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
  • X19 Unrestored process-global state — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
  • X2 Cancellation propagation — 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 reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
  • X21 Side-effecting pattern guard — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
  • X22 Contradicted release guard — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
  • X23 Unguarded diagnostic materialisation — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
  • X24 Document value interpolated into markup unescaped — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
  • X25 Inert configuration knob — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
  • X26 Unsynchronised callback handoff — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
  • X27 Collection changed while being enumerated — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
  • X28 Index access outside its own emptiness guard — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
  • X29 Per-element action decided by a fixed element — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
  • X3 Exception handling — 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
  • X30 Support guard that admits what it rejects — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
  • X32 Type resolved by simple name across every loaded assembly — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, 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
  • 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 — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
  • X9 Subsumed condition operand — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.

Appendix A — Findings (grouped)

The findings behind the scores, grouped by severity, then by dimension and kind. The high-severity issues are enumerated in full below; items per group are capped at 25 with any overflow stated explicitly per group, never silently truncated. The complete machine-readable list of every finding (all severities) is the companion findings.md in this report's bundle.

Critical — 28 finding(s)
D29 · Static Analysis (SAST) · REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
D30 · Dependency Vulnerabilities · High CVE · ×5
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
D31 · IaC & Container Security · High IaC · ×5
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
D35 · Change Coupling · Boundary-crossing change coupling · ×4
  • Boundary-crossing change coupling: parameters.rs ↔ lib.rs warpgate-admin/src/api/parameters.rs — `warpgate-admin/src/api/parameters.rs` (context warpgate-admin) and `warpgate-db-migrations/src/lib.rs` (context warpgate-db-migrations) sit in DIFFERENT parts of the tree yet change together 86% of the time (18 of the 21 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — a repo-wide or module-wide sweep is evidence about the sweep rather than about any pair inside it and is left out of BOTH sides of this ratio, while a dependency bump, a formatter/rename sweep, or a commit whose edit to one of the two files was a tool directive such as //go:generate or whitespace only is left out of the shared count ONLY, so the two sides are not taken over identical commit sets) — the bounded-context boundary may be in the wrong place, or one context is leaking into the other. This is the behavioural boundary violation a static scan can't see. You can check this without leaving the row: of the 18 shared commits counted here, the most recent 3 are `aec66b7a` fixed #2556 - default auth policy (#2557); `3f36f133` fixed #2536 - do not record keypresses during interactive RDP logon, …; `0b12eff8` Allow admin to configure new tab preference (#2396) — run `git show` on any of them.
  • Boundary-crossing change coupling: lib.rs ↔ lib.rs warpgate-protocol-mysql/src/lib.rs — `warpgate-protocol-mysql/src/lib.rs` (context warpgate-protocol-mysql) and `warpgate-protocol-postgres/src/lib.rs` (context warpgate-protocol-postgres) sit in DIFFERENT parts of the tree yet change together 77% of the time (10 of the 13 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — a repo-wide or module-wide sweep is evidence about the sweep rather than about any pair inside it and is left out of BOTH sides of this ratio, while a dependency bump, a formatter/rename sweep, or a commit whose edit to one of the two files was a tool directive such as //go:generate or whitespace only is left out of the shared count ONLY, so the two sides are not taken over identical commit sets) — the bounded-context boundary may be in the wrong place, or one context is leaking into the other. This is the behavioural boundary violation a static scan can't see. You can check this without leaving the row: of the 10 shared commits counted here, the most recent 3 are `1b848915` Stop Kubernetes listener from becoming unavailable on incomplete TCP …; `bfcf2023` fixed #2379 - do not log LB health checks as failed sessions (#2390); `13478db2` Support TCP Proxy Protocol (#2174) — run `git show` on any of them.
  • Boundary-crossing change coupling: session.rs ↔ session.rs warpgate-protocol-mysql/src/session.rs — `warpgate-protocol-mysql/src/session.rs` (context warpgate-protocol-mysql) and `warpgate-protocol-ssh/src/server/session.rs` (context warpgate-protocol-ssh) sit in DIFFERENT parts of the tree yet change together 61% of the time (11 of the 18 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — a repo-wide or module-wide sweep is evidence about the sweep rather than about any pair inside it and is left out of BOTH sides of this ratio, while a dependency bump, a formatter/rename sweep, or a commit whose edit to one of the two files was a tool directive such as //go:generate or whitespace only is left out of the shared count ONLY, so the two sides are not taken over identical commit sets) — the bounded-context boundary may be in the wrong place, or one context is leaking into the other. This is the behavioural boundary violation a static scan can't see. You can check this without leaving the row: of the 11 shared commits counted here, the most recent 3 are `0daf97d9` fixed #1981 - option to cache web approvals (#2175); `9ca14d10` record invalid usernames as login failures; `a037b92d` perf: find target by name using a query instead of doing it in memory… — run `git show` on any of them.
  • Boundary-crossing change coupling: auth_state_store.rs ↔ session.rs warpgate-core/src/auth_state_store.rs — `warpgate-core/src/auth_state_store.rs` (context warpgate-core) and `warpgate-protocol-ssh/src/server/session.rs` (context warpgate-protocol-ssh) sit in DIFFERENT parts of the tree yet change together 58% of the time (11 of the 19 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — a repo-wide or module-wide sweep is evidence about the sweep rather than about any pair inside it and is left out of BOTH sides of this ratio, while a dependency bump, a formatter/rename sweep, or a commit whose edit to one of the two files was a tool directive such as //go:generate or whitespace only is left out of the shared count ONLY, so the two sides are not taken over identical commit sets) — the bounded-context boundary may be in the wrong place, or one context is leaking into the other. This is the behavioural boundary violation a static scan can't see. You can check this without leaving the row: of the 11 shared commits counted here, the most recent 3 are `0daf97d9` fixed #1981 - option to cache web approvals (#2175); `9ca14d10` record invalid usernames as login failures; `82041787` fixed #2027 - case-insensitive username comparison for web approval (… — run `git show` on any of them.
D29 · Static Analysis (SAST) · REDACTED
  • REDACTED
  • REDACTED
D13 · Secret Scanning · Leaked secret · ×1
  • REDACTED
D29 · Static Analysis (SAST) · REDACTED · ×1
  • REDACTED
D29 · Static Analysis (SAST) · REDACTED · ×1
  • REDACTED
D29 · Static Analysis (SAST) · REDACTED · ×1
  • REDACTED
D30 · Dependency Vulnerabilities · Critical CVE · ×1
  • REDACTED
Serious — 334 finding(s)
D15 · Churn × Complexity Hotspots · Hotspot · ×20
  • Hotspot: warpgate-protocol-ssh/src/server/session.rs warpgate-protocol-ssh/src/server/session.rs:1260 — warpgate-protocol-ssh/src/server/session.rs changed 34 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 47 in ServerSession::handle_remote_event at line 1260. 17 of those changes were fix/bug commits, and the other 17 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-06-26..2026-09-24, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-26 17:13:34 +02:00' --until='2026-09-24 17:13:34 +02:00' --full-history --no-merges -- warpgate-protocol-ssh/src/server/session.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: warpgate-protocol-rdp/src/server/mod.rs warpgate-protocol-rdp/src/server/mod.rs:209 — warpgate-protocol-rdp/src/server/mod.rs changed 14 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 34 in warpgate_protocol_rdp::server::control_loop at line 209. 6 of those changes were fix/bug commits, and the other 8 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-06-26..2026-09-24, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-26 17:13:34 +02:00' --until='2026-09-24 17:13:34 +02:00' --full-history --no-merges -- warpgate-protocol-rdp/src/server/mod.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: warpgate/src/commands/setup.rs warpgate/src/commands/setup.rs:52 — warpgate/src/commands/setup.rs changed 9 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 49 in warpgate::commands::setup::command at line 52. 3 of those changes were fix/bug commits, and the other 6 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-06-26..2026-09-24, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-26 17:13:34 +02:00' --until='2026-09-24 17:13:34 +02:00' --full-history --no-merges -- warpgate/src/commands/setup.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: warpgate/src/commands/run.rs warpgate/src/commands/run.rs:62 — warpgate/src/commands/run.rs changed 15 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 23 in warpgate::commands::run::command at line 62. 2 of those changes were fix/bug commits, and the other 13 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-06-26..2026-09-24, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-26 17:13:34 +02:00' --until='2026-09-24 17:13:34 +02:00' --full-history --no-merges -- warpgate/src/commands/run.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: warpgate-protocol-rdp/src/client/mod.rs warpgate-protocol-rdp/src/client/mod.rs:153 — warpgate-protocol-rdp/src/client/mod.rs changed 15 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 22 in warpgate_protocol_rdp::client::active_loop at line 153. 6 of those changes were fix/bug commits, and the other 9 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-06-26..2026-09-24, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-26 17:13:34 +02:00' --until='2026-09-24 17:13:34 +02:00' --full-history --no-merges -- warpgate-protocol-rdp/src/client/mod.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: warpgate-protocol-http/src/api/info.rs warpgate-protocol-http/src/api/info.rs:164 — warpgate-protocol-http/src/api/info.rs changed 16 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 19 in Api::api_get_info at line 164. 6 of those changes were fix/bug commits, and the other 10 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-06-26..2026-09-24, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-26 17:13:34 +02:00' --until='2026-09-24 17:13:34 +02:00' --full-history --no-merges -- warpgate-protocol-http/src/api/info.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: warpgate-protocol-kubernetes/src/server/handlers.rs warpgate-protocol-kubernetes/src/server/handlers.rs:229 — warpgate-protocol-kubernetes/src/server/handlers.rs changed 10 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 24 in warpgate_protocol_kubernetes::server::handlers::_handle_normal_request_inner at line 229. 1 of those changes was a fix/bug commit, and the other 9 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-06-26..2026-09-24, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-26 17:13:34 +02:00' --until='2026-09-24 17:13:34 +02:00' --full-history --no-merges -- warpgate-protocol-kubernetes/src/server/handlers.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: warpgate-protocol-rdp/src/server/hold_screen.rs warpgate-protocol-rdp/src/server/hold_screen.rs:277 — warpgate-protocol-rdp/src/server/hold_screen.rs changed 11 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 16 in warpgate_protocol_rdp::server::hold_screen::scancode_otp_action at line 277. 3 of those changes were fix/bug commits, and the other 8 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-06-26..2026-09-24, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-26 17:13:34 +02:00' --until='2026-09-24 17:13:34 +02:00' --full-history --no-merges -- warpgate-protocol-rdp/src/server/hold_screen.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: warpgate-web-ssh/src/manager.rs warpgate-web-ssh/src/manager.rs:134 — warpgate-web-ssh/src/manager.rs changed 10 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 15 in warpgate_web_ssh::manager::spawn_event_loop at line 134. 4 of those changes were fix/bug commits, and the other 6 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-06-26..2026-09-24, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-26 17:13:34 +02:00' --until='2026-09-24 17:13:34 +02:00' --full-history --no-merges -- warpgate-web-ssh/src/manager.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: warpgate-common/src/error.rs warpgate-common/src/error.rs:104 — warpgate-common/src/error.rs changed 7 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 21 in WarpgateError::user_facing_reason at line 104. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-06-26..2026-09-24, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-26 17:13:34 +02:00' --until='2026-09-24 17:13:34 +02:00' --full-history --no-merges -- warpgate-common/src/error.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: warpgate-protocol-mysql/src/client.rs warpgate-protocol-mysql/src/client.rs:41 — warpgate-protocol-mysql/src/client.rs changed 7 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 19 in MySqlClient::connect at line 41. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-06-26..2026-09-24, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-26 17:13:34 +02:00' --until='2026-09-24 17:13:34 +02:00' --full-history --no-merges -- warpgate-protocol-mysql/src/client.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: warpgate-web-desktop/src/api.rs warpgate-web-desktop/src/api.rs:19 — warpgate-web-desktop/src/api.rs changed 6 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 21 in warpgate_web_desktop::api::ws_handler at line 19. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-06-26..2026-09-24, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-26 17:13:34 +02:00' --until='2026-09-24 17:13:34 +02:00' --full-history --no-merges -- warpgate-web-desktop/src/api.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: warpgate-web-ssh/src/api.rs warpgate-web-ssh/src/api.rs:20 — warpgate-web-ssh/src/api.rs changed 7 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 18 in warpgate_web_ssh::api::ws_handler at line 20. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-06-26..2026-09-24, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-26 17:13:34 +02:00' --until='2026-09-24 17:13:34 +02:00' --full-history --no-merges -- warpgate-web-ssh/src/api.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: warpgate-core/src/ticket_requests.rs warpgate-core/src/ticket_requests.rs:57 — warpgate-core/src/ticket_requests.rs changed 6 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 17 in warpgate_core::ticket_requests::create_ticket_request at line 57. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-06-26..2026-09-24, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-26 17:13:34 +02:00' --until='2026-09-24 17:13:34 +02:00' --full-history --no-merges -- warpgate-core/src/ticket_requests.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: warpgate-protocol-postgres/src/client.rs warpgate-protocol-postgres/src/client.rs:59 — warpgate-protocol-postgres/src/client.rs changed 5 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 18 in PostgresClient::connect at line 59. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-06-26..2026-09-24, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-26 17:13:34 +02:00' --until='2026-09-24 17:13:34 +02:00' --full-history --no-merges -- warpgate-protocol-postgres/src/client.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: warpgate-protocol-http/src/catchall.rs warpgate-protocol-http/src/catchall.rs:128 — warpgate-protocol-http/src/catchall.rs changed 6 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 15 in warpgate_protocol_http::catchall::get_target_for_request at line 128. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-06-26..2026-09-24, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-26 17:13:34 +02:00' --until='2026-09-24 17:13:34 +02:00' --full-history --no-merges -- warpgate-protocol-http/src/catchall.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: warpgate-common/src/audit.rs warpgate-common/src/audit.rs:216 — warpgate-common/src/audit.rs changed 4 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 22 in AuditEvent::emit at line 216. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-06-26..2026-09-24, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-26 17:13:34 +02:00' --until='2026-09-24 17:13:34 +02:00' --full-history --no-merges -- warpgate-common/src/audit.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: warpgate-protocol-vnc/src/server/bridge.rs warpgate-protocol-vnc/src/server/bridge.rs:108 — warpgate-protocol-vnc/src/server/bridge.rs changed 4 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 20 in warpgate_protocol_vnc::server::bridge::run_proxy_session at line 108. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-06-26..2026-09-24, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-26 17:13:34 +02:00' --until='2026-09-24 17:13:34 +02:00' --full-history --no-merges -- warpgate-protocol-vnc/src/server/bridge.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: warpgate-core/src/db_auth.rs warpgate-core/src/db_auth.rs:189 — warpgate-core/src/db_auth.rs changed 4 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 19 in warpgate_core::db_auth::authorize_user at line 189. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-06-26..2026-09-24, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-26 17:13:34 +02:00' --until='2026-09-24 17:13:34 +02:00' --full-history --no-merges -- warpgate-core/src/db_auth.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: warpgate-core/src/credential_encryption.rs warpgate-core/src/credential_encryption.rs:230 — warpgate-core/src/credential_encryption.rs changed 2 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 16 in warpgate_core::credential_encryption::rewrite_all at line 230. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-06-26..2026-09-24, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-26 17:13:34 +02:00' --until='2026-09-24 17:13:34 +02:00' --full-history --no-merges -- warpgate-core/src/credential_encryption.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
D4 · Code Duplication · Duplicated block (10 lines × 2) · ×13
  • Duplicated block (10 lines × 2) warpgate-common/src/eventhub.rs:56 — warpgate-common/src/eventhub.rs:56-65 | warpgate-common/src/eventhub.rs:72-81 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (10 lines × 2) warpgate-core/src/config_providers/db.rs:823 — warpgate-core/src/config_providers/db.rs:823-832 | warpgate-core/src/config_providers/db.rs:884-893 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (10 lines × 2) warpgate-db-migrations/src/m00037_database_target_auth.rs:105 — warpgate-db-migrations/src/m00037_database_target_auth.rs:105-114 | warpgate-db-migrations/src/m00038_fix_target_auth_tags.rs:106-115 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
  • Duplicated block (10 lines × 2) warpgate-protocol-http/src/api/auth.rs:449 — warpgate-protocol-http/src/api/auth.rs:449-458 | warpgate-protocol-http/src/api/auth.rs:601-610 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (10 lines × 2) warpgate-protocol-ssh/src/server/session.rs:1442 — warpgate-protocol-ssh/src/server/session.rs:1442-1451 | warpgate-protocol-ssh/src/server/session.rs:1473-1482 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (10 lines × 2) warpgate-db-migrations/src/m00058_analytics.rs:10 — warpgate-db-migrations/src/m00058_analytics.rs:10-19 | warpgate-db-migrations/src/m00063_recordings_storage.rs:13-22 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
  • Duplicated block (10 lines × 2) warpgate-db-migrations/src/m00058_analytics.rs:21 — warpgate-db-migrations/src/m00058_analytics.rs:21-30 | warpgate-db-migrations/src/m00063_recordings_storage.rs:24-33 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
  • Duplicated block (10 lines × 2) warpgate-db-migrations/src/m00080_user_and_target_sessions.rs:166 — warpgate-db-migrations/src/m00080_user_and_target_sessions.rs:166-178 | warpgate-db-migrations/src/m00082_target_session_columns.rs:112-121 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
  • Duplicated block (10 lines × 2) warpgate-protocol-http/src/api/credentials.rs:408 — warpgate-protocol-http/src/api/credentials.rs:408-417 | warpgate-protocol-http/src/api/credentials.rs:642-651 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (10 lines × 2) warpgate-protocol-http/src/api/credentials.rs:462 — warpgate-protocol-http/src/api/credentials.rs:462-471 | warpgate-protocol-http/src/api/credentials.rs:593-602 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (10 lines × 2) warpgate-aws/src/region.rs:14 — warpgate-aws/src/region.rs:14-23 | warpgate-aws/src/region.rs:34-43 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (10 lines × 2) warpgate-admin/src/api/certificate_credentials.rs:146 — warpgate-admin/src/api/certificate_credentials.rs:146-155 | warpgate-admin/src/api/public_key_credentials.rs:164-173 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
  • Duplicated block (10 lines × 2) warpgate-protocol-ssh/src/server/session.rs:2036 — warpgate-protocol-ssh/src/server/session.rs:2036-2045 | warpgate-protocol-ssh/src/server/session.rs:2085-2094 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
D3 · God Classes · MethodTooLong · ×11
  • MethodTooLong: AuditEvent.emit warpgate-common/src/audit.rs:216 — MethodTooLong — emit runs 397 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 297 over it, 3.97× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: Api.api_get_info warpgate-protocol-http/src/api/info.rs:164 — MethodTooLong — api_get_info runs 190 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 90 over it, 1.90× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: HTTPProtocolServer.bind warpgate-protocol-http/src/lib.rs:106 — MethodTooLong — bind runs 179 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 79 over it, 1.79× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: ServerSession.handle_remote_event warpgate-protocol-ssh/src/server/session.rs:1260 — MethodTooLong — handle_remote_event runs 170 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 70 over it, 1.70× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: Migration.up warpgate-db-migrations/src/m00044_ticket_requests.rs:87 — MethodTooLong — up runs 143 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 43 over it, 1.43× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: MySqlClient.connect warpgate-protocol-mysql/src/client.rs:41 — MethodTooLong — connect runs 125 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 25 over it, 1.25× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: ServerSession.handle_server_handler_event warpgate-protocol-ssh/src/server/session.rs:1050 — MethodTooLong — handle_server_handler_event runs 124 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 24 over it, 1.24× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: Connector.authenticate_session warpgate-protocol-ssh/src/client/mod.rs:872 — MethodTooLong — authenticate_session runs 117 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 17 over it, 1.17× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: Api.api_return_to_sso_get_common warpgate-protocol-http/src/api/sso_provider_list.rs:241 — MethodTooLong — api_return_to_sso_get_common runs 115 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 15 over it, 1.15× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: Migration.up warpgate-db-migrations/src/m00035_ticket_user_target_id.rs:86 — MethodTooLong — up runs 109 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 9 over it, 1.09× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: PostgresClient.connect warpgate-protocol-postgres/src/client.rs:59 — MethodTooLong — connect runs 108 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 8 over it, 1.08× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
D3 · God Classes · FunctionTooLong · ×11
  • FunctionTooLong: warpgate::commands::setup::command warpgate/src/commands/setup.rs:52 — FunctionTooLong — warpgate::commands::setup::command runs 318 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 218 over it, 3.18× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: warpgate_protocol_rdp::server::control_loop warpgate-protocol-rdp/src/server/mod.rs:209 — FunctionTooLong — warpgate_protocol_rdp::server::control_loop runs 174 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 74 over it, 1.74× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: warpgate::commands::run::command warpgate/src/commands/run.rs:62 — FunctionTooLong — warpgate::commands::run::command runs 164 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 64 over it, 1.64× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: warpgate_protocol_kubernetes::server::handlers::_handle_normal_request_inner warpgate-protocol-kubernetes/src/server/handlers.rs:229 — FunctionTooLong — warpgate_protocol_kubernetes::server::handlers::_handle_normal_request_inner runs 135 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 35 over it, 1.35× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: warpgate_core::db_auth::authorize_user warpgate-core/src/db_auth.rs:189 — FunctionTooLong — warpgate_core::db_auth::authorize_user runs 125 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 25 over it, 1.25× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: warpgate_protocol_vnc::server::negotiate_and_authorize warpgate-protocol-vnc/src/server/mod.rs:163 — FunctionTooLong — warpgate_protocol_vnc::server::negotiate_and_authorize runs 119 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 19 over it, 1.19× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: warpgate_core::ticket_requests::create_ticket_request warpgate-core/src/ticket_requests.rs:57 — FunctionTooLong — warpgate_core::ticket_requests::create_ticket_request runs 116 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 16 over it, 1.16× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: warpgate_protocol_kubernetes::server::handlers::_handle_websocket_request_inner warpgate-protocol-kubernetes/src/server/handlers.rs:488 — FunctionTooLong — warpgate_protocol_kubernetes::server::handlers::_handle_websocket_request_inner runs 104 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 4 over it, 1.04× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: warpgate_protocol_vnc::server::protocol::read_client_messages warpgate-protocol-vnc/src/server/protocol.rs:266 — FunctionTooLong — warpgate_protocol_vnc::server::protocol::read_client_messages runs 104 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 4 over it, 1.04× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: warpgate_desktop_auth::authenticate warpgate-desktop-auth/src/lib.rs:72 — FunctionTooLong — warpgate_desktop_auth::authenticate runs 102 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 2 over it, 1.02× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: warpgate_protocol_http::proxy::proxy_ws_inner warpgate-protocol-http/src/proxy.rs:516 — FunctionTooLong — warpgate_protocol_http::proxy::proxy_ws_inner runs 101 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 1 over it, 1.01× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
D5 · Coupling · Off the main sequence · ×11
  • Off the main sequence: warpgate-aws — warpgate-aws: abstractness 0.00, instability 0.00, distance 1.00 — zone of pain — concrete and depended on by 8 project(s), so it's rigid to change.
  • Off the main sequence: warpgate-ca — warpgate-ca: abstractness 0.00, instability 0.00, distance 1.00 — zone of pain — concrete and depended on by 7 project(s), so it's rigid to change.
  • Off the main sequence: warpgate-sso — warpgate-sso: abstractness 0.00, instability 0.00, distance 1.00 — zone of pain — concrete and depended on by 4 project(s), so it's rigid to change.
  • Off the main sequence: warpgate-admin — warpgate-admin: abstractness 0.08, instability 0.00, distance 0.92 — an application entry point, so it is concrete by design — the distance is expected; what is worth checking is that other projects depend on it at all, since a host should be a leaf of the graph.
  • Off the main sequence: warpgate-db-entities — warpgate-db-entities: abstractness 0.00, instability 0.24, distance 0.76 — zone of pain — concrete and depended on by 13 project(s), so it's rigid to change.
  • Off the main sequence: warpgate-common-http — warpgate-common-http: abstractness 0.00, instability 0.25, distance 0.75 — the shape a shared-kernel / building-block library has BY DESIGN — concrete and widely depended-on is what makes it useful, and this dimension does not penalise it (the distance is reported for completeness, not as a defect). Worth a look only if it has grown past one coherent kernel into an everything-bucket.
  • Off the main sequence: warpgate-database-protocols — warpgate-database-protocols: abstractness 0.25, instability 0.00, distance 0.75 — zone of pain — concrete and depended on by 1 project(s), so it's rigid to change.
  • Off the main sequence: warpgate-desktop-ui — warpgate-desktop-ui: abstractness 0.00, instability 0.25, distance 0.75 — zone of pain — concrete and depended on by 3 project(s), so it's rigid to change.
  • Off the main sequence: warpgate-ldap — warpgate-ldap: abstractness 0.00, instability 0.25, distance 0.75 — zone of pain — concrete and depended on by 3 project(s), so it's rigid to change.
  • Off the main sequence: warpgate-tls — warpgate-tls: abstractness 0.18, instability 0.08, distance 0.74 — zone of pain — concrete and depended on by 12 project(s), so it's rigid to change.
  • Off the main sequence: warpgate-common — warpgate-common: abstractness 0.07, instability 0.22, distance 0.71 — the shape a shared-kernel / building-block library has BY DESIGN — concrete and widely depended-on is what makes it useful, and this dimension does not penalise it (the distance is reported for completeness, not as a defect). Worth a look only if it has grown past one coherent kernel into an everything-bucket.
D3 · God Classes · FileTooLong · ×9
  • FileTooLong: server/session.rs warpgate-protocol-ssh/src/server/session.rs — FileTooLong — 1796 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), about 93% of them inside a single declaration: ServerSession (4 blocks, 129-2720). The bar is 500 significant lines; this is 1296 over it, 3.59× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • FileTooLong: client/mod.rs warpgate-protocol-ssh/src/client/mod.rs — FileTooLong — 888 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted). The bar is 500 significant lines; this is 388 over it, 1.78× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: config_providers/db.rs warpgate-core/src/config_providers/db.rs — FileTooLong — 717 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), about 88% of them inside a single declaration: DatabaseConfigProvider (3 blocks, 28-1016). The bar is 500 significant lines; this is 217 over it, 1.43× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • FileTooLong: api/users.rs warpgate-admin/src/api/users.rs — FileTooLong — 619 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted). The bar is 500 significant lines; this is 119 over it, 1.24× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: config/mod.rs warpgate-common/src/config/mod.rs — FileTooLong — 599 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted). The bar is 500 significant lines; this is 99 over it, 1.20× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: api/auth.rs warpgate-protocol-http/src/api/auth.rs — FileTooLong — 570 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted). The bar is 500 significant lines; this is 70 over it, 1.14× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: src/audit.rs warpgate-common/src/audit.rs — FileTooLong — 551 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), about 96% of them inside a single declaration: AuditEvent (2 blocks, 35-662). The bar is 500 significant lines; this is 51 over it, 1.10× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • FileTooLong: api/credentials.rs warpgate-protocol-http/src/api/credentials.rs — FileTooLong — 528 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), about 66% of them inside a single declaration: Api (248-719). The bar is 500 significant lines; this is 28 over it, 1.06× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • FileTooLong: client/mod.rs warpgate-protocol-rdp/src/client/mod.rs — FileTooLong — 510 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted). The bar is 500 significant lines; this is 10 over it, 1.02× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
D31 · IaC & Container Security · Medium IaC · ×8
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
D4 · Code Duplication · Duplicated block (13 lines × 2) · ×8
  • Duplicated block (13 lines × 2) warpgate-admin/src/api/otp_credentials.rs:149 — warpgate-admin/src/api/otp_credentials.rs:149-161 | warpgate-admin/src/api/password_credentials.rs:159-171 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
  • Duplicated block (13 lines × 2) warpgate-protocol-mysql/src/client.rs:98 — warpgate-protocol-mysql/src/client.rs:98-110 | warpgate-protocol-postgres/src/client.rs:130-142 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice.
  • Duplicated block (13 lines × 2) warpgate-protocol-ssh/src/server/session.rs:805 — warpgate-protocol-ssh/src/server/session.rs:805-817 | warpgate-protocol-ssh/src/server/session.rs:2539-2552 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (13 lines × 2) warpgate-protocol-ssh/src/server/session.rs:2121 — warpgate-protocol-ssh/src/server/session.rs:2121-2133 | warpgate-protocol-ssh/src/server/session.rs:2159-2171 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (13 lines × 2) warpgate-db-migrations/src/m00078_assignment_composite_pks.rs:116 — warpgate-db-migrations/src/m00078_assignment_composite_pks.rs:116-130 | warpgate-db-migrations/src/m00078_assignment_composite_pks.rs:203-215 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (13 lines × 2) warpgate-web-desktop/src/manager.rs:76 — warpgate-web-desktop/src/manager.rs:76-88 | warpgate-web-ssh/src/manager.rs:68-80 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice.
  • Duplicated block (13 lines × 2) warpgate-db-migrations/src/m00027_ca.rs:40 — warpgate-db-migrations/src/m00027_ca.rs:40-52 | warpgate-db-migrations/src/m00027_ca.rs:53-65 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (13 lines × 2) warpgate-db-migrations/src/m00057_password_login_mode.rs:35 — warpgate-db-migrations/src/m00057_password_login_mode.rs:35-47 | warpgate-db-migrations/src/m00057_password_login_mode.rs:71-83 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
D4 · Code Duplication · Duplicated block (8 lines × 2) · ×7
  • Duplicated block (8 lines × 2) warpgate-admin/src/api/ldap_servers.rs:347 — warpgate-admin/src/api/ldap_servers.rs:347-354 | warpgate-admin/src/api/ldap_servers.rs:413-420 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (8 lines × 2) warpgate-admin/src/api/users.rs:669 — warpgate-admin/src/api/users.rs:669-676 | warpgate-admin/src/api/users.rs:723-730 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (8 lines × 2) warpgate-admin/src/api/users.rs:705 — warpgate-admin/src/api/users.rs:705-712 | warpgate-admin/src/api/users.rs:753-760 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (8 lines × 2) warpgate-admin/src/api/users.rs:846 — warpgate-admin/src/api/users.rs:846-853 | warpgate-admin/src/api/users.rs:896-903 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (8 lines × 2) warpgate-protocol-http/src/api/web_desktop.rs:207 — warpgate-protocol-http/src/api/web_desktop.rs:207-214 | warpgate-protocol-http/src/api/web_ssh.rs:188-195 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
  • Duplicated block (8 lines × 2) warpgate-protocol-mysql/src/stream.rs:95 — warpgate-protocol-mysql/src/stream.rs:95-103 | warpgate-protocol-postgres/src/stream.rs:158-165 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice.
  • Duplicated block (8 lines × 2) warpgate-db-migrations/src/m00010_parameters.rs:32 — warpgate-db-migrations/src/m00010_parameters.rs:32-39 | warpgate-db-migrations/src/m00020_ldap_server.rs:45-52 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
D4 · Code Duplication · Duplicated block (7 lines × 2) · ×7
  • Duplicated block (7 lines × 2) warpgate-core/src/ticket_requests.rs:173 — warpgate-core/src/ticket_requests.rs:173-179 | warpgate-core/src/ticket_requests.rs:202-208 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (7 lines × 2) warpgate-db-migrations/src/m00075_hash_ticket_and_api_token_secrets.rs:36 — warpgate-db-migrations/src/m00075_hash_ticket_and_api_token_secrets.rs:36-42 | warpgate-db-migrations/src/m00081_http_session_user_session_id.rs:104-110 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
  • Duplicated block (7 lines × 2) warpgate-protocol-vnc/src/server/protocol.rs:375 — warpgate-protocol-vnc/src/server/protocol.rs:375-381 | warpgate-protocol-vnc/src/server/protocol.rs:390-397 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (7 lines × 2) warpgate-common/src/helpers/serde_base64.rs:13 — warpgate-common/src/helpers/serde_base64.rs:13-19 | warpgate-db-migrations/src/m00009_credential_models.rs:174-180 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice.
  • Duplicated block (7 lines × 2) warpgate-protocol-http/src/api/web_desktop.rs:197 — warpgate-protocol-http/src/api/web_desktop.rs:197-203 | warpgate-protocol-http/src/api/web_ssh.rs:178-184 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
  • Duplicated block (7 lines × 2) warpgate-admin/src/api/admin_scheme.rs:162 — warpgate-admin/src/api/admin_scheme.rs:162-168 | warpgate-protocol-http/src/api/auth_scheme.rs:55-61 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice.
  • Duplicated block (7 lines × 2) warpgate-protocol-ssh/src/server/session.rs:1086 — warpgate-protocol-ssh/src/server/session.rs:1086-1092 | warpgate-protocol-ssh/src/server/session.rs:1694-1700 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
D15 · Churn × Complexity Hotspots · Repeated repair · ×6
  • Repeated repair: warpgate-web/src/admin/config/Parameters.svelte warpgate-web/src/admin/config/Parameters.svelte:114 — warpgate-web/src/admin/config/Parameters.svelte changed 24 times in last 90 days and 13 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 11 (its worst body is save at line 114), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fixed #2556 - default auth policy (#2557)”; “fixed #2536 - do not record keypresses during interactive RDP logon, add disable keyboard recording option (#2537)”; “fixed #2422 - validate numeric parameter fields in the API”; “fixed #2487 - RDP - handle unstable bitmap parse order in Chromium (#2491)”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-06-26..2026-09-24, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-26 17:13:34 +02:00' --until='2026-09-24 17:13:34 +02:00' --full-history --no-merges -- warpgate-web/src/admin/config/Parameters.svelte`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: warpgate-admin/src/api/parameters.rs warpgate-admin/src/api/parameters.rs:302 — warpgate-admin/src/api/parameters.rs changed 22 times in last 90 days and 12 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 4 (its worst body is Api::api_update_parameters at line 302), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fixed #2556 - default auth policy (#2557)”; “fixed #2536 - do not record keypresses during interactive RDP logon, add disable keyboard recording option (#2537)”; “fixed #2422 - validate numeric parameter fields in the API”; “fixed #2449 - cannot unset nullable parameters via API”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-06-26..2026-09-24, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-26 17:13:34 +02:00' --until='2026-09-24 17:13:34 +02:00' --full-history --no-merges -- warpgate-admin/src/api/parameters.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: warpgate-core/src/protocols/desktop.rs warpgate-core/src/protocols/desktop.rs:18 — warpgate-core/src/protocols/desktop.rs changed 5 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 4 (its worst body is warpgate_core::protocols::desktop::truncate_clipboard_contents at line 18), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fixed #2536 - do not record keypresses during interactive RDP logon, add disable keyboard recording option (#2537)”; “fixed #2411 - support RDP clipboard redirection (#2447)”; “fixed #2349 - keyboard layouts in RDP (#2364)”; “fixed #2326 - dynamic resolution in RDP web client (#2329)”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-06-26..2026-09-24, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-26 17:13:34 +02:00' --until='2026-09-24 17:13:34 +02:00' --full-history --no-merges -- warpgate-core/src/protocols/desktop.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: warpgate/src/commands/create_user.rs warpgate/src/commands/create_user.rs:13 — warpgate/src/commands/create_user.rs changed 5 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 6 (its worst body is warpgate::commands::create_user::command at line 13), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fixed #2556 - default auth policy (#2557)”; “fixed #2453 - setup CLI recreates admin user every time”; “fixed #2191 - allow concurrent DB access (#2192)”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-06-26..2026-09-24, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-26 17:13:34 +02:00' --until='2026-09-24 17:13:34 +02:00' --full-history --no-merges -- warpgate/src/commands/create_user.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: warpgate-web/src/embed/index.ts warpgate-web/src/embed/index.ts:9 — warpgate-web/src/embed/index.ts changed 5 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 4 (its worst body is index.forceSecureWebSocketURLs at line 9), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fixed #1627 - support multiple SSH keys (#2277)”; “fixed #2254 - novnc websockets not working”; “fixed embedded menu”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-06-26..2026-09-24, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-26 17:13:34 +02:00' --until='2026-09-24 17:13:34 +02:00' --full-history --no-merges -- warpgate-web/src/embed/index.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: warpgate-protocol-ssh/src/server/russh_handler.rs warpgate-protocol-ssh/src/server/russh_handler.rs:71 — warpgate-protocol-ssh/src/server/russh_handler.rs changed 5 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 2 (its worst body is ServerHandlerEvent::existing_channel at line 71), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fixed #2328 - channel confirmation race (#2331)”; “fixed #1459 - concurrent agent channel requests causing deadlock (#2135)”; “fixed #2026 - custom SSH banner (#2125)”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-06-26..2026-09-24, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-26 17:13:34 +02:00' --until='2026-09-24 17:13:34 +02:00' --full-history --no-merges -- warpgate-protocol-ssh/src/server/russh_handler.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
D2 · Cognitive Complexity · ServerSession · ×5
  • ServerSession::handle_remote_event (cognitive 61) warpgate-protocol-ssh/src/server/session.rs:1260 — ServerSession::handle_remote_event has cognitive complexity 61 (threshold 15). Drivers by points: if/else 20 (51 pts), match/switch 4 (7 pts), boolean chains 3 (nesting depth added 34). The drivers above price the dispatch low by construction — a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full — so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
  • ServerSession::start (cognitive 35) warpgate-protocol-ssh/src/server/session.rs:253 — ServerSession::start has cognitive complexity 35 (threshold 15). Drivers by points: if/else 11 (24 pts), match/switch 3 (6 pts), loops 5 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ServerSession::handle_event (cognitive 31) warpgate-protocol-ssh/src/server/session.rs:830 — ServerSession::handle_event has cognitive complexity 31 (threshold 15). Drivers by points: if/else 12 (23 pts), match/switch 3 (6 pts), boolean chains 2 (nesting depth added 14). The drivers above price the dispatch low by construction — a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full — so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
  • ServerSession::try_auth_eager (cognitive 27) warpgate-protocol-ssh/src/server/session.rs:2375 — ServerSession::try_auth_eager has cognitive complexity 27 (threshold 15). Drivers by points: if/else 10 (22 pts), match/switch 3 (5 pts) (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ServerSession::_auth_keyboard_interactive (cognitive 21) warpgate-protocol-ssh/src/server/session.rs:2173 — ServerSession::_auth_keyboard_interactive has cognitive complexity 21 (threshold 15). Drivers by points: if/else 11 (20 pts), match/switch 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D30 · Dependency Vulnerabilities · Medium advisory (unmaintained) · ×5
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
D4 · Code Duplication · Duplicated block (14 lines × 2) · ×5
  • Duplicated block (14 lines × 2) warpgate-protocol-rdp/src/server/mod.rs:140 — warpgate-protocol-rdp/src/server/mod.rs:140-154 | warpgate-protocol-vnc/src/server/mod.rs:100-113 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice.
  • Duplicated block (14 lines × 2) warpgate-db-migrations/src/m00025_ssh_client_auth.rs:66 — warpgate-db-migrations/src/m00025_ssh_client_auth.rs:66-79 | warpgate-db-migrations/src/m00086_jit_session_approval.rs:162-177 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
  • Duplicated block (14 lines × 2) warpgate-db-migrations/src/m00041_fix_user_role_assignment_dates.rs:21 — warpgate-db-migrations/src/m00041_fix_user_role_assignment_dates.rs:21-34 | warpgate-db-migrations/src/m00041_fix_user_role_assignment_dates.rs:35-48 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (14 lines × 2) warpgate-common/src/audit.rs:394 — warpgate-common/src/audit.rs:394-407 | warpgate-common/src/audit.rs:413-426 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (14 lines × 2) warpgate-db-migrations/src/m00017_descriptions.rs:96 — warpgate-db-migrations/src/m00017_descriptions.rs:96-109 | warpgate-db-migrations/src/m00019_rate_limits.rs:64-77 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
D4 · Code Duplication · Duplicated block (9 lines × 2) · ×5
  • Duplicated block (9 lines × 2) warpgate-common/src/audit.rs:517 — warpgate-common/src/audit.rs:517-525 | warpgate-common/src/audit.rs:542-550 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (9 lines × 2) warpgate-common/src/audit.rs:586 — warpgate-common/src/audit.rs:586-594 | warpgate-common/src/audit.rs:613-621 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (9 lines × 2) warpgate-protocol-http/src/api/credentials.rs:439 — warpgate-protocol-http/src/api/credentials.rs:439-447 | warpgate-protocol-http/src/api/credentials.rs:554-562 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (9 lines × 2) warpgate-db-migrations/src/m00041_fix_user_role_assignment_dates.rs:70 — warpgate-db-migrations/src/m00041_fix_user_role_assignment_dates.rs:70-78 | warpgate-db-migrations/src/m00041_fix_user_role_assignment_dates.rs:79-87 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (9 lines × 2) warpgate-db-migrations/src/m00036_user_role_expiry_history.rs:13 — warpgate-db-migrations/src/m00036_user_role_expiry_history.rs:13-21 | warpgate-db-migrations/src/m00036_user_role_expiry_history.rs:22-30 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
D2 · Cognitive Complexity · warpgate_core · ×4
  • warpgate_core::db_auth::authorize_user (cognitive 40) warpgate-core/src/db_auth.rs:189 — warpgate_core::db_auth::authorize_user has cognitive complexity 40 (threshold 15). Drivers by points: if/else 12 (34 pts), match/switch 2 (5 pts), loops 1 (nesting depth added 25). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • warpgate_core::credential_encryption::rewrite_all (cognitive 25) warpgate-core/src/credential_encryption.rs:230 — warpgate_core::credential_encryption::rewrite_all has cognitive complexity 25 (threshold 15). Drivers by points: if/else 11 (21 pts), loops 4 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • warpgate_core::config_providers::sso_user::resolve_and_map_sso_user (cognitive 22) warpgate-core/src/config_providers/sso_user.rs:11 — warpgate_core::config_providers::sso_user::resolve_and_map_sso_user has cognitive complexity 22 (threshold 15). Drivers by points: if/else 12 (19 pts), loops 1 (3 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • warpgate_core::ticket_requests::create_ticket_request (cognitive 18) warpgate-core/src/ticket_requests.rs:57 — warpgate_core::ticket_requests::create_ticket_request has cognitive complexity 18 (threshold 15). Drivers by points: if/else 12 (13 pts), boolean chains 4, match/switch 1 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · warpgate_protocol_kubernetes · ×4
  • warpgate_protocol_kubernetes::server::handlers::_handle_normal_request_inner (cognitive 34) warpgate-protocol-kubernetes/src/server/handlers.rs:229 — warpgate_protocol_kubernetes::server::handlers::_handle_normal_request_inner has cognitive complexity 34 (threshold 15). Drivers by points: if/else 14 (21 pts), boolean chains 6, loops 4 (5 pts), match/switch 1 (2 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • warpgate_protocol_kubernetes::correlator::correlated_authorization (cognitive 22) warpgate-protocol-kubernetes/src/correlator.rs:92 — warpgate_protocol_kubernetes::correlator::correlated_authorization has cognitive complexity 22 (threshold 15). Drivers by points: if/else 6 (13 pts), match/switch 3 (7 pts), boolean chains 1, loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • warpgate_protocol_kubernetes::server::auth::authenticate (cognitive 22) warpgate-protocol-kubernetes/src/server/auth.rs:295 — warpgate_protocol_kubernetes::server::auth::authenticate has cognitive complexity 22 (threshold 15). Drivers by points: if/else 6 (11 pts), match/switch 3 (8 pts), loops 1 (2 pts), boolean chains 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • warpgate_protocol_kubernetes::server::handlers::_handle_websocket_request_inner (cognitive 16) warpgate-protocol-kubernetes/src/server/handlers.rs:488 — warpgate_protocol_kubernetes::server::handlers::_handle_websocket_request_inner has cognitive complexity 16 (threshold 15). Drivers by points: if/else 10 (11 pts), match/switch 3 (4 pts), boolean chains 1 (nesting depth added 2). To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D3 · God Classes · ClassTooLong · ×4
  • ClassTooLong: ServerSession warpgate-protocol-ssh/src/server/session.rs:129 — ClassTooLong — 1670 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), 68 methods, 4 blocks, lines 129-2720. The bar is 400 significant lines; this is 1270 over it, 4.18× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: DatabaseConfigProvider warpgate-core/src/config_providers/db.rs:28 — ClassTooLong — 630 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), 3 methods, 3 blocks, lines 28-1016. The bar is 400 significant lines; this is 230 over it, 1.58× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: AuditEvent warpgate-common/src/audit.rs:35 — ClassTooLong — 530 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), 1 methods, 2 blocks, lines 35-662. The bar is 400 significant lines; this is 130 over it, 1.33× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: ServerHandler warpgate-protocol-ssh/src/server/russh_handler.rs:103 — ClassTooLong — 406 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), 1 methods, 5 blocks, lines 103-619. The bar is 400 significant lines; this is 6 over it, 1.02× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
D30 · Dependency Vulnerabilities · Medium CVE · ×4
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
D1 · Cyclomatic Complexity · ServerSession · ×3
  • ServerSession::handle_remote_event (cyclomatic 47) warpgate-protocol-ssh/src/server/session.rs:1260 — ServerSession::handle_remote_event has cyclomatic complexity 47 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ServerSession::handle_event (cyclomatic 25) warpgate-protocol-ssh/src/server/session.rs:830 — ServerSession::handle_event has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file's highest cyclomatic complexity: ServerSession::handle_server_handler_event (cyclomatic 30) is higher and carries no row of its own — it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension's figures nor in its score.
  • ServerSession::start (cyclomatic 21) warpgate-protocol-ssh/src/server/session.rs:253 — ServerSession::start has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file's highest cyclomatic complexity: ServerSession::handle_server_handler_event (cyclomatic 30) is higher and carries no row of its own — it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension's figures nor in its score.
D1 · Cyclomatic Complexity · warpgate_core · ×3
  • warpgate_core::db_auth::authorize_user (cyclomatic 19) warpgate-core/src/db_auth.rs:189 — warpgate_core::db_auth::authorize_user has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • warpgate_core::ticket_requests::create_ticket_request (cyclomatic 17) warpgate-core/src/ticket_requests.rs:57 — warpgate_core::ticket_requests::create_ticket_request has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
  • warpgate_core::credential_encryption::rewrite_all (cyclomatic 16) warpgate-core/src/credential_encryption.rs:230 — warpgate_core::credential_encryption::rewrite_all has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D2 · Cognitive Complexity · warpgate · ×3
  • warpgate::commands::setup::command (cognitive 97) warpgate/src/commands/setup.rs:52 — warpgate::commands::setup::command has cognitive complexity 97 (threshold 15). Drivers by points: if/else 61 (92 pts), match/switch 3, boolean chains 1, loops 1 (nesting depth added 31). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • warpgate::commands::run::command (cognitive 28) warpgate/src/commands/run.rs:62 — warpgate::commands::run::command has cognitive complexity 28 (threshold 15). Drivers by points: match/switch 6 (12 pts), if/else 7 (9 pts), loops 5 (7 pts) (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • warpgate::config::check_and_migrate_config (cognitive 24) warpgate/src/config.rs:74 — warpgate::config::check_and_migrate_config has cognitive complexity 24 (threshold 15). Drivers by points: if/else 7 (16 pts), match/switch 1 (4 pts), loops 1 (3 pts), boolean chains 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · warpgate_protocol_rdp · ×3
  • warpgate_protocol_rdp::server::control_loop (cognitive 78) warpgate-protocol-rdp/src/server/mod.rs:209 — warpgate_protocol_rdp::server::control_loop has cognitive complexity 78 (threshold 15). Drivers by points: if/else 19 (56 pts), match/switch 5 (18 pts), boolean chains 3, loops 1 (nesting depth added 50). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • warpgate_protocol_rdp::client::active_loop (cognitive 45) warpgate-protocol-rdp/src/client/mod.rs:153 — warpgate_protocol_rdp::client::active_loop has cognitive complexity 45 (threshold 15). Drivers by points: if/else 9 (26 pts), loops 4 (9 pts), match/switch 3 (8 pts), boolean chains 2 (nesting depth added 27). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • warpgate_protocol_rdp::client::input::translate (cognitive 18) warpgate-protocol-rdp/src/client/input.rs:11 — warpgate_protocol_rdp::client::input::translate has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (15 pts), loops 1 (2 pts), match/switch 1 (nesting depth added 8). The drivers above price the dispatch low by construction — a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full — so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
D2 · Cognitive Complexity · warpgate_protocol_vnc · ×3
  • warpgate_protocol_vnc::server::bridge::run_proxy_session (cognitive 32) warpgate-protocol-vnc/src/server/bridge.rs:108 — warpgate_protocol_vnc::server::bridge::run_proxy_session has cognitive complexity 32 (threshold 15). Drivers by points: if/else 5 (18 pts), match/switch 4 (12 pts), boolean chains 1, loops 1 (nesting depth added 21). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • warpgate_protocol_vnc::client::run (cognitive 25) warpgate-protocol-vnc/src/client.rs:161 — warpgate_protocol_vnc::client::run has cognitive complexity 25 (threshold 15). Drivers by points: if/else 2 (9 pts), match/switch 4 (9 pts), loops 3 (6 pts), boolean chains 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • warpgate_protocol_vnc::server::protocol::read_client_messages (cognitive 24) warpgate-protocol-vnc/src/server/protocol.rs:266 — warpgate_protocol_vnc::server::protocol::read_client_messages has cognitive complexity 24 (threshold 15). Drivers by points: match/switch 4 (11 pts), if/else 3 (9 pts), loops 2 (4 pts) (nesting depth added 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
D3 · God Classes · TooManyFields · ×3
  • TooManyFields: Model warpgate-db-entities/src/Parameters.rs:185 — TooManyFields — 61 stored fields beside 7 methods. The bar is 30 stored fields; this is 31 over it, 2.03× the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member — each reader then names only the group it uses.
  • TooManyFields: ParameterValues warpgate-admin/src/api/parameters.rs:61 — TooManyFields — 46 stored fields. The bar is 30 stored fields; this is 16 over it, 1.53× the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member — each reader then names only the group it uses.
  • TooManyFields: ParameterUpdate warpgate-admin/src/api/parameters.rs:112 — TooManyFields — 46 stored fields. The bar is 30 stored fields; this is 16 over it, 1.53× the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member — each reader then names only the group it uses.
D4 · Code Duplication · Duplicated block (11 lines × 2) · ×3
  • Duplicated block (11 lines × 2) warpgate-core/src/config_providers/db.rs:407 — warpgate-core/src/config_providers/db.rs:407-417 | warpgate-core/src/config_providers/db.rs:581-591 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (11 lines × 2) warpgate-protocol-http/src/api/ticket_requests.rs:252 — warpgate-protocol-http/src/api/ticket_requests.rs:252-262 | warpgate-protocol-http/src/api/ticket_requests.rs:383-393 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (11 lines × 2) warpgate-admin/src/api/certificate_credentials.rs:253 — warpgate-admin/src/api/certificate_credentials.rs:253-263 | warpgate-admin/src/api/public_key_credentials.rs:282-292 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
D4 · Code Duplication · Duplicated block (6 lines × 2) · ×3
  • Duplicated block (6 lines × 2) warpgate-protocol-http/src/api/web_desktop.rs:146 — warpgate-protocol-http/src/api/web_desktop.rs:146-151 | warpgate-protocol-http/src/api/web_desktop.rs:178-183 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (6 lines × 2) warpgate-core/src/recordings/desktop.rs:238 — warpgate-core/src/recordings/desktop.rs:238-243 | warpgate-core/src/recordings/terminal.rs:99-104 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
  • Duplicated block (6 lines × 2) warpgate-db-migrations/src/m00010_parameters.rs:41 — warpgate-db-migrations/src/m00010_parameters.rs:41-46 | warpgate-db-migrations/src/m00020_ldap_server.rs:54-59 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
D4 · Code Duplication · Duplicated block (15 lines × 2) · ×3
  • Duplicated block (15 lines × 2) warpgate-db-migrations/src/m00025_ssh_client_auth.rs:28 — warpgate-db-migrations/src/m00025_ssh_client_auth.rs:28-42 | warpgate-db-migrations/src/m00044_ticket_requests.rs:135-151 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
  • Duplicated block (15 lines × 2) warpgate-db-migrations/src/m00019_rate_limits.rs:38 — warpgate-db-migrations/src/m00019_rate_limits.rs:38-52 | warpgate-db-migrations/src/m00044_ticket_requests.rs:201-216 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
  • Duplicated block (15 lines × 2) warpgate-db-migrations/src/m00031_minimize_password_login.rs:16 — warpgate-db-migrations/src/m00031_minimize_password_login.rs:16-30 | warpgate-db-migrations/src/m00050_password_policy.rs:67-81 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
D4 · Code Duplication · Duplicated block (16 lines × 2) · ×3
  • Duplicated block (16 lines × 2) warpgate-db-migrations/src/m00044_ticket_requests.rs:219 — warpgate-db-migrations/src/m00044_ticket_requests.rs:219-234 | warpgate-db-migrations/src/m00086_jit_session_approval.rs:66-81 — before extracting anything, compare `warpgate-db-migrations/src/m00044_ticket_requests.rs` and `warpgate-db-migrations/src/m00086_jit_session_approval.rs` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 46 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
  • Duplicated block (16 lines × 2) warpgate-db-migrations/src/m00044_ticket_requests.rs:106 — warpgate-db-migrations/src/m00044_ticket_requests.rs:106-121 | warpgate-db-migrations/src/m00086_jit_session_approval.rs:100-115 — before extracting anything, compare `warpgate-db-migrations/src/m00044_ticket_requests.rs` and `warpgate-db-migrations/src/m00086_jit_session_approval.rs` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 46 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
  • Duplicated block (16 lines × 2) warpgate-common/src/audit.rs:219 — warpgate-common/src/audit.rs:219-234 | warpgate-common/src/audit.rs:252-267 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
D1 · Cyclomatic Complexity · warpgate · ×2
  • warpgate::commands::setup::command (cyclomatic 49) warpgate/src/commands/setup.rs:52 — warpgate::commands::setup::command has cyclomatic complexity 49 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • warpgate::commands::run::command (cyclomatic 23) warpgate/src/commands/run.rs:62 — warpgate::commands::run::command has cyclomatic complexity 23 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform — the same kind of value, with no behaviour of its own — a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing.
D1 · Cyclomatic Complexity · warpgate_protocol_rdp · ×2
  • warpgate_protocol_rdp::server::control_loop (cyclomatic 34) warpgate-protocol-rdp/src/server/mod.rs:209 — warpgate_protocol_rdp::server::control_loop has cyclomatic complexity 34 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • warpgate_protocol_rdp::client::active_loop (cyclomatic 22) warpgate-protocol-rdp/src/client/mod.rs:153 — warpgate_protocol_rdp::client::active_loop has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · warpgate_protocol_vnc · ×2
  • warpgate_protocol_vnc::server::protocol::read_client_messages (cyclomatic 20) warpgate-protocol-vnc/src/server/protocol.rs:266 — warpgate_protocol_vnc::server::protocol::read_client_messages has cyclomatic complexity 20 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform — the same kind of value, with no behaviour of its own — a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing.
  • warpgate_protocol_vnc::server::bridge::run_proxy_session (cyclomatic 20) warpgate-protocol-vnc/src/server/bridge.rs:108 — warpgate_protocol_vnc::server::bridge::run_proxy_session has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D2 · Cognitive Complexity · warpgate_web_desktop · ×2
  • warpgate_web_desktop::api::ws_handler (cognitive 41) warpgate-web-desktop/src/api.rs:19 — warpgate_web_desktop::api::ws_handler has cognitive complexity 41 (threshold 15). Drivers by points: if/else 8 (25 pts), match/switch 4 (9 pts), boolean chains 4, loops 2 (3 pts) (nesting depth added 23). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • warpgate_web_desktop::manager::spawn_event_loop (cognitive 22) warpgate-web-desktop/src/manager.rs:235 — warpgate_web_desktop::manager::spawn_event_loop has cognitive complexity 22 (threshold 15). Drivers by points: match/switch 4 (11 pts), if/else 2 (5 pts), loops 2 (4 pts), boolean chains 2 (nesting depth added 12). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
D2 · Cognitive Complexity · warpgate_desktop_auth · ×2
  • warpgate_desktop_auth::hold_screen::run_hold_screen (cognitive 28) warpgate-desktop-auth/src/hold_screen.rs:145 — warpgate_desktop_auth::hold_screen::run_hold_screen has cognitive complexity 28 (threshold 15). Drivers by points: match/switch 4 (15 pts), if/else 3 (9 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 18). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
  • warpgate_desktop_auth::authenticate (cognitive 19) warpgate-desktop-auth/src/lib.rs:72 — warpgate_desktop_auth::authenticate has cognitive complexity 19 (threshold 15). Drivers by points: if/else 6 (14 pts), match/switch 3 (5 pts) (nesting depth added 10). The drivers above price the dispatch low by construction — a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full — so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
D2 · Cognitive Complexity · warpgate_admin · ×2
  • warpgate_admin::api::recordings_detail::serve_live_stream (cognitive 26) warpgate-admin/src/api/recordings_detail.rs:270 — warpgate_admin::api::recordings_detail::serve_live_stream has cognitive complexity 26 (threshold 15). Drivers by points: match/switch 5 (14 pts), if/else 4 (10 pts), boolean chains 1, loops 1 (nesting depth added 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
  • warpgate_admin::api::recordings_detail::replay_scratch_span_awaiting (cognitive 16) warpgate-admin/src/api/recordings_detail.rs:213 — warpgate_admin::api::recordings_detail::replay_scratch_span_awaiting has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (12 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · Connector · ×2
  • Connector::authenticate_session (cognitive 24) warpgate-protocol-ssh/src/client/mod.rs:872 — Connector::authenticate_session has cognitive complexity 24 (threshold 15). Drivers by points: if/else 9 (19 pts), boolean chains 2, loops 1 (2 pts), match/switch 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • Connector::_handle_auth_result (cognitive 19) warpgate-protocol-ssh/src/client/mod.rs:1038 — Connector::_handle_auth_result has cognitive complexity 19 (threshold 15). Drivers by points: loops 3 (11 pts), match/switch 2 (5 pts), if/else 1 (3 pts) (nesting depth added 13). The drivers above price the dispatch low by construction — a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full — so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
D2 · Cognitive Complexity · warpgate_protocol_http · ×2
  • warpgate_protocol_http::catchall::get_target_for_request (cognitive 23) warpgate-protocol-http/src/catchall.rs:128 — warpgate_protocol_http::catchall::get_target_for_request has cognitive complexity 23 (threshold 15). Drivers by points: if/else 16 (22 pts), boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • warpgate_protocol_http::common::inject_request_authorization (cognitive 17) warpgate-protocol-http/src/common.rs:429 — warpgate_protocol_http::common::inject_request_authorization has cognitive complexity 17 (threshold 15). Drivers by points: if/else 12 (16 pts), boolean chains 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · Migration · ×2
  • Migration::up (cognitive 21) warpgate-db-migrations/src/m00038_fix_target_auth_tags.rs:50 — Migration::up has cognitive complexity 21 (threshold 15). Drivers by points: if/else 8 (16 pts), match/switch 2 (4 pts), loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • Migration::up (cognitive 16) warpgate-db-migrations/src/m00087_drop_null_target_options.rs:78 — Migration::up has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (12 pts), loops 3 (4 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D30 · Dependency Vulnerabilities · Medium vulnerability · ×2
  • REDACTED
  • REDACTED
D35 · Change Coupling · Change coupling · ×2
  • Change coupling: handler.rs ↔ russh_handler.rs warpgate-protocol-ssh/src/client/handler.rs — `warpgate-protocol-ssh/src/client/handler.rs` and `warpgate-protocol-ssh/src/server/russh_handler.rs` change together 75% of the time (9 of the 12 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — a repo-wide or module-wide sweep is evidence about the sweep rather than about any pair inside it and is left out of BOTH sides of this ratio, while a dependency bump, a formatter/rename sweep, or a commit whose edit to one of the two files was a tool directive such as //go:generate or whitespace only is left out of the shared count ONLY, so the two sides are not taken over identical commit sets) with no explicit dependency — the edge is real but nothing declares it. Read the pair before acting: if one registers itself into the other through a hook or an initialiser, the missing dependency is DELIBERATE — the registration is the link, and it is meant not to be an import — and the thing to add is a comment on each side naming the other, not a merge; if they simply belong together, co-locate them; if neither holds, the coupling is hidden and worth breaking. You can check this without leaving the row: of the 9 shared commits counted here, the most recent 3 are `6c231ba6` fixed #1459 - concurrent agent channel requests causing deadlock (#2135); `9453879e` fmt; `e2036886` Implement Agent Forwarding (#1249) — run `git show` on any of them.
  • Change coupling: handler.rs ↔ session.rs warpgate-protocol-ssh/src/client/handler.rs — `warpgate-protocol-ssh/src/client/handler.rs` and `warpgate-protocol-ssh/src/server/session.rs` change together 58% of the time (7 of the 12 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — a repo-wide or module-wide sweep is evidence about the sweep rather than about any pair inside it and is left out of BOTH sides of this ratio, while a dependency bump, a formatter/rename sweep, or a commit whose edit to one of the two files was a tool directive such as //go:generate or whitespace only is left out of the shared count ONLY, so the two sides are not taken over identical commit sets) with no explicit dependency — the edge is real but nothing declares it. Read the pair before acting: if one registers itself into the other through a hook or an initialiser, the missing dependency is DELIBERATE — the registration is the link, and it is meant not to be an import — and the thing to add is a comment on each side naming the other, not a merge; if they simply belong together, co-locate them; if neither holds, the coupling is hidden and worth breaking. You can check this without leaving the row: of the 7 shared commits counted here, the most recent 3 are `f66dee30` #1828 - option to disable host key checks (#2284); `6c231ba6` fixed #1459 - concurrent agent channel requests causing deadlock (#2135); `e2036886` Implement Agent Forwarding (#1249) — run `git show` on any of them.
D4 · Code Duplication · Duplicated block (6 lines × 3) · ×2
  • Duplicated block (6 lines × 3) warpgate-db-migrations/src/m00073_redact_session_target_snapshots.rs:53 — warpgate-db-migrations/src/m00073_redact_session_target_snapshots.rs:53-58 | warpgate-db-migrations/src/m00080_user_and_target_sessions.rs:64-69 | warpgate-db-migrations/src/m00087_drop_null_target_options.rs:100-105 — before extracting anything, compare `warpgate-db-migrations/src/m00073_redact_session_target_snapshots.rs` and `warpgate-db-migrations/src/m00087_drop_null_target_options.rs` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 39 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
  • Duplicated block (6 lines × 3) warpgate-db-migrations/src/m00073_redact_session_target_snapshots.rs:62 — warpgate-db-migrations/src/m00073_redact_session_target_snapshots.rs:62-67 | warpgate-db-migrations/src/m00080_user_and_target_sessions.rs:74-79 | warpgate-db-migrations/src/m00087_drop_null_target_options.rs:109-114 — before extracting anything, compare `warpgate-db-migrations/src/m00073_redact_session_target_snapshots.rs` and `warpgate-db-migrations/src/m00087_drop_null_target_options.rs` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 39 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
D4 · Code Duplication · Duplicated block (5 lines × 2) · ×2
  • Duplicated block (5 lines × 2) warpgate-core/src/recordings/traffic.rs:186 — warpgate-core/src/recordings/traffic.rs:186-190 | warpgate-core/src/recordings/traffic.rs:198-202 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (5 lines × 2) warpgate-admin/src/api/recordings_detail.rs:106 — warpgate-admin/src/api/recordings_detail.rs:106-110 | warpgate-admin/src/api/recordings_detail.rs:123-127 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
D4 · Code Duplication · Duplicated block (17 lines × 2) · ×2
  • Duplicated block (17 lines × 2) warpgate-db-migrations/src/m00078_assignment_composite_pks.rs:47 — warpgate-db-migrations/src/m00078_assignment_composite_pks.rs:47-74 | warpgate-db-migrations/src/m00078_assignment_composite_pks.rs:153-169 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (17 lines × 2) warpgate-db-migrations/src/m00034_add_log_related_fields.rs:25 — warpgate-db-migrations/src/m00034_add_log_related_fields.rs:25-41 | warpgate-db-migrations/src/m00034_add_log_related_fields.rs:48-64 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
R10 · Code Duplication · Duplicated block (11 lines × 2 locations) · ×2
  • Duplicated block (11 lines × 2 locations) REDACTED:203 — REDACTED:203 · REDACTED:224 — all 2 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported.
  • Duplicated block (11 lines × 2 locations) warpgate-web/src/gateway/lib/certificateStore.ts:24 — warpgate-web/src/gateway/lib/certificateStore.ts:24 · warpgate-web/src/gateway/lib/certificateStore.ts:48 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
R7 · Dead Code · Dead file (~158 LoC) · ×2
  • Dead file (~158 LoC) warpgate-web/src/admin/CertificateCredentialModal.svelte — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 3 in-repo import(s) from 3 other file(s) do name it (warpgate-web/src/admin/config/users/CredentialEditor.svelte, warpgate-web/src/common/ConnectionInstructions.svelte, warpgate-web/src/gateway/CredentialManager.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
  • Dead file (~158 LoC) warpgate-web/src/admin/config/targets/ssh/KeyChecker.svelte — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/admin/config/targets/ssh/Options.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~142 LoC) · ×2
  • Dead file (~142 LoC) warpgate-web/src/admin/config/AdminRole.svelte — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/admin/config/Config.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
  • Dead file (~142 LoC) warpgate-web/src/admin/config/ldap/LdapServer.svelte — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/admin/config/Config.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
D1 · Cyclomatic Complexity · SessionChannel · ×1
  • SessionChannel::run (cyclomatic 26) warpgate-protocol-ssh/src/client/channel_session.rs:40 — SessionChannel::run has cyclomatic complexity 26 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform — the same kind of value, with no behaviour of its own — a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing.
D1 · Cyclomatic Complexity · warpgate_protocol_kubernetes · ×1
  • warpgate_protocol_kubernetes::server::handlers::_handle_normal_request_inner (cyclomatic 24) warpgate-protocol-kubernetes/src/server/handlers.rs:229 — warpgate_protocol_kubernetes::server::handlers::_handle_normal_request_inner has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · warpgate_web_desktop · ×1
  • warpgate_web_desktop::api::ws_handler (cyclomatic 21) warpgate-web-desktop/src/api.rs:19 — warpgate_web_desktop::api::ws_handler has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · Api · ×1
  • Api::api_get_info (cyclomatic 19) warpgate-protocol-http/src/api/info.rs:164 — Api::api_get_info has cyclomatic complexity 19 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · MySqlClient · ×1
  • MySqlClient::connect (cyclomatic 19) warpgate-protocol-mysql/src/client.rs:41 — MySqlClient::connect has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · PostgresClient · ×1
  • PostgresClient::connect (cyclomatic 18) warpgate-protocol-postgres/src/client.rs:59 — PostgresClient::connect has cyclomatic complexity 18 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform — the same kind of value, with no behaviour of its own — a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing.
D1 · Cyclomatic Complexity · warpgate_web_ssh · ×1
  • warpgate_web_ssh::api::ws_handler (cyclomatic 18) warpgate-web-ssh/src/api.rs:20 — warpgate_web_ssh::api::ws_handler has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · TargetMenu · ×1
  • TargetMenu::handle_input (cyclomatic 17) warpgate-protocol-ssh/src/server/target_menu.rs:191 — TargetMenu::handle_input has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · PlaybackController.doSeek (cyclomatic 17) · ×1
  • PlaybackController.doSeek (cyclomatic 17) warpgate-web/src/admin/player/playbackController.ts:173 — PlaybackController.doSeek has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · warpgate_desktop_auth · ×1
  • warpgate_desktop_auth::hold_screen::run_hold_screen (cyclomatic 16) warpgate-desktop-auth/src/hold_screen.rs:145 — warpgate_desktop_auth::hold_screen::run_hold_screen has cyclomatic complexity 16 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform — the same kind of value, with no behaviour of its own — a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing.
D1 · Cyclomatic Complexity · CookieHostMiddlewareEndpoint · ×1
  • CookieHostMiddlewareEndpoint::call (cyclomatic 16) warpgate-protocol-http/src/middleware/cookie_host.rs:50 — CookieHostMiddlewareEndpoint::call has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D2 · Cognitive Complexity · Api · ×1
  • Api::api_get_info (cognitive 37) warpgate-protocol-http/src/api/info.rs:164 — Api::api_get_info has cognitive complexity 37 (threshold 15). Drivers by points: if/else 24 (31 pts), boolean chains 3, match/switch 3 (nesting depth added 7). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · warpgate_web_ssh · ×1
  • warpgate_web_ssh::api::ws_handler (cognitive 35) warpgate-web-ssh/src/api.rs:20 — warpgate_web_ssh::api::ws_handler has cognitive complexity 35 (threshold 15). Drivers by points: if/else 7 (22 pts), match/switch 3 (6 pts), loops 3 (5 pts), boolean chains 2 (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · DirtyTracker · ×1
  • DirtyTracker::take_settled (cognitive 27) warpgate-web-desktop/src/dirty.rs:71 — DirtyTracker::take_settled has cognitive complexity 27 (threshold 15). Drivers by points: loops 6 (16 pts), if/else 3 (11 pts) (nesting depth added 18). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline.
D2 · Cognitive Complexity · CookieHostMiddlewareEndpoint · ×1
  • CookieHostMiddlewareEndpoint::call (cognitive 26) warpgate-protocol-http/src/middleware/cookie_host.rs:50 — CookieHostMiddlewareEndpoint::call has cognitive complexity 26 (threshold 15). Drivers by points: if/else 11 (20 pts), loops 2 (3 pts), boolean chains 2, match/switch 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · warpgate_protocol_ssh · ×1
  • warpgate_protocol_ssh::server::target_menu::run_target_menu_loop (cognitive 24) warpgate-protocol-ssh/src/server/target_menu.rs:499 — warpgate_protocol_ssh::server::target_menu::run_target_menu_loop has cognitive complexity 24 (threshold 15). Drivers by points: if/else 6 (17 pts), match/switch 2 (5 pts), boolean chains 1, loops 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · PostgresClient · ×1
  • PostgresClient::connect (cognitive 22) warpgate-protocol-postgres/src/client.rs:59 — PostgresClient::connect has cognitive complexity 22 (threshold 15). Drivers by points: if/else 6 (13 pts), match/switch 4 (8 pts), loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · TlsCertificateBundle · ×1
  • TlsCertificateBundle::sni_names (cognitive 22) warpgate-tls/src/cert.rs:83 — TlsCertificateBundle::sni_names has cognitive complexity 22 (threshold 15). Drivers by points: if/else 7 (13 pts), loops 2 (4 pts), match/switch 1 (4 pts), boolean chains 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · MySqlClient · ×1
  • MySqlClient::connect (cognitive 20) warpgate-protocol-mysql/src/client.rs:41 — MySqlClient::connect has cognitive complexity 20 (threshold 15). Drivers by points: if/else 8 (11 pts), match/switch 3 (6 pts), boolean chains 2, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · ListenerSupervisor · ×1
  • ListenerSupervisor::run (cognitive 19) warpgate/src/listener_supervisor.rs:115 — ListenerSupervisor::run has cognitive complexity 19 (threshold 15). Drivers by points: if/else 4 (12 pts), match/switch 3 (6 pts), loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · helpers.toClassName (cognitive 19) · ×1
  • helpers.toClassName (cognitive 19) warpgate-web/src/common/helpers.ts:55 — helpers.toClassName has cognitive complexity 19 (threshold 15). Drivers by points: if/else 6 (14 pts), loops 1 (3 pts), boolean chains 2 (nesting depth added 10). To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
D2 · Cognitive Complexity · HandshakeResponse · ×1
  • HandshakeResponse::encode_with (cognitive 18) warpgate-database-protocols/src/mysql/protocol/connect/handshake_response.rs:36 — HandshakeResponse::encode_with has cognitive complexity 18 (threshold 15). Drivers by points: if/else 14 (18 pts) (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · protocols.getEffectivePossibleCredentials (cognitive 18) · ×1
  • protocols.getEffectivePossibleCredentials (cognitive 18) REDACTED:331 — protocols.getEffectivePossibleCredentials has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (11 pts), boolean chains 5, loops 1 (2 pts) (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · Services · ×1
  • Services::poll_admin_approval (cognitive 17) warpgate-core/src/approvals/gate.rs:206 — Services::poll_admin_approval has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (11 pts), match/switch 4 (6 pts) (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · ResponseRelay · ×1
  • ResponseRelay::next (cognitive 17) warpgate-protocol-mysql/src/relay.rs:62 — ResponseRelay::next has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9 (16 pts), boolean chains 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · PostgresSession · ×1
  • PostgresSession::run_authorized_inner (cognitive 17) warpgate-protocol-postgres/src/session.rs:352 — PostgresSession::run_authorized_inner has cognitive complexity 17 (threshold 15). Drivers by points: match/switch 7 (13 pts), if/else 1 (3 pts), loops 1 (nesting depth added 8). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
D2 · Cognitive Complexity · TargetMenu · ×1
  • TargetMenu::handle_input (cognitive 17) warpgate-protocol-ssh/src/server/target_menu.rs:191 — TargetMenu::handle_input has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (13 pts), match/switch 1 (2 pts), boolean chains 1, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D22 · Internal API Consistency · Inconsistent naming for standard I/O operations. `FramedRead` uses `read` (standard Rust `Read` trait name), while `FramedWrite` uses `write_all` (standard Rust `Write` trait method for full buffer writes). This creates asymmetry in the API surface. · ×1
  • Inconsistent naming for standard I/O operations. `FramedRead` uses `read` (standard Rust `Read` trait name), while `FramedWrite` uses `write_all` (standard Rust `Write` trait method for full buffer writes). This creates asymmetry in the API surface. — Rename `FramedWrite.write_all` to `FramedWrite.write` to match `FramedRead.read`, or rename `FramedRead.read` to `FramedRead.read_all` if partial reads are not supported. Given the context of framing, `write` is likely the intended symmetric counterpart to `read`. (signatures: FramedRead.read(buf: BytesMut): ReadFut | FramedWrite.write_all(buf: &[u8]): WriteAllFut)
D22 · Internal API Consistency · Inconsistent constructor patterns for wrapping streams. `StreamWrapper` uses a static factory method `from_inner`, while `Framed` uses `new` and `new_with_leftover`. This forces users to remember different instantiation patterns for similar wrapper types. · ×1
  • Inconsistent constructor patterns for wrapping streams. `StreamWrapper` uses a static factory method `from_inner`, while `Framed` uses `new` and `new_with_leftover`. This forces users to remember different instantiation patterns for similar wrapper types. — Standardize on `new` for constructors. Rename `StreamWrapper.from_inner` to `StreamWrapper.new` or provide a `new` constructor that takes the inner stream. (signatures: StreamWrapper.from_inner(stream: InnerStream): Self | Framed.new(stream: InnerStream): Self | Framed.new_with_leftover(stream: InnerStream, leftover: BytesMut): Self)
D22 · Internal API Consistency · Inconsistent return types for `into_inner`. `StreamWrapper.into_inner` returns the inner type directly, while `Framed.into_inner` returns a tuple `(InnerStream, BytesMut)`. This breaks the expectation that `into_inner` always returns the wrapped inner component in a consistent shape, forcing users to handle the tuple unpacking for `Framed` specifically. · ×1
  • Inconsistent return types for `into_inner`. `StreamWrapper.into_inner` returns the inner type directly, while `Framed.into_inner` returns a tuple `(InnerStream, BytesMut)`. This breaks the expectation that `into_inner` always returns the wrapped inner component in a consistent shape, forcing users to handle the tuple unpacking for `Framed` specifically. — Align the return types. Either have `StreamWrapper` return a tuple if it also holds state, or provide `Framed.into_inner_stream()` that returns just the stream, keeping `into_inner` for the full state extraction. Given `into_inner_no_leftover` exists, `into_inner` is ambiguous in intent (does it include leftover?). A clearer name like `into_inner_with_leftover` for the tuple version would help, but the asymmetry with `StreamWrapper` is the primary issue. (signatures: StreamWrapper.into_inner(): InnerStream | Framed.into_inner(): (InnerStream, BytesMut) | Framed.into_inner_no_leftover(): InnerStream)
D22 · Internal API Consistency · Inconsistent return types for `get_inner`/`get_inner_mut`. `StreamWrapper` returns the inner stream directly, while `Framed` returns a tuple of references. This inconsistency requires different handling code depending on which wrapper type is being used. · ×1
  • Inconsistent return types for `get_inner`/`get_inner_mut`. `StreamWrapper` returns the inner stream directly, while `Framed` returns a tuple of references. This inconsistency requires different handling code depending on which wrapper type is being used. — Standardize the return type. If `Framed` needs to expose both stream and leftover buffer, `StreamWrapper` should likely do the same if it holds similar state, or `Framed` should provide separate getters like `get_stream()` and `get_leftover()` to avoid the tuple asymmetry. (signatures: StreamWrapper.get_inner(): InnerStream | StreamWrapper.get_inner_mut(): InnerStream | Framed.get_inner(): (&InnerStream, &BytesMut) | Framed.get_inner_mut(): (&mut InnerStream, &mut BytesMut))
D29 · Static Analysis (SAST) · REDACTED · ×1
  • REDACTED
D29 · Static Analysis (SAST) · REDACTED · ×1
  • REDACTED
D3 · God Classes · TooManyMethods · ×1
  • TooManyMethods: ServerSession warpgate-protocol-ssh/src/server/session.rs:129 — TooManyMethods — 68 methods. The bar is 30 methods; this is 38 over it, 2.27× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
D30 · Dependency Vulnerabilities · Medium advisory (unsound) · ×1
  • REDACTED
D36 · Supply-chain Provenance & Signing · REDACTED · ×1
  • REDACTED
D36 · Supply-chain Provenance & Signing · REDACTED · ×1
  • REDACTED
D36 · Supply-chain Provenance & Signing · REDACTED · ×1
  • REDACTED
D4 · Code Duplication · Near-duplicate member pair (50 shared lines) · ×1
  • Near-duplicate member pair (50 shared lines) warpgate-db-migrations/src/m00078_assignment_composite_pks.rs:24 — warpgate-db-migrations/src/m00078_assignment_composite_pks.rs:24-134 | warpgate-db-migrations/src/m00078_assignment_composite_pks.rs:136-240 — These two members are variants of one another: 50 of their lines are already reported as duplicated blocks below, spread through both bodies rather than gathered into one. Read them as a single construct written twice. The repair is at the members' grain — factor the shared pipeline into one implementation the two call with their differences as parameters or as an injected step, or, where the difference is systematic (sync against async, one transport against another), generate one from the other. Extracting the individual blocks below is not the same fix: it leaves the two bodies in place and the next edit still has to be made twice.
D4 · Code Duplication · Members sharing a duplicated core (4 members, 50+ identical tokens) · ×1
  • Members sharing a duplicated core (4 members, 50+ identical tokens) warpgate-common/src/auth/state.rs:463 — warpgate-common/src/auth/state.rs:463-476 | warpgate-core/src/approvals/subject.rs:61-74 | warpgate-core/src/approvals/subject.rs:76-89 | warpgate-core/src/approvals/subject.rs:91-104 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
D4 · Code Duplication · Duplicated block (27 lines × 2) · ×1
  • Duplicated block (27 lines × 2) warpgate-db-migrations/src/m00073_redact_session_target_snapshots.rs:48 — warpgate-db-migrations/src/m00073_redact_session_target_snapshots.rs:48-74 | warpgate-db-migrations/src/m00087_drop_null_target_options.rs:95-121 — before extracting anything, compare `warpgate-db-migrations/src/m00073_redact_session_target_snapshots.rs` and `warpgate-db-migrations/src/m00087_drop_null_target_options.rs` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 39 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
D4 · Code Duplication · Duplicated block (18–20 lines × 2) · ×1
  • Duplicated block (18–20 lines × 2) warpgate-core/src/logging/json_console.rs:37 — warpgate-core/src/logging/json_console.rs:37-56 | warpgate-core/src/logging/layer.rs:50-67 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
D4 · Code Duplication · Duplicated block (16–18 lines × 2) · ×1
  • Duplicated block (16–18 lines × 2) warpgate-web-desktop/src/api.rs:29 — warpgate-web-desktop/src/api.rs:29-44 | warpgate-web-ssh/src/api.rs:31-48 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice.
D4 · Code Duplication · Duplicated block (9–13 lines × 2) · ×1
  • Duplicated block (9–13 lines × 2) warpgate-db-migrations/src/m00072_session_node_id_not_null.rs:19 — warpgate-db-migrations/src/m00072_session_node_id_not_null.rs:19-31 | warpgate-db-migrations/src/m00080_user_and_target_sessions.rs:232-240 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
D4 · Code Duplication · Duplicated block (12 lines × 2) · ×1
  • Duplicated block (12 lines × 2) warpgate-admin/src/api/certificate_credentials.rs:142 — warpgate-admin/src/api/certificate_credentials.rs:142-153 | warpgate-protocol-http/src/api/credentials.rs:638-649 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice.
D4 · Code Duplication · Duplicated block (8–12 lines × 2) · ×1
  • Duplicated block (8–12 lines × 2) warpgate-protocol-mysql/src/lib.rs:49 — warpgate-protocol-mysql/src/lib.rs:49-56 | warpgate-protocol-postgres/src/lib.rs:50-61 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice.
D4 · Code Duplication · Duplicated block (8–9 lines × 2) · ×1
  • Duplicated block (8–9 lines × 2) warpgate-admin/src/api/certificate_credentials.rs:194 — warpgate-admin/src/api/certificate_credentials.rs:194-201 | warpgate-admin/src/api/certificate_credentials.rs:226-234 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
D4 · Code Duplication · Duplicated block (8 lines × 6) · ×1
  • Duplicated block (8 lines × 6) warpgate-common/src/audit.rs:516 — warpgate-common/src/audit.rs:516-523 | warpgate-common/src/audit.rs:541-548 | warpgate-common/src/audit.rs:563-570 | warpgate-common/src/audit.rs:585-592 | warpgate-common/src/audit.rs:612-619 | warpgate-common/src/audit.rs:643-650 — all 6 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
D4 · Code Duplication · Duplicated block (8 lines × 3) · ×1
  • Duplicated block (8 lines × 3) warpgate-protocol-mysql/src/lib.rs:49 — warpgate-protocol-mysql/src/lib.rs:49-56 | warpgate-protocol-postgres/src/lib.rs:50-57 | warpgate-protocol-vnc/src/server/mod.rs:49-56 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 3 times.
D4 · Code Duplication · Duplicated block (7 lines × 4) · ×1
  • Duplicated block (7 lines × 4) warpgate-common/src/auth/state.rs:467 — warpgate-common/src/auth/state.rs:467-473 | warpgate-core/src/approvals/subject.rs:65-71 | warpgate-core/src/approvals/subject.rs:80-86 | warpgate-core/src/approvals/subject.rs:95-101 — there are 4 copies across 2 file(s) — more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 4 sites; resolving a subset leaves the remainder to drift apart.
D4 · Code Duplication · Duplicated block (10 lines × 4) · ×1
  • Duplicated block (10 lines × 4) warpgate-protocol-mysql/src/session_handle.rs:9 — warpgate-protocol-mysql/src/session_handle.rs:9-18 | warpgate-protocol-postgres/src/session_handle.rs:9-18 | warpgate-protocol-rdp/src/session_handle.rs:9-18 | warpgate-protocol-vnc/src/server/session_handle.rs:9-18 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 4 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 4 times.
D4 · Code Duplication · Duplicated block (9 lines × 8) · ×1
  • Duplicated block (9 lines × 8) warpgate-db-entities/src/ApiToken.rs:25 — warpgate-db-entities/src/ApiToken.rs:25-33 | warpgate-db-entities/src/CertificateCredential.rs:28-36 | warpgate-db-entities/src/OtpCredential.rs:23-31 | warpgate-db-entities/src/PasswordCredential.rs:23-31 | warpgate-db-entities/src/PublicKeyCredential.rs:28-36 | warpgate-db-entities/src/SsoCredential.rs:24-32 | warpgate-db-migrations/src/m00014_api_tokens.rs:31-39 | warpgate-db-migrations/src/m00028_certificate_credentials.rs:33-41 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 8 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 8 times.
D4 · Code Duplication · Duplicated block (20 lines × 2) · ×1
  • Duplicated block (20 lines × 2) warpgate-db-migrations/src/m00078_assignment_composite_pks.rs:88 — warpgate-db-migrations/src/m00078_assignment_composite_pks.rs:88-108 | warpgate-db-migrations/src/m00078_assignment_composite_pks.rs:179-198 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
D4 · Code Duplication · Duplicated block (17 lines × 4) · ×1
  • Duplicated block (17 lines × 4) warpgate-db-migrations/src/m00044_ticket_requests.rs:121 — warpgate-db-migrations/src/m00044_ticket_requests.rs:121-137 | warpgate-db-migrations/src/m00044_ticket_requests.rs:176-192 | warpgate-db-migrations/src/m00050_password_policy.rs:23-39 | warpgate-db-migrations/src/m00050_password_policy.rs:51-67 — there are 4 copies across 2 file(s) — more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 4 sites; resolving a subset leaves the remainder to drift apart.
D4 · Code Duplication · Duplicated block (15 lines × 4) · ×1
  • Duplicated block (15 lines × 4) warpgate-db-migrations/src/m00025_ssh_client_auth.rs:42 — warpgate-db-migrations/src/m00025_ssh_client_auth.rs:42-56 | warpgate-db-migrations/src/m00037_show_session_menu.rs:16-30 | warpgate-db-migrations/src/m00047_record_scp.rs:11-25 | warpgate-db-migrations/src/m00083_record_desktop_keyboard_input.rs:11-25 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from all 4 call sites, so a change lands once.
D4 · Code Duplication · Duplicated block (14 lines × 5) · ×1
  • Duplicated block (14 lines × 5) warpgate-db-migrations/src/m00044_ticket_requests.rs:120 — warpgate-db-migrations/src/m00044_ticket_requests.rs:120-134 | warpgate-db-migrations/src/m00044_ticket_requests.rs:175-189 | warpgate-db-migrations/src/m00050_password_policy.rs:22-36 | warpgate-db-migrations/src/m00050_password_policy.rs:50-64 | warpgate-db-migrations/src/m00084_mfa_enforcement.rs:22-35 — there are 5 copies across 3 file(s) — more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 5 sites; resolving a subset leaves the remainder to drift apart.
D4 · Code Duplication · Duplicated block (14 lines × 4) · ×1
  • Duplicated block (14 lines × 4) warpgate-common/src/audit.rs:314 — warpgate-common/src/audit.rs:314-327 | warpgate-common/src/audit.rs:334-347 | warpgate-common/src/audit.rs:354-367 | warpgate-common/src/audit.rs:374-387 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
D4 · Code Duplication · Duplicated block (14 lines × 3) · ×1
  • Duplicated block (14 lines × 3) warpgate-db-migrations/src/m00044_ticket_requests.rs:221 — warpgate-db-migrations/src/m00044_ticket_requests.rs:221-234 | warpgate-db-migrations/src/m00044_ticket_requests.rs:235-248 | warpgate-db-migrations/src/m00086_jit_session_approval.rs:68-81 — before extracting anything, compare `warpgate-db-migrations/src/m00044_ticket_requests.rs` and `warpgate-db-migrations/src/m00086_jit_session_approval.rs` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 46 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
D4 · Code Duplication · Duplicated block (12 lines × 3) · ×1
  • Duplicated block (12 lines × 3) warpgate-db-migrations/src/m00025_ssh_client_auth.rs:60 — warpgate-db-migrations/src/m00025_ssh_client_auth.rs:60-71 | warpgate-db-migrations/src/m00027_ca.rs:97-109 | warpgate-db-migrations/src/m00084_mfa_enforcement.rs:40-51 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from all 3 call sites, so a change lands once.
D44 · Platform End-of-Life · End-of-life runtime · ×1
  • End-of-life runtime: .NET net6.0 — vendor/sspi/tools/aadjoin/UnitTests/UnitTests.csproj declares .NET net6.0 as this project's target framework, and .NET 6 LTS, support ended 2024-11-12. An unsupported runtime receives no security patches, so every vulnerability disclosed in it since 2024-11-12 is present and unfixable without moving off it. This is a migration rather than an upgrade: there is no newer release of a runtime that has ended.
D5 · Coupling · Unstable project warpgate-web-desktop · ×1
  • Unstable project warpgate-web-desktop — warpgate-web-desktop has instability 0.88 with 1 dependents.
D5 · Coupling · Unstable project warpgate-web-ssh · ×1
  • Unstable project warpgate-web-ssh — warpgate-web-ssh has instability 0.86 with 1 dependents.
P12 · CI test-gate honesty · Coverage collected but not gated · ×1
  • Coverage collected but not gated — CI collects a coverage report but no step enforces a minimum — coverage could halve and CI stays green. Add a step that fails the build when coverage drops below a floor (your coverage tool's minimum-threshold flag, or a coverage-gate action) so the number guards something. What was searched, so you can tell an absence from a miss: this repository's CI files AND its coverage configuration — the well-known coverage and test-runner config files, read at the repository root and inside workspace package directories two levels down, so a floor declared beside the tests rather than in the pipeline is credited — matched against the threshold settings this check knows by name. A floor set in your coverage service's web UI rather than in a committed file, or under a setting whose name is not one of those, is not seen here.
R10 · Code Duplication · Duplicated block (28 lines × 2 locations) · ×1
  • Duplicated block (28 lines × 2 locations) warpgate-web/src/gateway/WebDesktop.svelte:446 — warpgate-web/src/gateway/WebDesktop.svelte:446 · warpgate-web/src/gateway/WebSsh.svelte:258 — the 2 copies sit in sibling files in one directory, so check first whether one of them (or an existing module there) already owns this behaviour and the others should call it; otherwise extract it into one module in that directory and have each site call it.
R10 · Code Duplication · Duplicated block (23 lines × 2 locations) · ×1
  • Duplicated block (23 lines × 2 locations) warpgate-web/src/admin/config/AccessRoles.svelte:12 — warpgate-web/src/admin/config/AccessRoles.svelte:12 · warpgate-web/src/admin/config/users/Users.svelte:21 — the 2 copies are spread across 2 directories, so the shared home is a decision rather than an obvious spot: check first whether one of them already owns this behaviour, and otherwise put the extracted module somewhere all of the sites already reach rather than making one of them depend on another.
R10 · Code Duplication · Duplicated block with local edits (19 matched lines × 2 locations) · ×1
  • Duplicated block with local edits (19 matched lines × 2 locations) warpgate-web/src/admin/config/Parameters.svelte:80 — warpgate-web/src/admin/config/Parameters.svelte:80 · warpgate-web/src/admin/config/Policies.svelte:16 — the two spans are one implementation copied and then locally edited — 93 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one.
R10 · Code Duplication · Duplicated block (17 lines × 2 locations) · ×1
  • Duplicated block (17 lines × 2 locations) warpgate-web/src/admin/player/DesktopRecordingPlayer.svelte:140 — warpgate-web/src/admin/player/DesktopRecordingPlayer.svelte:140 · warpgate-web/src/admin/player/TerminalRecordingPlayer.svelte:202 — the 2 copies are spread across 2 files, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported.
R10 · Code Duplication · Duplicated block (16 lines × 3 locations) · ×1
  • Duplicated block (16 lines × 3 locations) warpgate-web/src/admin/config/AccessRoles.svelte:19 — warpgate-web/src/admin/config/AccessRoles.svelte:19 · warpgate-web/src/admin/config/target-groups/TargetGroups.svelte:12 · warpgate-web/src/admin/config/users/Users.svelte:28 — the 3 copies are spread across 3 files, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported.
R10 · Code Duplication · Duplicated block (16 lines × 2 locations) · ×1
  • Duplicated block (16 lines × 2 locations) warpgate-web/src/admin/config/ldap/CreateLdapServer.svelte:48 — warpgate-web/src/admin/config/ldap/CreateLdapServer.svelte:48 · warpgate-web/src/admin/config/ldap/LdapServer.svelte:82 — the 2 copies sit in sibling files in one directory, so check first whether one of them (or an existing module there) already owns this behaviour and the others should call it; otherwise extract it into one module in that directory and have each site call it.
R10 · Code Duplication · Duplicated block (15 lines × 2 locations) · ×1
  • Duplicated block (15 lines × 2 locations) warpgate-web/src/admin/config/AccessRole.svelte:27 — warpgate-web/src/admin/config/AccessRole.svelte:27 · warpgate-web/src/admin/config/AccessRole.svelte:43 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
R10 · Code Duplication · Duplicated block (15 lines × 3 locations) · ×1
  • Duplicated block (15 lines × 3 locations) warpgate-web/src/admin/config/AccessRole.svelte:62 — warpgate-web/src/admin/config/AccessRole.svelte:62 · warpgate-web/src/admin/config/AdminRole.svelte:127 · warpgate-web/src/admin/config/targets/Target.svelte:81 — the 3 copies are spread across 3 files, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported.
R10 · Code Duplication · Duplicated block (9 lines × 2 locations) · ×1
  • Duplicated block (9 lines × 2 locations) warpgate-web/src/admin/lib/api.ts:8 — warpgate-web/src/admin/lib/api.ts:8 · warpgate-web/src/gateway/lib/api.ts:4 — the 2 copies are spread across 2 directories, so the shared home is a decision rather than an obvious spot: check first whether one of them already owns this behaviour, and otherwise put the extracted module somewhere all of the sites already reach rather than making one of them depend on another.
R10 · Code Duplication · Duplicated block (7 lines × 2 locations) · ×1
  • Duplicated block (7 lines × 2 locations) warpgate-web/src/admin/status/Session.svelte:64 — warpgate-web/src/admin/status/Session.svelte:64 · warpgate-web/src/admin/status/Session.svelte:78 — all 2 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported.
R10 · Code Duplication · Duplicated block (5 lines × 2 locations) · ×1
  • Duplicated block (5 lines × 2 locations) REDACTED:100 — REDACTED:100 · REDACTED:126 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
R2 · Cyclomatic Complexity · Complex function mfaEnforcedFactor (cyclomatic 14, cognitive 14) · ×1
  • Complex function mfaEnforcedFactor (cyclomatic 14, cognitive 14) warpgate-web/src/admin/config/users/AuthPolicyEditor.svelte:113 — mfaEnforcedFactor has cyclomatic complexity 14 and cognitive complexity 14; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function parseHumantimeDuration (cyclomatic 13, cognitive 12) · ×1
  • Complex function parseHumantimeDuration (cyclomatic 13, cognitive 12) warpgate-web/src/common/duration.ts:35 — parseHumantimeDuration has cyclomatic complexity 13 and cognitive complexity 12; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function getEffectivePossibleCredentials (cyclomatic 12, cognitive 18) · ×1
  • Complex function getEffectivePossibleCredentials (cyclomatic 12, cognitive 18) REDACTED:331 — getEffectivePossibleCredentials has cyclomatic complexity 12 and cognitive complexity 18; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function (anonymous) (cyclomatic 12, cognitive 11) · ×1
  • Complex function (anonymous) (cyclomatic 12, cognitive 11) warpgate-web/src/admin/player/DesktopRecordingPlayer.svelte:121 — (anonymous) has cyclomatic complexity 12 and cognitive complexity 11; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function reset (cyclomatic 12, cognitive 7) · ×1
  • Complex function reset (cyclomatic 12, cognitive 7) warpgate-web/src/admin/config/secret-backends/SecretBackendModal.svelte:46 — reset has cyclomatic complexity 12 and cognitive complexity 7; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function onMessage (cyclomatic 12, cognitive 6) · ×1
  • Complex function onMessage (cyclomatic 12, cognitive 6) warpgate-web/src/gateway/WebSsh.svelte:152 — onMessage has cyclomatic complexity 12 and cognitive complexity 6; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function recordingMetadataToFieldSet (cyclomatic 12, cognitive 5) · ×1
  • Complex function recordingMetadataToFieldSet (cyclomatic 12, cognitive 5) warpgate-web/src/common/recordings.ts:63 — recordingMetadataToFieldSet has cyclomatic complexity 12 and cognitive complexity 5; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function updateActiveSectionFromScroll (cyclomatic 11, cognitive 18) · ×1
  • Complex function updateActiveSectionFromScroll (cyclomatic 11, cognitive 18) warpgate-web/src/admin/lib/SectionedForm.svelte:23 — updateActiveSectionFromScroll has cyclomatic complexity 11 and cognitive complexity 18; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function onWsMessage (cyclomatic 11, cognitive 11) · ×1
  • Complex function onWsMessage (cyclomatic 11, cognitive 11) warpgate-web/src/gateway/WebDesktop.svelte:134 — onWsMessage has cyclomatic complexity 11 and cognitive complexity 11; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function save (cyclomatic 11, cognitive 10) · ×1
  • Complex function save (cyclomatic 11, cognitive 10) warpgate-web/src/admin/config/Parameters.svelte:114 — save has cyclomatic complexity 11 and cognitive complexity 10; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R7 · Dead Code · Dead file (~500 LoC) · ×1
  • Dead file (~500 LoC) warpgate-web/src/admin/log-viewer/LogViewer.svelte — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 2 in-repo import(s) from 2 other file(s) do name it (warpgate-web/src/admin/Log.svelte, warpgate-web/src/admin/status/Session.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~491 LoC) · ×1
  • Dead file (~491 LoC) warpgate-web/src/gateway/WebDesktop.svelte — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 2 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/gateway/Root.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~372 LoC) · ×1
  • Dead file (~372 LoC) REDACTED — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 4 in-repo import(s) from 4 other file(s) do name it (warpgate-web/src/admin/config/users/AuthPolicyEditor.svelte, warpgate-web/src/admin/config/users/CredentialEditor.svelte, warpgate-web/src/admin/status/Session.svelte and 1 more) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~331 LoC) · ×1
  • Dead file (~331 LoC) warpgate-web/src/gateway/WebSshTab.svelte — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/gateway/WebSsh.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~324 LoC) · ×1
  • Dead file (~324 LoC) warpgate-web/src/common/desktopInput.ts — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 2 in-repo import(s) from 2 other file(s) do name it (warpgate-web/src/admin/player/DesktopRecordingPlayer.svelte, warpgate-web/src/gateway/WebDesktop.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~322 LoC) · ×1
  • Dead file (~322 LoC) warpgate-web/src/admin/player/TerminalRecordingPlayer.svelte — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/admin/status/Recording.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~321 LoC) · ×1
  • Dead file (~321 LoC) warpgate-web/src/admin/config/users/User.svelte — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/admin/config/Config.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~308 LoC) · ×1
  • Dead file (~308 LoC) warpgate-web/src/admin/config/users/CredentialEditor.svelte — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 2 in-repo import(s) from 2 other file(s) do name it (warpgate-web/src/admin/config/users/AuthPolicyEditor.svelte, warpgate-web/src/admin/config/users/User.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~304 LoC) · ×1
  • Dead file (~304 LoC) warpgate-web/src/gateway/WebSsh.svelte — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 2 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/gateway/Root.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~297 LoC) · ×1
  • Dead file (~297 LoC) warpgate-web/src/admin/player/playbackController.ts — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 2 in-repo import(s) from 2 other file(s) do name it (warpgate-web/src/admin/player/DesktopRecordingPlayer.svelte, warpgate-web/src/admin/player/TerminalRecordingPlayer.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~242 LoC) · ×1
  • Dead file (~242 LoC) warpgate-web/src/admin/player/DesktopRecordingPlayer.svelte — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/admin/status/Recording.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~233 LoC) · ×1
  • Dead file (~233 LoC) warpgate-web/src/common/desktopCanvas.ts — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 2 in-repo import(s) from 2 other file(s) do name it (warpgate-web/src/admin/player/DesktopRecordingPlayer.svelte, warpgate-web/src/gateway/WebDesktop.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~221 LoC) · ×1
  • Dead file (~221 LoC) warpgate-web/src/common/SecretRefInput.svelte — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 7 in-repo import(s) from 7 other file(s) do name it (warpgate-web/src/admin/config/ClientKeyModal.svelte, warpgate-web/src/admin/config/SSHKeys.svelte, warpgate-web/src/admin/config/secret-backends/SecretBackends.svelte and 4 more) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~213 LoC) · ×1
  • Dead file (~213 LoC) warpgate-web/src/admin/config/users/AuthPolicyEditor.svelte — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 2 in-repo import(s) from 2 other file(s) do name it (warpgate-web/src/admin/config/Policies.svelte, warpgate-web/src/admin/config/users/CredentialEditor.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~206 LoC) · ×1
  • Dead file (~206 LoC) warpgate-web/src/common/ConnectionInstructions.svelte — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 5 in-repo import(s) from 5 other file(s) do name it (warpgate-web/src/admin/config/CreateTicket.svelte, warpgate-web/src/admin/config/targets/Target.svelte, warpgate-web/src/gateway/TargetList.svelte and 2 more) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~198 LoC) · ×1
  • Dead file (~198 LoC) warpgate-web/src/gateway/TicketRequests.svelte — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/gateway/App.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~196 LoC) · ×1
  • Dead file (~196 LoC) warpgate-web/src/common/ItemList.svelte — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 13 in-repo import(s) from 13 other file(s) do name it (warpgate-web/src/admin/config/AccessRole.svelte, warpgate-web/src/admin/config/AccessRoles.svelte, warpgate-web/src/admin/config/AdminRole.svelte and 10 more) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~184 LoC) · ×1
  • Dead file (~184 LoC) warpgate-web/src/admin/config/targets/protocolInfo.ts — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/admin/config/targets/ProtocolDocs.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~183 LoC) · ×1
  • Dead file (~183 LoC) warpgate-web/src/admin/status/Requests.svelte — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/admin/status/Status.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~180 LoC) · ×1
  • Dead file (~180 LoC) warpgate-web/src/gateway/TargetList.svelte — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/gateway/App.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~165 LoC) · ×1
  • Dead file (~165 LoC) warpgate-web/src/admin/config/Parameters.svelte — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/admin/config/Config.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~160 LoC) · ×1
  • Dead file (~160 LoC) warpgate-web/src/common/recordings.ts — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/admin/status/Session.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~147 LoC) · ×1
  • Dead file (~147 LoC) warpgate-web/src/admin/lib/store.ts — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 29 in-repo import(s) from 29 other file(s) do name it (warpgate-web/src/admin/App.svelte, warpgate-web/src/admin/config/AccessRole.svelte, warpgate-web/src/admin/config/AccessRoles.svelte and 26 more) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~143 LoC) · ×1
  • Dead file (~143 LoC) warpgate-web/src/common/desktopClipboard.ts — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/gateway/WebDesktop.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~140 LoC) · ×1
  • Dead file (~140 LoC) warpgate-web/src/admin/config/targets/CreateTarget.svelte — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/admin/config/Config.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~135 LoC) · ×1
  • Dead file (~135 LoC) warpgate-web/src/common/duration.ts — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 6 in-repo import(s) from 6 other file(s) do name it (warpgate-web/src/admin/config/Tickets.svelte, warpgate-web/src/admin/status/Requests.svelte, warpgate-web/src/common/DurationInput.svelte and 3 more) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~133 LoC) · ×1
  • Dead file (~133 LoC) warpgate-web/src/gateway/App.svelte — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/gateway/Root.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~126 LoC) · ×1
  • Dead file (~126 LoC) warpgate-web/src/admin/config/targets/Target.svelte — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/admin/config/Config.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~123 LoC) · ×1
  • Dead file (~123 LoC) warpgate-web/src/admin/lib/SectionedForm.svelte — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 3 in-repo import(s) from 3 other file(s) do name it (warpgate-web/src/admin/config/Parameters.svelte, warpgate-web/src/admin/config/targets/Target.svelte, warpgate-web/src/admin/config/users/User.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~119 LoC) · ×1
  • Dead file (~119 LoC) warpgate-web/src/gateway/CredentialManager.svelte — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/gateway/ProfileCredentials.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~115 LoC) · ×1
  • Dead file (~115 LoC) warpgate-web/src/common/RateLimitInput.svelte — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 3 in-repo import(s) from 3 other file(s) do name it (warpgate-web/src/admin/config/Parameters.svelte, warpgate-web/src/admin/config/targets/Target.svelte, warpgate-web/src/admin/config/users/User.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~114 LoC) · ×1
  • Dead file (~114 LoC) warpgate-web/src/common/liveRecordingStream.ts — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/admin/player/playbackController.ts) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~111 LoC) · ×1
  • Dead file (~111 LoC) warpgate-web/src/admin/CreateOtpModal.svelte — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 3 in-repo import(s) from 3 other file(s) do name it (warpgate-web/src/admin/config/users/CredentialEditor.svelte, warpgate-web/src/gateway/CredentialManager.svelte, warpgate-web/src/gateway/MfaSetup.svelte) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~109 LoC) · ×1
  • Dead file (~109 LoC) warpgate-web/src/admin/player/rangeStream.ts — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 3 in-repo import(s) from 3 other file(s) do name it (warpgate-web/src/admin/player/DesktopRecordingPlayer.svelte, warpgate-web/src/admin/player/TerminalRecordingPlayer.svelte, warpgate-web/src/admin/player/playbackController.ts) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~105 LoC) · ×1
  • Dead file (~105 LoC) warpgate-web/src/admin/App.svelte — no import path from any entry point (2 application, 4 tooling, 1 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (warpgate-web/src/admin/index.ts) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R8 · Dependency Hygiene · Unused dependency '@otplib/plugin-base32-enc-dec' · ×1
  • Unused dependency '@otplib/plugin-base32-enc-dec' — Declared in warpgate-web/package.json but never imported anywhere in that package or its workspace members — no static import reaches it. Usually that is dead weight and attack surface, but two shapes are indistinguishable from source and are NOT dead: an optional or native peer that another dependency loads dynamically at runtime, and a package a build, docs or test step installs and invokes separately. Confirm which of the three this is before removing it.
R8 · Dependency Hygiene · Unused dependency '@otplib/plugin-crypto-js' · ×1
  • Unused dependency '@otplib/plugin-crypto-js' — Declared in warpgate-web/package.json but never imported anywhere in that package or its workspace members — no static import reaches it. Usually that is dead weight and attack surface, but two shapes are indistinguishable from source and are NOT dead: an optional or native peer that another dependency loads dynamically at runtime, and a package a build, docs or test step installs and invokes separately. Confirm which of the three this is before removing it.
R8 · Dependency Hygiene · Unused dependency '@otplib/preset-browser' · ×1
  • Unused dependency '@otplib/preset-browser' — Declared in warpgate-web/package.json but never imported anywhere in that package or its workspace members — no static import reaches it. Usually that is dead weight and attack surface, but two shapes are indistinguishable from source and are NOT dead: an optional or native peer that another dependency loads dynamically at runtime, and a package a build, docs or test step installs and invokes separately. Confirm which of the three this is before removing it.
SC1 · Supply-chain hygiene · NuGet dependencies are not locked · ×1
  • NuGet dependencies are not locked — No packages.lock.json and no central package management — restores aren't reproducible or pinned (SSDF PW.4.4). Enable <RestorePackagesWithLockFile>true</RestorePackagesWithLockFile> (commit the lockfile) or adopt Directory.Packages.props. Advisory — never scored.
Minor — 22 finding(s)
D31 · IaC & Container Security · Low IaC · ×10
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
D20 · ADR Quality · No ADRs found · ×1
  • No ADRs found — No ADRs found. No recognised ADR directory (`docs/adr/`, `docs/decisions/`, `adr/`, `docs/rfcs/`, an `ADR0001/` folder, or their siblings) exists anywhere in this tree. What was searched, so you can tell an empty log from a search that missed one: every directory under the tree (build output, dependencies and VCS metadata excepted), for a document that is either any non-index page inside a recognised ADR directory, whatever its name and however deeply nested (`docs/adr/use-postgres.md`, `docs/adr/2024/0001-x.md`); or a file anywhere whose name is ADR-shaped (`0001-use-postgres.md`, `adr-012-caching.md`); or, when neither turned anything up, a document carrying the decision-record signature (an "Architecture Decision Record" heading, or Status / Context / Decision / Consequences as section headings). A decision log that clears none of these — unnumbered files outside any recognised directory, without those headings — is not seen by this check and this row is then wrong. If that is your case, say so rather than renaming anything; otherwise, consider recording architectural decisions in `docs/adr/`.
D21 · Naming Consistency · Inconsistent abbreviation for the same concept. 'MembershipChgs' is used as a nested type name for specific SIDs, while 'MembershipChanges' is used as the property name for the collection. 'Chgs' is a non-standard abbreviation for 'Changes'. · ×1
  • Inconsistent abbreviation for the same concept. 'MembershipChgs' is used as a nested type name for specific SIDs, while 'MembershipChanges' is used as the property name for the collection. 'Chgs' is a non-standard abbreviation for 'Changes'. — Use 'MembershipChanges' consistently for both the property and the nested type (e.g., rename 'MembershipChgs' to 'MembershipChanges'). (symbols: Property: public AADJoin.Messages.JoinDeviceResponse.MembershipChgs.LocalSID, Property: public AADJoin.Messages.JoinDeviceResponse.MembershipChanges)
D21 · Naming Consistency · Typo in method name. 'DecryptCeritficate' contains a typo ('Ceritficate' instead of 'Certificate'). Other methods in the same class use correct spelling ('PemCsrToFile', 'PemCrtToFile'). · ×1
  • Typo in method name. 'DecryptCeritficate' contains a typo ('Ceritficate' instead of 'Certificate'). Other methods in the same class use correct spelling ('PemCsrToFile', 'PemCrtToFile'). — Rename 'DecryptCeritficate' to 'DecryptCertificate'. (symbols: Method: public string AADJoin.Utils.CryptoUtils.DecryptCeritficate(byte[], byte[], string), Method: public string AADJoin.Utils.CryptoUtils.PemCsrToFile(string, string), Method: public string AADJoin.Utils.CryptoUtils.PemCrtToFile(string, string), Method: public string AADJoin.Utils.CryptoUtils.PemCrtToPfxFile(string, System.Security.Cryptography.RSA, string, string))
D21 · Naming Consistency · Inconsistent casing for factory/parse methods. 'AuthResponse.fromString' uses lowercase 'f', while 'JoinDeviceResponse.FromString', 'TenantAuthResponse.FromString', and 'P2PCertificatesResponse.FromString' use PascalCase 'F'. · ×1
  • Inconsistent casing for factory/parse methods. 'AuthResponse.fromString' uses lowercase 'f', while 'JoinDeviceResponse.FromString', 'TenantAuthResponse.FromString', and 'P2PCertificatesResponse.FromString' use PascalCase 'F'. — Rename 'AuthResponse.fromString' to 'AuthResponse.FromString' to match the convention used by other message types. (symbols: Method: public AuthResponse AADJoin.Messages.AuthResponse.fromString(string), Method: public JoinDeviceResponse AADJoin.Messages.JoinDeviceResponse.FromString(string), Method: public TenantAuthResponse AADJoin.Messages.TenantAuthResponse.FromString(string), Method: public P2PCertificatesResponse AADJoin.Messages.P2PCertificatesResponse.FromString(string))
D21 · Naming Consistency · Inconsistent abbreviation for 'User'. The type and property are named 'Usr', while other credentials use 'User' (e.g., 'AADJoin.Creds.UserCreds', 'AADJoin.Messages.JoinDeviceRequest.User' is not present but 'UserCreds' is). 'Usr' is a non-standard abbreviation. · ×1
  • Inconsistent abbreviation for 'User'. The type and property are named 'Usr', while other credentials use 'User' (e.g., 'AADJoin.Creds.UserCreds', 'AADJoin.Messages.JoinDeviceRequest.User' is not present but 'UserCreds' is). 'Usr' is a non-standard abbreviation. — Rename 'Usr' to 'User' to align with standard naming conventions and other 'User' related types in the codebase. (symbols: Property: public AADJoin.Messages.JoinDeviceResponse.Usr, Property: public AADJoin.Messages.JoinDeviceResponse.Usr.Upn, Type: public AADJoin.Messages.JoinDeviceResponse.Usr)
D34 · Knowledge Freshness · Orphaned files with no living knowledge · ×1
  • Orphaned files with no living knowledge — 5 of 270 analysed file(s) have no living knowledge left — their last meaningful change has decayed away, so if one breaks, no one currently understands it (counted over production source files of roughly 2,400 bytes or more, excluding vendored, generated and example/demo trees and test files identified by path convention, largest first; 270 of the 496 production source files in this repository met that bar). None is large enough to earn a read-through of its own, so this row stands in for the per-file rows rather than raising one each — most significant first: warpgate-db-migrations/src/m00044_ticket_requests.rs, warpgate-sso/src/google_groups.rs, warpgate-db-migrations/src/m00050_password_policy.rs, warpgate-db-migrations/src/m00020_target_groups.rs, warpgate-db-migrations/src/m00025_ssh_client_auth.rs. Attach the read to the next change that touches one of them: have a second person review that change, and leave behind a short comment or test recording what the file is for, so the knowledge comes back at the cost of a change you were making anyway.
D36 · Supply-chain Provenance & Signing · REDACTED · ×1
  • REDACTED
D40 · Network Egress Confinement · No network policy · ×1
  • No network policy — No Kubernetes NetworkPolicy (or Cilium policy) found. Without one, every pod can talk to every other pod and reach out to the internet by default. Add a default-deny policy and open only the flows you need.
D41 · Kernel & Syscall Confinement · No seccomp profile · ×1
  • No seccomp profile — Workloads do not set a seccomp profile (RuntimeDefault or a Localhost profile). Seccomp blocks the syscalls a container never needs, shrinking the kernel attack surface a container escape would use.
D41 · Kernel & Syscall Confinement · No AppArmor/SELinux confinement · ×1
  • No AppArmor/SELinux confinement — Workloads declare no AppArmor or SELinux profile. A mandatory-access-control profile confines what a compromised container can touch on the host, complementing seccomp's syscall filter.
M2 · Architecture documentation · No ADRs · ×1
  • No ADRs — 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.
X5 · Nullable reference types · Nullable reference types not enabled everywhere · ×1
  • Nullable reference types not enabled everywhere — 0/1 NRT-eligible project(s) enable <Nullable>enable</Nullable> (projects targeting a pre-C#-8 framework are excluded — NRTs aren't available there). NRTs catch a whole class of null-deref bugs at compile time.
Minor — 1 finding(s)
D19 · Documentation Quality · XML-doc coverage · ×1
  • XML-doc coverage: AADJoin vendor/sspi/tools/aadjoin/AADJoin/AADJoin.csproj — AADJoin: 6 % XML-doc coverage (7/116).

Appendix B — Reproduction & audit trail

Every external tool invocation behind a deep-scan dimension — the tool, its captured version, the exact command, how many findings it yielded, and a link to the retained raw output. To reproduce any finding: check out the same commit and run the command shown (repo-relative — never an absolute scratch path). The complete raw scanner output is retained verbatim under artifacts/raw/ (indexed in artifacts/raw/index.json); per-invocation exit codes and wall-clock durations are in sidecar.json — kept out of this table so the rendered report stays byte-identical across runs of the same commit.

DimensionToolVersionCommandFindingsRaw output
D28 · Secrets (history)gitleaks—gitleaks detect --no-banner --config /opt/gitleaks-rules/watchdog-gitleaks.toml --report-format json --report-path /tmp/watchdog-gitleaks-3c8d4d682d594aa28d12b72d4d1807ff/history.json --exit-code 0 --source .0artifacts/raw/gitleaks-history.json
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-3c8d4d682d594aa28d12b72d4d1807ff/tree.json --exit-code 0 --source .0artifacts/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 .14artifacts/raw/semgrep.json
D30 · Dependency Vulnerabilitiesdotnet—dotnet list vendor/sspi/tools/aadjoin/AADJoin.sln package --vulnerable --include-transitive --format json18artifacts/raw/dotnet-vulnerable.json
D31 · IaC & Container Securitytrivy—trivy config --format json --quiet .23artifacts/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 1 file(s) — `warpgate-web/src/common/desktopCanvas.ts` — so the PII/GDPR sweep did not cover the unparsed regions of them; rows reported elsewhere in those files are real.0—
D42 · Runtime Threat Enforcementruntime-hardening—runtime-hardening: not applicable — The repository ships application workloads but no cluster-governance resources (CRDs, admission webhooks, or a committed policy engine). Runtime threat-detection (Falco/Tetragon) and admission control (Kyverno/OPA-Gatekeeper/PodSecurity) are cluster-OPERATOR controls owned by the platform, not shipped by an application repo/chart — nothing for this repo to assess.0—
D43 · Malicious Dependenciestrivy—trivy fs --scanners vuln --format json --quiet --severity CRITICAL,HIGH,MEDIUM,LOW --skip-dirs **/bin/** --skip-dirs **/obj/** . --skip-db-update0artifacts/raw/trivy-fs.json

Run 01a0ecb9-c7ba-7872-b3a7-d40bb823ad7a · every finding is also locatable in findings.md, and the complete scoring record (with exit codes + durations) in sidecar.json.

Downloadable artifacts

Machine-readable and reproducible from this commit + frozen rubric — drop them straight into a contract appendix, a CRA dossier, or a downstream SCA / VEX tool.

⬇ Findings, MITRE CWE-tagged .sarif⬇ Health changelog .md