Public report — harbor, published 6 Aug 2026. Concrete security findings (CVE IDs, secret matches, dependency versions) are hidden in this version; ask the repo owner for the full report.
Watchdog 06-08-2026 @ 08:44 UTC Public
Code Health Audit

Goharbor/harbor

No baseline yet — first run
48% At Risk

Large · 172,521 LoC · rebuild ~2.8 person-years · weakest lens: Accessibility (40%)

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

50/52dimensions tool-verifieddeterministic · confidence 1.0 · 2 LLM-assisted, advisory
523findings with an exact file:lineof 540 — the remainder are repo-wide signals (a dimension-level measurement, not a single line); open any file:line and verify
52/116dimensions across the health lenses172521 LoC — wide & deep

Executive summary

Read through the Production lens — the standard calibration. *Green* means good enough to run in production. The score is absolute and comparable across repos.

goharbor/harbor carries serious gaps (48%). Several issues below can materially affect correctness, security, or the cost of changing it — and propagate to everything that depends on it.

Most urgent: a critical security exposure was detected (see the Security & Compliance lens). Treat it as a priority regardless of the overall grade.

The area that most needs attention is Accessibility (40%) — it raises ongoing delivery and operational cost. Security (43%) is the next concern — exposure to security and compliance incidents is elevated.

Leadership focus, highest impact first: text alternative — alt on images (alt="" for purely decorative… (Text alternatives); Make custom controls keyboard-operable (role + tabindex + key handler) (Keyboard semantics); Give every control a programmatic label (a <label for> /… (Forms & labels).

For scale: Large (~172,521 production lines); rebuilding it from scratch would take roughly ~2.8 person-years (~1–6 engineers). Approximate, ±~30%.

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.
Accessibility 40% · 46% weightSecurity 43% · 25% weightDomain Modelling 59% · 14% weightReadiness 65% · 8% weightMaturity 65% · 4% weightCode Health 80% · 2% weightArchitecture 80% · 1% weight

Raise Accessibility 40 → 70 (the Healthy floor) ⇒ headline 48 → ~54.

Code composition — where the lines go
Tests 100%
Rebuild cost & value ~ Modeled — €130,000–€680,000
Cost to rebuild€130,000–€680,000 (1.3–4.2 person-years (2,245–7,123 h), ~1–6 engineers)
Domain complexityHigh — harder problems cost more per line
Quality factor0.7× (at 48% quality) — the last 20% of quality is most of the work
Size & shapeLarge · effort split not classified (source measured from disk; the effort-tier breakdown is a C#-only syntax walk)
Dead frontend code~52 LoC unreachable (3 file(s)) — that slice of this estimate buys code with zero runtime value; deleting it is the cheapest win in this report (the R7 card lists every file)

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

How we model this: boilerplate at a scaffolding rate + logic × domain High (×1.6) — CQRS, domain model, event-driven integration × a 0.7× 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
Add a text alternative — alt on images (alt="" for purely decorative ones), a title or aria-label on meaningful svg, an aria-label or inner fallback content on canvas, and a captions <track> on video.
+7.0 pts · Medium effort · Text alternatives
2
Make custom controls keyboard-operable (role + tabindex + key handler), drop positive tabindex, and give anchors a real href.
+7.0 pts · Medium effort · Keyboard semantics
3
Give every control a programmatic label (a <label for> / wrapping <label> / aria-label) and every button text — a placeholder is not a label.
+6.8 pts · Medium effort · Forms & labels

Diagnosis — what's actually going on

Value concentrated against a weak lens · High · Value at risk
This is a Large asset (~2.8 person-years to rebuild), and its weakest lens is Accessibility at 40%. The operational and business risk on an asset this size concentrates there — that's where remediation buys the most protection.
Evidence: valuation: Large, ~2.8 person-years rebuild (172,521 LoC) · weakest lens: Accessibility 40%
→ Direct remediation budget at Accessibility first — highest risk-reduction per euro on an asset this size.
The top fix pays for itself · High · Economics
The top-ranked fix costs roughly 3–10 engineer-days once. Not doing it costs about 4.2–28.2 engineer-days every year, paid as drag on the ~84,684 lines this team changes annually — a bill that arrives whether or not anyone books it. On those figures the fix breaks even in roughly 1–28 months and is free after that. Method, stated so this is not read as a quotation: debt from the ranked task's effort band; interest = annual changed lines (measured, annualised from the 90-day window) ÷ an ASSUMED 150–400 lines per engineer-day × the 2–5% drag implied by the code-quality signals; breaking point = debt ÷ annual interest. A modelled planning range built from measured inputs and one named assumption — not a quotation, a valuation, or a certified figure.
Evidence: D15 churn: 20,881 line(s) changed over a 90-day window ⇒ ~84,684/year · D1/D2/D4 code quality: averaging 7.2/10 ⇒ a 2–5% drag on each change · top-ranked remediation: Medium effort ⇒ about 3–10 engineer-day(s)
→ Do the top-ranked fix now if this code will still be yours in 28 months.
Root cause: an un-encapsulated domain · Medium · Root cause
18 findings across public setters, anemic types and primitive ids share one root cause — the domain layer doesn't protect its own invariants. Fixing the encapsulation pattern resolves them together, rather than chasing each finding.
Evidence: DM5 setters: 6 · DM4 anemic: 0 · DM2 primitive ids: 12
→ Address encapsulation as one pattern (private setters + behaviour + strongly-typed ids), not 100 separate findings.
Highest-leverage move · Medium · Leverage
Of everything flagged, the best return on effort is: Add a text alternative — alt on images (alt="" for purely decorative ones), a title or aria-label on meaningful svg, an aria-label or inner fallback content on canvas, and a captions <track> on video. The rest can wait behind it.
Evidence: priority ranking: top of 5 ranked by impact/effort
→ Add a text alternative — alt on images (alt="" for purely decorative ones), a title or aria-label on meaningful svg, an aria-label or inner fallback content on canvas, and a captions <track> on video.
A velocity tax on every change · Medium · Economics
The code-quality signals (complexity, duplication, cohesion) average 7.2/10, which acts as a tax on every change in the weaker areas: modifications there plausibly cost on the order of 2–5% more than in clean code, and the tax compounds as the codebase grows. (A modelled estimate, not a measured fact.)
Evidence: D1/D2/D4 code quality: averaging 7.2/10 across the code-quality signals actually measured
→ Pay it down where churn is highest — the hotspots — not everywhere; that's where the tax is actually paid.

Architecture — module dependency matrix

541 modules, 3337 dependencies — 2 dependency cycles, shown as the red cell(s) above the diagonal. 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.)

…bor/src/common/models…src/jobservice/logger…rbor/harbor/src/lib/q…/pkg/permission/types…bor/src/pkg/reg/model…rbor/src/pkg/registry…retention/policy/rule…or/src/jobservice/job…rbor/src/pkg/artifact…arbor/src/pkg/project…r/src/pkg/reg/adapter…or/src/pkg/repository…r/harbor/src/pkg/user…rc/controller/project…or/src/controller/tag…r/harbor/src/pkg/task…c/controller/artifact…ller/replication/flow…bor/src/pkg/retention…bor/src/pkg/scheduler…r/src/controller/scan…bor/src/pkg/scan/sbom…ontroller/p2p/preheat…r/harbor/src/pkg/oidc…rc/core/service/token…or/harbor/src/lib/orm…ontroller/replication…harbor/src/common/api…r/harbor/src/core/api…core/controllers…r/src/lib/cache/redis…/harbor/src/pkg/token…kg/token/claims/robot…c/pkg/token/claims/v2…r/middleware/security…c/server/v2.0/handler…or/harbor/src/testing…esting/controller/tag…rc/testing/jobservice…g/server/v2.0/handler…bor/src/common/models1…src/jobservice/logger2…rbor/harbor/src/lib/q3…/pkg/permission/types4…bor/src/pkg/reg/model5…rbor/src/pkg/registry6…retention/policy/rule7…or/src/jobservice/job8…rbor/src/pkg/artifact9…arbor/src/pkg/project10…r/src/pkg/reg/adapter11…or/src/pkg/repository12…r/harbor/src/pkg/user13…rc/controller/project14…or/src/controller/tag15…r/harbor/src/pkg/task16…c/controller/artifact17…ller/replication/flow18…bor/src/pkg/retention19…bor/src/pkg/scheduler20…r/src/controller/scan21…bor/src/pkg/scan/sbom22…ontroller/p2p/preheat23…r/harbor/src/pkg/oidc24…rc/core/service/token25…or/harbor/src/lib/orm26…ontroller/replication27…harbor/src/common/api28…r/harbor/src/core/api29…core/controllers30…r/src/lib/cache/redis31…/harbor/src/pkg/token32…kg/token/claims/robot33…c/pkg/token/claims/v234…r/middleware/security35…c/server/v2.0/handler36…or/harbor/src/testing37…esting/controller/tag38…rc/testing/jobservice39…g/server/v2.0/handler4012227253231121114632411453412622534111692111213411313113113111131122112213151131131151311221121113311311311113112211212122411113113113111131122112121128226226222262244224242141244124412444412448844858413113113111131122112121131131131111311221121211411311311113112211212113113113111131122112121131131131111311221121211213111141463333131131131111311221121211131131131113311221121212622722622226224422424213113113111131122112121+501 more modules (most-connected shown)

At a glance — Code Health · 80% · Strong

At a glance — Architecture · 80% · Strong

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

At a glance — Readiness · 65% · Adequate

At a glance — Security · 43% · Weak · gated by D28, D29, D31, D38

At a glance — Domain Modelling · 59% · Adequate · gated by DM2, DM5

At a glance — Accessibility · 40% · Weak · gated by AC1, AC4

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
A03:2021 — Injection50High / Critical
A06:2021 — Vulnerable & Outdated Components47High / Critical
A05:2021 — Security Misconfiguration46High / Critical
A02:2021 — Cryptographic Failures12High / Critical
A04:2021 — Insecure Design1Medium

Roadmap

Begin by adding text alternatives for all images, SVGs, and videos to address critical media accessibility gaps. Next, ensure all interactive elements and form controls are fully keyboard-operable and have programmatic labels, as these represent the largest volume of issues. Finally, enforce accessibility standards by integrating automated testing in CI and correcting page structure elements like language attributes and landmarks.

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

Do thisHelpsEffortDimension
Add a text alternative — alt on images (alt="" for purely decorative ones), a title or aria-label on meaningful svg, an aria-label or inner fallback content on canvas, and a captions <track> on video.+7.0 ptsMediumText alternatives
Make custom controls keyboard-operable (role + tabindex + key handler), drop positive tabindex, and give anchors a real href.+7.0 ptsMediumKeyboard semantics
Give every control a programmatic label (a <label for> / wrapping <label> / aria-label) and every button text — a placeholder is not a label.+6.8 ptsMediumForms & labels
Accessibility linting is already configured — assert with cypress-axe in tests, then gate axe/pa11y/Lighthouse in CI.+6.7 ptsMediumA11y enforcement
Declare <html lang>, a document <title> and a <main> landmark, keep headings in order, leave zoom enabled, title iframes and drop meta-refresh.+6.3 ptsMediumPage structure
Resolve the 49 High finding(s) in Static Analysis (SAST) — start with CI.yml (18), build-package.yml (12), publish_release.yml (7).+3.1 ptsMediumStatic Analysis (SAST)
Resolve the 10 Secret finding(s) in Secrets (history) — start with private_key.pem (7), server.key (2), values.yaml.+2.9 ptsMediumSecrets (history)
Resolve the 1 Leaked secret finding(s) in Secret Scanning — start with server.key.+0.9 ptsLowSecret Scanning

File quality

Per-file score 0–10 — a quality signature. Of 216 files carrying findings, judged against the Production bar: 2% slop · 60% mixed · 38% near-clean.

FileScoreBandWorst signal
src/portal/package-lock.json0.0SlopOSV Dependency Vulnerabilities: Critical CVE: [GHSA redacted]
src/portal/app-swagger-ui/package-lock.json2.3SlopOSV Dependency Vulnerabilities: High CVE: [GHSA redacted]
make/photon/db/Dockerfile.base3.7SlopIaC & Container Security: High IaC: DS-0002
make/photon/prepare/Dockerfile.base3.7SlopIaC & Container Security: High IaC: DS-0002
make/photon/valkey/Dockerfile.base3.7SlopIaC & Container Security: High IaC: DS-0002
tools/migrate_chart/Dockerfile4.1MixedIaC & Container Security: High IaC: DS-0002
tools/spectral/Dockerfile4.1MixedIaC & Container Security: High IaC: DS-0002
tools/swagger/Dockerfile4.1MixedIaC & Container Security: High IaC: DS-0002
src/jobservice/server.key4.4MixedSecret Scanning: Leaked secret: private-key
.github/workflows/CI.yml4.4MixedStatic Analysis (SAST): High: github-actions-mutable-action-tag
.github/workflows/build-package.yml4.4MixedStatic Analysis (SAST): High: github-actions-mutable-action-tag
.github/workflows/publish_release.yml4.4MixedStatic Analysis (SAST): High: github-actions-mutable-action-tag
.github/workflows/codeql-analysis.yml5.1MixedStatic Analysis (SAST): High: github-actions-mutable-action-tag
make/photon/common/Dockerfile5.1MixedIaC & Container Security: High IaC: DS-0002
make/photon/core/Dockerfile.base5.1MixedIaC & Container Security: High IaC: DS-0002
make/photon/exporter/Dockerfile.base5.1MixedIaC & Container Security: High IaC: DS-0002
make/photon/log/Dockerfile.base5.1MixedIaC & Container Security: High IaC: DS-0002
make/photon/nginx/Dockerfile.base5.1MixedIaC & Container Security: High IaC: DS-0002
make/photon/prepare/Dockerfile5.1MixedIaC & Container Security: High IaC: DS-0002
make/photon/registry/Dockerfile.base5.1MixedIaC & Container Security: High IaC: DS-0002

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. 50 of 52 evaluated dimensions are computed purely by tools and static analysis (confidence 1.0); 2 documentation/naming judgement(s) are LLM-assisted and labelled advisory. Overall confidence is 0.7 — 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 — 52 dimensions across the health lenses
D1D2D3D4D13D15D16D19D21D28D29D31D32D33D34D35D36D37D38AC1AC2AC3AC4AC5AC6AC7AX5DM1DM2DM4DM5DM7DM8M1M2M3M4P1P3P4P5P6R1R10R2R3R4R5R6R7R8R9

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, 523 of 540 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
jscpdCode duplication✓ deterministic
Coverage (coverlet / dotnet-coverage)Line & branch coverage10.0.302✓ deterministic
NuGet / dotnetOutdated, vulnerable & deprecated dependencies10.0.302✓ 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 019fd63e-b385-7150-9723-89619e087491.

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.

  • D30 Dependency Vulnerabilities — scanner not present in this environment — The backing tool was not installed where this scan ran, so this dimension was not scored. Install the tool (or run in the hosted environment, where it is always present) for a graded result.

Repo exclusion declarations: 8 pattern(s) declared (.gitattributes linguist-generated/vendored, .editorconfig generated_code) excluded 0 source file(s) from code-quality scoring. Declarations are the repo's own visible statement that a tree is machine-written or vendored — auditable in any diff, honored by GitHub the same way.

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 (jscpd) — 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.
  • 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").
  • 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.
  • D16 Bus Factor: Bus-factor is a time-decayed model of commit attribution (who has recently, repeatedly worked a file), not comprehension — pairing, review and reading-without-committing spread knowledge it can't see; bot commits and shared accounts still distort it.
  • 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.
  • 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.
  • 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").
  • 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.
  • D32 Data Compliance (PII/GDPR): PII/GDPR signals are heuristic pattern matches in code — they flag likely handling concerns, not legal compliance, and cannot trace where data actually flows at runtime.
  • D33 JS/npm Dependency Vulnerabilities: JS/npm CVE matching reads package manifests and lockfiles — risk from how a dependency is used, and advisories not yet published, fall outside this scan.
  • 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.
  • AC1 Text alternatives: Alt-text is detected structurally — the scan sees that an alternative EXISTS, not whether it meaningfully describes the image, and decorative-vs-missing is judged by attribute shape; runtime-injected images and a non-role=img decorative svg are out of scope. This is accessibility readiness, never a WCAG conformance claim.
  • AC2 Forms & labels: Label association is read from static markup — a label wired up at runtime (JS-set aria-labelledby, framework-injected ids) reads as missing, a present label says nothing about whether its text is correct. A known UI-library field component (e.g. a JSX <TextField>) is now checked conservatively — flagged only when it carries NO label/aria-label/aria-labelledby/id/name — but wrapper/context-labelled libraries (Chakra/Radix FormControl+FormLabel) aren't statically visible (possible false positive) and non-JSX lowercased components are still skipped. A clean result is "no unlabelled native control found", not a labelling proof.
  • AC3 Page structure: Page structure is read from the static markup tree — landmarks, headings and lang injected at runtime aren't seen, heading ORDER is checked structurally (not against the rendered visual hierarchy), and lang/title/main fire only on full documents, never partials, and the data-table check sees header-cell presence (a <th> exists), not whether each header correctly associates with its cells. Static readiness, not conformance.
  • AC4 Keyboard semantics: Keyboard semantics are inferred from markup attributes — interactivity wired purely in script, focus managed at runtime, and component-level handlers are invisible. A clean result means "no static keyboard-trap shape", not a keyboard-operability proof.
  • AC5 ARIA correctness: ARIA correctness is checked against the static role/attribute shape — roles/attributes set dynamically aren't seen, a valid role says nothing about whether it matches the element's real behaviour, and required-state checks are suppressed when a JSX spread could supply them.
  • AC6 Visual & motion safety: Contrast and motion safety are PARTIAL by construction — literal colours (hex/rgb/hsl/named) in inline styles, in-repo <style> blocks, in-repo .css files, var() tokens, Tailwind neutral utilities and CSS-in-JS top-level declarations are read (same-rule/same-element colour+background pairs only); computed/runtime/theme colour, external-CDN stylesheets, CSS-in-JS dynamic (${…}) and nested-selector colours, cross-element pairs and image contrast stay out of reach, so a clean result is bounded by what the static CSS itself shows.
  • AC7 A11y enforcement: Enforcement is scored from in-repo config/CI evidence only — an a11y gate enforced in external tooling with no in-repo trace can't be credited, and a configured linter is presence, not proof the rules actually run or block a merge.
  • DM4 Rich vs anemic 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.
  • 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 (3): D19, D21, M4 (model: Local LLM). For these, a model reads a bounded sample and sets the numeric score (documentation, ADR quality, naming, comment value, onboarding) — D25 sets the ADR-conformance fraction over sampled code, D22 judges API accuracy over a sample. These 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 Complexity7.0 / 10Strong✓ 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: DocumentedVerifiedPrevented · effective 7.0 / 10 · rule-coverage 100% · ceiling Prevented

70 method(s) exceeded the cyclomatic complexity threshold of 15; the worst was projectAPI.CreateProject at 38.

projectAPI.CreateProject (cyclomatic 38)src/server/v2.0/handler/project.go:102
controller.deleteDeeply (cyclomatic 36)src/controller/artifact/controller.go:357
GarbageCollector.sweep (cyclomatic 35)src/jobservice/job/impl/gc/garbage_collection.go:293
controller.Create (cyclomatic 31)src/controller/member/controller.go:122
Job.Run (cyclomatic 29)src/pkg/scan/job.go:144

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

What to do

  1. Resolve the 1 projectAPI.CreateProject (cyclomatic 38) finding(s) in Cyclomatic Complexity — start with project.go. — One of this dimension's main actionable groups (1 warning-level).
  2. Resolve the 1 controller.deleteDeeply (cyclomatic 36) finding(s) in Cyclomatic Complexity — start with controller.go. — One of this dimension's main actionable groups (1 warning-level).
  3. Resolve the 1 GarbageCollector.sweep (cyclomatic 35) finding(s) in Cyclomatic Complexity — start with garbage_collection.go. — One of this dimension's main actionable groups (1 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 Complexity5.0 / 10Weak✓ 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: DocumentedVerifiedPrevented · effective 5.0 / 10 · rule-coverage 100% · ceiling Prevented

162 method(s) exceeded the cognitive complexity threshold of 15; the worst was GarbageCollector.sweep at 124.

adapter.FetchArtifacts (cognitive 40) · ×2src/pkg/reg/adapter/gitlab/adapter.go:100
adapter.FetchArtifacts (cognitive 21) · ×2src/pkg/reg/adapter/harbor/v1/adapter.go:43
selector.Select (cognitive 20) · ×2src/lib/selector/selectors/severity/selector.go:47
adapter.listRepositories (cognitive 16) · ×2src/pkg/reg/adapter/jfrog/adapter.go:217
GarbageCollector.sweep (cognitive 124)src/jobservice/job/impl/gc/garbage_collection.go:293

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

What to do

  1. Resolve the 2 adapter.FetchArtifacts (cognitive 40) finding(s) in Cognitive Complexity — start with adapter.go, artifact_registry.go. — One of this dimension's main actionable groups (2 warning-level).
  2. Resolve the 2 adapter.FetchArtifacts (cognitive 21) finding(s) in Cognitive Complexity — start with adapter.go (2). — One of this dimension's main actionable groups (2 warning-level).
  3. Resolve the 2 selector.Select (cognitive 20) finding(s) in Cognitive Complexity — start with selector.go (2). — One of this dimension's main actionable groups (2 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 Classes9.9 / 10Exemplary✓ 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: DocumentedVerifiedPrevented · effective 9.9 / 10 · rule-coverage 100% · ceiling Prevented

4 god class(es) detected.

FileTooLong: scan/base_controller.go · ×3src/controller/scan/base_controller.go:0
TooManyMethods: FakeOrmersrc/testing/lib/orm/orm.go:26

✓ On the Gold path — maintain.

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

D4 · Code Duplication9.6 / 10Exemplary✓ 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: DocumentedVerifiedPrevented · effective 9.6 / 10 · rule-coverage 100% · ceiling Verified

123 duplicated block group(s) detected.

Duplicated block (11 lines × 2) · ×18src/controller/artifact/processor/image/manifest_v2.go:103
Duplicated block (12 lines × 2) · ×14src/common/http/client.go:212
Duplicated block (9 lines × 2) · ×13src/controller/proxy/controller.go:310
Duplicated block (10 lines × 2) · ×11src/controller/event/metadata/tag.go:39
Duplicated block (8 lines × 2) · ×11src/controller/event/topic.go:177

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

✓ On the Gold path — maintain.

Detailed fixes: d4_recommendation.md · top locations in Appendix A, every location in findings.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: DocumentedVerifiedPrevented · effective 5.0 / 10 · rule-coverage 100% · ceiling Prevented

1 secret(s) detected.

Leaked secret: private-keysrc/jobservice/server.key:1

What to do

  1. Resolve the 1 Leaked secret finding(s) in Secret Scanning — start with server.key. — 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.

D15 · Churn × Complexity Hotspots10.0 / 10Exemplary✓ 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: DocumentedVerifiedPrevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Documented

Top hotspots: src/server/middleware/repoproxy/proxy.go (3×22=66); src/pkg/auditext/event/member/member.go (2×21=42); src/pkg/registry/client.go (2×16=32)

Hotspot: src/server/middleware/repoproxy/proxy.go · ×4src/server/middleware/repoproxy/proxy.go

✓ On the Gold path — maintain.

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

D16 · Bus Factor9.2 / 10Exemplary✓ Tool-verified

What it measures: Whether knowledge is concentrated in too few people (the "bus factor").

Method: Living knowledge per author via time-decayed commit attribution (6-month half-life, focus weighting) across largest source files. Deterministic, avoids blame's mechanical-refactor false positives.

Maturity: DocumentedVerifiedPrevented · effective 9.2 / 10 · rule-coverage 100% · ceiling Documented

59 source file(s) have their living knowledge concentrated in one author (≥90% of recent, decayed contribution). The largest is src/portal/src/app/base/project/project-detail/project-detail.component.ts.

Off-boarding risk: anonymized user #1 · ×6
Further sole-owners (lower concentration)

✓ On the Gold path — maintain.

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

D19 · Documentation Quality / 10Strong◐ 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: DocumentedVerifiedPrevented · effective Strong / 10 · rule-coverage 100% · ceiling Documented

Harbor's documentation is comprehensive and well-structured: a strong README (1014 words) with CI badges, community meeting schedule link, and an OCI chart-museum migration tool; architecture/README.md files covering the full outline (Harbor; Features; Architecture; API; Install & Run; Verifying Release Signatures; Quick Verification; Install Cosign (v2.0+); Verify signature; OCI Distribution Conformance Tests; Compatibility; Community; Demos; Partners and Users; Security; Security Audit; Reporting security vulnerabilities; License; Fossa Status) with a detailed E2E test guide, the UI README covering Node version, proxy config, and development server start-up, and a backup-restore scripts contrib doc that is clipped but is clearly present in its outline. The tools/swagger templates README gives excellent rationale for swagger customization plus an example walk-through. There are no visible gaps or missing sections among the named docs. The documentation is comprehensive and well-structured for a Helm chart deployment repository: two README.md files (one per Harbor version) plus an architecture/signature-verification doc cover the topic. Both charts are written in markdown with clear headings, precise prerequisites, installation steps, and troubleshooting guidance; the signature-verification doc also includes a full table of contents and a concrete verification example. The shared notes about master branch stability and cross-references to external Harbor issues channels are consistent across docs.

The 'Install the chart' section is present in the outline but not shown in the visible text, so whether it actually installs the chart rather than just describing its configuration options cannot be confirmed.src/pkg/chart/testdata/harbor-schema2/README.md

What to do

  1. Resolve the 1 The 'Install the chart' section is present in the outline but not shown… finding(s) in Documentation Quality — start with README.md. — One of this dimension's main actionable groups (1 recommendation-level).

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

D21 · Naming Consistency / 10Exemplary◐ 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: DocumentedVerifiedPrevented · effective Exemplary / 10 · rule-coverage 100% · ceiling Verified

0 naming inconsistencies across 0 sampled symbols.

✓ On the Gold path — maintain.

Detailed fixes: d21_recommendation.md.

D28 · Secrets (history)0.0 / 10Critical✓ Tool-verified

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

Method: Git-history secret scan via gitleaks detect over full history in an isolated checkout; each match flagged High. Exhaustive; degrades cleanly when tool absent.

Maturity: DocumentedVerifiedPrevented · effective 0.0 / 10 · rule-coverage 100% · ceiling Documented

14 finding(s): 0 critical, 14 high, 0 medium, 0 low. Remediation for historically-committed secrets is credential rotation — they remain in history regardless of later deletion.

Secret: private-key · ×10make/photon/prepare/templates/core/private_key.pem:1detected by gitleaks finding
Rotate the exposed credentials — git history can't be un-committed

What to do

  1. Resolve the 10 Secret finding(s) in Secrets (history) — start with private_key.pem (7), server.key (2), values.yaml. — One of this dimension's main actionable groups (10 issue-level).
  2. Resolve the 1 Rotate the exposed credentials finding(s) in Secrets (history). — One of this dimension's main actionable groups (1 recommendation-level).

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

D29 · Static Analysis (SAST)0.0 / 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: DocumentedVerifiedPrevented · effective 0.0 / 10 · rule-coverage 100% · ceiling Documented

73 finding(s): 0 critical, 49 high, 13 medium, 11 low.

High: dependabot-missing-cooldown · ×49.github/dependabot.yml:10detected by semgrep finding
Medium: math-random-usedsrc/controller/registry/controller.go:19detected by semgrep finding

What to do

  1. Resolve the 49 High finding(s) in Static Analysis (SAST) — start with CI.yml (18), build-package.yml (12), publish_release.yml (7). — One of this dimension's main actionable groups (49 issue-level).
  2. Resolve the 1 Medium finding(s) in Static Analysis (SAST) — start with controller.go. — One of this dimension's main actionable groups (1 warning-level).

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

D31 · IaC & Container Security0.0 / 10Critical✓ Tool-verified

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

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

Maturity: DocumentedVerifiedPrevented · effective 0.0 / 10 · rule-coverage 100% · ceiling Documented

62 finding(s): 0 critical, 23 high, 38 medium, 1 low.

High IaC: DS-0002 · ×21make/photon/common/Dockerfiledetected by trivy finding
Medium IaC: DS-0013 · ×25make/photon/portal/Dockerfiledetected by trivy finding

What to do

  1. Resolve the 25 Medium IaC finding(s) in IaC & Container Security — start with Dockerfile (13), Dockerfile.base (9), Dockerfile.binary (3). — One of this dimension's main actionable groups (25 warning-level).
  2. Resolve the 21 High IaC finding(s) in IaC & Container Security — start with Dockerfile.base (15), Dockerfile (6). — One of this dimension's main actionable groups (21 issue-level).

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

D32 · Data Compliance (PII/GDPR)9.0 / 10Exemplary✓ Tool-verified

What it measures: Likely personal-data (PII / GDPR) handling concerns — logging or storing data without safeguards.

Method: Heuristic PII/GDPR pattern scan via semgrep across the repo, using Watchdog's own ruleset (personal data reaching log/console sinks, URLs and query strings, or unprotected browser storage); matches map to severity and a 0-10 wide normalizer. NotApplicable when the scan runs and detects no PII/GDPR surface (no unearned 10); reported LOUDLY as a measurement gap, never as not-applicable, if the ruleset is missing from the analyzer image. Exhaustive, advisory-leaning; degrades on parse failure.

Maturity: DocumentedVerifiedPrevented · effective 9.0 / 10 · rule-coverage 100% · ceiling Documented

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

Medium: watchdog-personal-data-in-urlsrc/portal/src/app/base/password-setting/password-setting.service.ts:59detected by semgrep finding

✓ On the Gold path — maintain.

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

D33 · JS/npm Dependency Vulnerabilities10.0 / 10Exemplary○ Nothing flagged

What it measures: Whether JavaScript/npm dependencies have known published vulnerabilities (CVEs) — the npm ecosystem's biggest risk.

Method: JS/npm CVE scan via trivy fs --scanners vuln over JS manifests (package.json/yarn.lock/pnpm-lock/bun.lockb); 0-10 tight normalizer. NotApplicable without JS manifests. Exhaustive, deterministic.

Maturity: DocumentedVerifiedPrevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Documented

No known-vulnerable JS/npm dependencies.

✓ On the Gold path — maintain.

Detailed fixes: d33_recommendation.md.

D34 · Knowledge Freshness6.8 / 10Adequate✓ 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: DocumentedVerifiedPrevented · effective 6.8 / 10 · rule-coverage 100% · ceiling Documented

225 of 713 significant source file(s) are orphaned — their living knowledge has decayed to nothing, so no one currently understands them. The largest is src/server/v2.0/handler/replication.go.

Orphaned knowledgesrc/server/v2.0/handler/replication.go
Further orphaned files (smaller)

What to do

  1. Resolve the 1 Orphaned knowledge finding(s) in Knowledge Freshness — start with replication.go. — One of this dimension's main actionable groups (1 issue-level).
  2. Resolve the 1 Further orphaned files (smaller) finding(s) in Knowledge Freshness. — One of this dimension's main actionable groups (1 recommendation-level).

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

D35 · Change Coupling10.0 / 10Exemplary✓ 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; coupling through a build step, config, or non-source file isn't seen.

Maturity: DocumentedVerifiedPrevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Documented

Strongest change-coupling: const.go↔model.go 85%; project.go↔project_metadata.go 80%; metadatalist.go↔model.go 70%

Boundary-crossing change coupling: const.go ↔ model.go · ×2src/common/const.go
Change coupling: metadatalist.go ↔ model.gosrc/lib/config/metadata/metadatalist.go

✓ On the Gold path — maintain.

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

D36 · Supply-chain Provenance & Signing5.0 / 10Adequate✓ 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: DocumentedVerifiedPrevented · effective 5.0 / 10 · rule-coverage 100% · ceiling Documented

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

Unpinned build actions
PR-triggered workflow without a permissions block
Secret passed as a command-line argument
No SBOM

What to do

  1. Resolve the 1 Unpinned build actions finding(s) in Supply-chain Provenance & Signing. — One of this dimension's main actionable groups (1 warning-level).
  2. Resolve the 1 PR-triggered workflow without a permissions block finding(s) in Supply-chain Provenance & Signing. — One of this dimension's main actionable groups (1 warning-level).
  3. Resolve the 1 Secret passed as a command-line argument 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: DocumentedVerifiedPrevented · 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.

D38 · OSV Dependency Vulnerabilities0.0 / 10Critical✓ Tool-verified

What it measures: Whether dependencies have known published vulnerabilities (CVEs) per the OSV database — read natively from whatever lockfile the repository ships (Cargo, npm, Go, Python, Maven, RubyGems, …). D33 and D30 add ecosystem-specific scanners on top for npm and .NET.

Method: Multi-ecosystem dependency-CVE scan via osv-scanner --recursive (queries the osv.dev database + parses lockfiles natively across ecosystems: npm package-lock/yarn/pnpm/bun, Go go.mod, Rust Cargo.lock, Maven/Gradle pom.xml/gradle.lockfile, PyPI requirements.txt/poetry.lock/Pipfile.lock, Composer composer.lock, RubyGems Gemfile.lock, Hex mix.lock, pub pubspec.lock, Swift Package.resolved); severity tally (Critical/High/Medium/Low) to 0-10 tight normalizer (8.0). NotApplicable only when the repo declares no supported non-.NET dependency lockfile (a NuGet-only repo stays NotApplicable — .NET CVEs are D30's domain); coverage needs a resolved lockfile. Additive to D33 (trivy fs); exhaustive + deterministic, DB kept fresh.

Maturity: DocumentedVerifiedPrevented · effective 0.0 / 10 · rule-coverage 100% · ceiling Documented

47 finding(s): 3 critical, 28 high, 12 medium, 4 low.

High CVE: [GHSA redacted] · ×25src/portal/package-lock.jsondetected by osv-scanner finding
Critical CVE: [GHSA redacted] · ×3src/portal/package-lock.jsondetected by osv-scanner finding
High vulnerability: [GHSA redacted] · ×3src/portal/package-lock.jsondetected by osv-scanner finding
Medium CVE: [GHSA redacted] · ×11src/portal/package-lock.jsondetected by osv-scanner finding
Medium vulnerability: [GHSA redacted]src/portal/package-lock.jsondetected by osv-scanner finding

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

What to do

  1. Resolve the 25 High CVE finding(s) in OSV Dependency Vulnerabilities — start with package-lock.json (25). — One of this dimension's main actionable groups (25 issue-level).
  2. Resolve the 3 Critical CVE finding(s) in OSV Dependency Vulnerabilities — start with package-lock.json (3). — One of this dimension's main actionable groups (3 issue-level).
  3. Resolve the 3 High vulnerability finding(s) in OSV Dependency Vulnerabilities — start with package-lock.json (3). — One of this dimension's main actionable groups (3 issue-level).

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

Frontend & cross-cutting dimensions

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

AC1 · Text alternatives1.4 / 10Critical✓ Tool-verified

Other · Accessibility — Whether non-text content carries a text alternative — img/area/input[type=image] have alt, a meaningful svg has a title or aria-label, video has a captions track, and object/embed/canvas have a name or fallback content. Static markup readiness, not a WCAG conformance claim.

Method: Static markup-model scan: every img/area/input[type=image] checked for alt, svg[role=img] for a title/aria-label, video for a captions <track>. Components skipped, spreads suppressed. Deterministic, hard fact per element.

  • An image with no alt (and no aria-label/aria-labelledby) is unreadable to assistive tech. Add alt — alt="" if it's purely decorative. (×10) — artifact-label.component.html:6, artifact-label.component.html:18, artifact-list-tab.component.html:266, …

What to do

  • Add a text alternative — alt on images (alt="" for purely decorative ones), a title or aria-label on meaningful svg, an aria-label or inner fallback content on canvas, and a captions <track> on video.
AC2 · Forms & labels5.1 / 10Adequate✓ Tool-verified

Other · Accessibility — Whether form controls have a programmatic label (an associated label, aria-label or aria-labelledby), buttons have text, links have an accessible name, fieldsets have a non-empty legend, known UI-library field components carry a label prop, and a placeholder isn't used as the only label. Static markup readiness, not a WCAG conformance claim.

Method: Static markup-model scan: inputs/selects/textareas checked for an associated label[for]/wrapping label/aria-label/aria-labelledby (per document), buttons for accessible text, fieldsets for a legend; placeholder-only labelling flagged. Deterministic, hard fact per control.

  • This control has only a placeholder — a placeholder is not a label (it vanishes on input and many AT ignore it). Add a <label for>, a wrapping <label>, or aria-label. (×6) — sign-in.component.html:78, sign-in.component.html:112, security.component.html:103, …
  • This control has no associated label. Add a <label for> / wrapping <label> / aria-label / aria-labelledby so assistive tech can name it. (×19) — account-settings-modal.component.html:175, account-settings-modal.component.html:270, set-job.component.html:85, …

What to do

  • Give every control a programmatic label (a <label for> / wrapping <label> / aria-label) and every button text — a placeholder is not a label.
AC3 · Page structure7.0 / 10Adequate✓ Tool-verified

Other · Accessibility — Whether pages declare a language (well-formed BCP-47) and a non-empty title, expose exactly one main landmark and a sane heading order with non-empty headings, keep zoom enabled, title their iframes, give data tables header cells, and avoid meta-refresh. Static markup readiness, not a WCAG conformance claim.

Method: Static markup-model scan: html lang, document <title>, a main landmark and heading order on full documents only, plus zoom-disabling viewports, untitled iframes and meta-refresh anywhere. Deterministic, per structural checkpoint.

  • Skipping heading levels breaks the document outline assistive tech relies on. Don't jump levels — increase by at most one. — project-detail.component.html:50
  • A <table> with data cells but no <th> gives assistive technology no way to associate cells with their headers. Mark the header row/column cells as <th> (with a scope). — values.component.html:45
  • The page declares no language, so assistive tech can't pick the right pronunciation. Add lang (e.g. lang="en"). — index.html:2
  • No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>. — index.html:2

What to do

  • Declare <html lang>, a document <title> and a <main> landmark, keep headings in order, leave zoom enabled, title iframes and drop meta-refresh.
AC4 · Keyboard semantics1.0 / 10Critical✓ Tool-verified

Other · Accessibility — Whether interactive behaviour is keyboard-reachable — no click handler on a non-interactive element lacking a role, tabindex and key handler, no positive tabindex, no href-less anchor, no placeholder-href (#/javascript) link acting as a button. Static markup readiness, not a WCAG conformance claim.

Method: Static markup-model scan: click handlers on non-interactive elements lacking role+tabindex+key handler, positive tabindex values, and href-less anchors. Components skipped, spreads suppressed. Deterministic, hard fact per element.

  • An <a> with no href, role or tabindex isn't focusable or keyboard-activatable. Give it a real href, or use a <button> for an action. (×15) — harbor-shell.component.html:168, replication-tasks.component.html:5, project-detail.component.html:3, …
  • A positive tabindex forces a manual tab order that fights the DOM and is fragile. Use tabindex="0" (or restructure the DOM). — about-dialog.component.html:15

What to do

  • Make custom controls keyboard-operable (role + tabindex + key handler), drop positive tabindex, and give anchors a real href.
AC5 · ARIA correctness10.0 / 10Exemplary○ Nothing flagged

Other · Accessibility — Whether ARIA is used correctly — valid non-abstract roles, the ARIA state a role requires, valid (non-misspelled) aria-* attribute names, in-enum values for token-typed aria-* attributes, and no aria-hidden on (or wrapping) a focusable element. Static markup readiness, not a WCAG conformance claim.

Method: Static markup-model scan: role values checked against the WAI-ARIA role set (abstract/invalid flagged), required ARIA state for a role, and aria-hidden on a focusable element. Deterministic, role/attribute level.

AC6 · Visual & motion safety10.0 / 10Exemplary○ Nothing flagged

Other · Accessibility — Whether focus outlines aren't removed without a replacement, motion respects prefers-reduced-motion, and literal CSS colour pairs meet contrast — PARTIAL: inline styles, in-repo <style> blocks, in-repo .css files, var() tokens, Tailwind neutral utilities and CSS-in-JS literals are read (hex/rgb/hsl/named), never computed/runtime/external-CDN colour. Static markup readiness, not a WCAG conformance claim.

Method: Static markup/CSS scan: inline outline:none/0, literal inline colour/background contrast against the 4.5:1 AA floor, and <style>-block animation without a prefers-reduced-motion guard. Deterministic but PARTIAL — only inline styles and in-repo CSS literals are visible.

AC7 · A11y enforcement6.0 / 10Adequate✓ Tool-verified

Other · Accessibility — Whether accessibility is ENFORCED in the toolchain — an accessibility checker configured over the markup (an a11y lint rule set, e.g. eslint-plugin-jsx-a11y or vuejs-accessibility where the project lints JavaScript) and an automated accessibility assertion wired into tests or CI (axe/pa11y/Lighthouse or an equivalent) — on the Documented→Verified→Prevented ladder.

Method: Repo config/CI scan: an accessibility checker configured over the markup (an a11y lint rule set such as eslint-plugin-jsx-a11y / vuejs-accessibility where JavaScript is linted) and an automated accessibility assertion in tests or CI (axe/pa11y/Lighthouse or equivalent), graded on the Documented→Verified→Prevented rungs. Deterministic, presence/rung detection.

  • An a11y linter is configured (Documented) but there's no automated a11y test or CI gate. Add cypress-axe to verify at runtime, then gate it in CI.

What to do

  • Accessibility linting is already configured — assert with cypress-axe in tests, then gate axe/pa11y/Lighthouse in CI.
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.

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

Other · Domain Modelling — Whether aggregates reference each other by identity (id) rather than by direct object reference — the core DDD consistency-boundary rule.

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 ids3.0 / 10Weak✓ Tool-verified

Other · Domain Modelling — How much of the domain uses strongly-typed ids vs raw Guid/string/int — adoption curve, not all-or-nothing.

Method: Roslyn (DDD-gated): strongly-typed id adoption on domain entities/events; raw Guid/int/string ids counted versus wrapped types. 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.

  • `Policy.ID` is a raw `int64` — give it a strongly-typed id: a dedicated single-field type wrapping the `int64`, in whatever form your language spells that. (×2) — model.go:33, model.go:30
  • `Policy.ProjectID` is a raw `int64` — give it a strongly-typed id: a dedicated single-field type wrapping the `int64`, in whatever form your language spells that. — model.go:33
  • `Schema.ID` is a raw `int64` — give it a strongly-typed id: a dedicated single-field type wrapping the `int64`, in whatever form your language spells that. — policy.go:61
  • `Schema.ProjectID` is a raw `int64` — give it a strongly-typed id: a dedicated single-field type wrapping the `int64`, in whatever form your language spells that. — policy.go:65
  • `Schema.ProviderID` is a raw `int64` — give it a strongly-typed id: a dedicated single-field type wrapping the `int64`, in whatever form your language spells that. — policy.go:66
  • `Instance.ID` is a raw `int64` — give it a strongly-typed id: a dedicated single-field type wrapping the `int64`, in whatever form your language spells that. — instance.go:44
  • `Project.ProjectID` is a raw `int64` — give it a strongly-typed id: a dedicated single-field type wrapping the `int64`, in whatever form your language spells that. — project.go:44
  • `Project.OwnerID` is a raw `int` — give it a strongly-typed id: a dedicated single-field type wrapping the `int`, in whatever form your language spells that. — project.go:45
  • `Project.RegistryID` is a raw `int64` — give it a strongly-typed id: a dedicated single-field type wrapping the `int64`, in whatever form your language spells that. — project.go:56
  • `Quota.ID` is a raw `int64` — give it a strongly-typed id: a dedicated single-field type wrapping the `int64`, in whatever form your language spells that. — quota.go:28
  • `Quota.ReferenceID` is a raw `string` — give it a strongly-typed id: a dedicated single-field type wrapping the `string`, in whatever form your language spells that. — quota.go:31

What to do

  • Adopt strongly-typed ids across the domain — finish the migration or document the boundary; primitive ids invite transposed-argument bugs.
DM4 · Rich vs anemic model10.0 / 10Exemplary✓ Tool-verified

Other · Domain Modelling — Whether aggregates/entities carry the behaviour that protects their invariants, rather than being data bags driven by external services.

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 state2.7 / 10Weak✓ Tool-verified

Other · Domain Modelling — Whether entities protect their state (private/init-only setters) instead of exposing public setters that bypass invariants. Softened when a rehydration framework (Marten/EF) is present.

Method: Roslyn (DDD-gated): public setters on entities detected; score softened when Marten/EF rehydration frameworks present. Deterministic, framework-aware.

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

  • `Policy` exposes publicly writable state (ID, Name, Description, Creator, SrcRegistry, DestRegistry, …). — model.go:32
  • `Policy` exposes publicly writable state (ID, Name, Description, ProjectID, TargetsDB, Targets, …). — model.go:29
  • `Schema` exposes publicly writable state (ID, Name, Description, ProjectID, ProviderID, Filters, …). — policy.go:60
  • `Instance` exposes publicly writable state (ID, Name, Description, Vendor, Endpoint, AuthMode, …). — instance.go:43
  • `Project` exposes publicly writable state (ProjectID, OwnerID, Name, CreationTime, UpdateTime, Deleted, …). — project.go:43
  • `Quota` exposes publicly writable state (ID, Ref, Reference, ReferenceID, Hard, Used, …). — quota.go:27

What to do

  • Make entity setters private/init-only; change state only through methods that enforce the invariants (Marten/EF can bind via constructor or private setters).
DM7 · Repository granularity10.0 / 10Exemplary✓ Tool-verified

Other · Domain Modelling — Whether repositories are per aggregate root (not per child entity) so the root's invariants can't be bypassed.

Method: Roslyn (DDD-gated): repository abstraction detection; repositories over non-aggregate-root entities flagged. Deterministic, DDD-native.

Coverage: Population: repositories + aggregate roots by NAME convention; per-root repository rule checked within the set.

DM8 · Value-object opportunities10.0 / 10Exemplary✓ Tool-verified

Other · Domain Modelling — Whether clusters of primitives that travel together (a missing value object) are extracted — a low-weight suggestion, LLM-confirmed when configured.

Method: Roslyn (DDD-gated): primitive parameter clusters recurring three or more times across signatures extracted, then confirmed by language model when configured. Advisory, low-weight.

M1 · Documentation (README)9.3 / 10Exemplary✓ 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 README to the 1 of 3 project(s) that lack one — worth up to 0.7 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 `NNNN-title.md` documents 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 `NNNN-title.md` names 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 accuracy8.0 / 10Strong◐ 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.

P3 · Security & performance tooling8.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 & Backup4.0 / 10Weak✓ 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).
  • Enable purge protection / soft-delete (and prevent_destroy on critical resources) so data stores can't be lost to an accidental or malicious delete.
P6 · Release 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 Safety9.8 / 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.

What to do

  • Migrate the remaining .js/.jsx files to TypeScript.
R10 · Code Duplication7.9 / 10Strong✓ Tool-verified

React / JS · Code Health — Copy-pasted token-identical blocks across the frontend (the D4 clone algorithm over JS/TS tokens, D-386).

Method: Copy-pasted token-identical blocks across the frontend (the D4 clone algorithm run over JS/TS tokens). Deterministic.

  • src/portal/src/app/shared/shared.module.ts:169 · src/portal/src/app/shared/shared.module.ts:213 — all 2 copies are in the same file, and what repeats is a LIST OF ENTRIES rather than behaviour — the same names written out more than once. Extract them into one shared, exported constant and spread that constant into each site, rather than into a function the sites call: a list like this often lives in declarative metadata (a decorator's options object, a static configuration table) that a build step must be able to read statically, where a function call is not allowed. Adding an entry to one copy and not the other is the failure this prevents. — shared.module.ts:169
  • src/portal/src/app/base/left-side-nav/job-service-dashboard/pending-job-card/pending-job-card.component.ts:88 · src/portal/src/app/base/left-side-nav/job-service-dashboard/worker-card/worker-card.component.ts:78 · src/portal/src/app/base/left-side-nav/job-service-dashboard/worker-list/worker-list.component.ts:95 — the 3 copies are spread across 3 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. — pending-job-card.component.ts:88
  • src/portal/src/app/base/project/project-log/audit-legacy-log.component.ts:41 · src/portal/src/app/base/project/project-log/audit-log.component.ts:42 — 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. — audit-legacy-log.component.ts:41
  • src/portal/src/app/base/project/repository/artifact/artifact-list-page/artifact-list-page.component.ts:88 · src/portal/src/app/base/project/repository/artifact/artifact-summary.component.ts:83 — 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. — artifact-list-page.component.ts:88
  • src/portal/src/app/base/left-side-nav/clearing-job/audit-log-purge/set-job/set-job.component.ts:147 · src/portal/src/app/base/left-side-nav/clearing-job/gc-page/gc/gc.component.ts:97 — 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. — set-job.component.ts:147
  • src/portal/src/app/base/left-side-nav/distribution/distribution-setup-modal/distribution-setup-modal.component.ts:337 · src/portal/src/app/base/left-side-nav/distribution/distribution-setup-modal/distribution-setup-modal.component.ts:391 — 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. — distribution-setup-modal.component.ts:337
  • src/portal/src/app/base/left-side-nav/interrogation-services/scanner/new-scanner-form/new-scanner-form.component.ts:114 · src/portal/src/app/base/left-side-nav/interrogation-services/scanner/new-scanner-form/new-scanner-form.component.ts: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. — new-scanner-form.component.ts:114
  • src/portal/src/app/base/left-side-nav/interrogation-services/vulnerability/vulnerability-config.component.ts:242 · src/portal/src/app/base/left-side-nav/interrogation-services/vulnerability/vulnerability-config.component.ts:261 · src/portal/src/app/base/left-side-nav/interrogation-services/vulnerability/vulnerability-config.component.ts:280 — all 3 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. — vulnerability-config.component.ts:242

What to do

  • Extract the duplicated blocks into shared functions/components.
R2 · Cyclomatic Complexity9.8 / 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.

  • Branch-heavy code is where defects cluster — extract decisions into smaller functions. (×8) — shared.utils.ts:136, add-p2p-policy.component.ts:277, new-user-form.component.ts:108, …

What to do

  • Break down the listed branch-heavy functions; aim P95 cyclomatic ≤ 5.
R3 · Large Files6.8 / 10Adequate✓ 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.

  • 25 file(s) over 400 lines (counted as significant lines — blank lines excluded — over production source only, tests excluded), largest first: src/portal/src/app/base/project/repository/artifact/artifact-list-page/artifact-list/artifact-list-tab/artifact-list-tab.component.ts (1219), src/portal/src/app/shared/units/utils.ts (1029), src/portal/src/app/base/left-side-nav/replication/replication/create-edit-rule/create-edit-rule.component.ts (901), src/portal/src/app/base/project/p2p-provider/policy/policy.component.ts (823), src/portal/src/app/base/left-side-nav/replication/replication/replication.component.ts (609), src/portal/src/app/base/project/project-config/project-policy-config/project-policy-config.component.ts (593) (+19 more).

What to do

  • Split each oversized file along the responsibilities already in it, into smaller focused modules in the same package.
R4 · Test Coverage9.9 / 10Exemplary✓ Tool-verified

React / JS · Readiness — Static test reachability (D-386): the share of production files reachable from any test via the import graph — measured without running anything.

Method: Static test reachability: the share of production files reachable from any test via the import graph — measured without running anything. Deterministic.

  • No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL — if neither does, no test reaches this one. (×4) — fade-in.animation.ts, top-repository.ts, requireRequestId.js, …

What to do

  • Add tests that import the unreached modules (directly or through their public entry).
R5 · Dependency Freshness7.3 / 10Strong✓ Tool-verified

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

Method: npm dependency staleness from manifest/registry metadata (a maturity signal; JS/npm CVEs are scored separately in D33). Deterministic.

What to do

  • Bump outdated dependencies to current versions to limit upgrade debt.
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 Code8.7 / 10Strong✓ 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.

  • 1 file(s) (~13 LoC) were excluded from dead-code analysis — declare main/module/exports or a conventional entry (src/index.*, an index.html script) so reachability can see this package.
  • Unreachable from the 11 application, 5 tooling and 208 test entry point(s) detected in this repo. Gate removals on your build/type-check — an undetected custom entry would make these reachable.
  • no import path from any entry point (11 application, 5 tooling, 208 test roots considered) (×3) — fade-in.animation.ts, top-repository.ts, tempCodeRunnerFile.ts
  • Nothing imports this binding — it is safe to review for removal. (×3) — confirmation-batch-message.ts:34, confirmation-batch-message.ts:48, clearing-job-interfact.ts:25

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 Hygiene7.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 src/portal/package.json but never imported anywhere in that package or its workspace members — dead weight and attack surface. Verify against build tooling before removing. (×3)

What to do

  • Remove unused dependencies, declare unlisted imports explicitly, and demote type-/test-only packages to devDependencies.
R9 · Circular Imports5.5 / 10Adequate✓ 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.

  • src/portal/src/app/shared/services/index.ts → src/portal/src/app/shared/services/job-log.service.ts → src/portal/src/app/shared/units/utils.ts → src/portal/src/app/shared/services/index.ts (one verified cycle inside a mutually-dependent group of 13 files) — index.ts
  • src/portal/src/app/shared/directives/scroll/scroll-manager.service.ts → src/portal/src/app/shared/directives/scroll/scroll-section.directive.ts → src/portal/src/app/shared/directives/scroll/scroll-manager.service.ts — scroll-manager.service.ts

What to do

  • Break each cycle by extracting the shared piece into a module both sides can import.

WCAG coverage — what static analysis assessed

Statically assessed 15 of 55 WCAG 2.2 Level A/AA success criteria (27%; ≈30% of the 50 WCAG 2.1 AA criteria for EN 301 549). The other 40 require runtime or manual evaluation. Partial signal only (a clean result is necessary, not sufficient; static analysis fully verifies none). This is accessibility readiness, not a conformance claim — a WCAG conformance claim requires manual evaluation (WCAG-EM 1.0).

DimensionWCAG 2.2 A/AA criteriaCoverage
AC1 · Text alternatives1.1.1, 1.2.2, 1.2.5Partial signal
AC2 · Forms & labels1.3.1, 3.3.2, 4.1.2Partial signal
AC3 · Page structure1.4.4, 2.2.1, 2.4.1, 2.4.2, 3.1.1, 4.1.2Partial signal
AC4 · Keyboard semantics2.1.1, 2.4.3Partial signal
AC5 · ARIA correctness4.1.2Partial signal
AC6 · Visual & motion safety1.4.3, 2.4.7Partial — literal CSS only
AC7 · A11y enforcementenforcement — no page criterionEnforcement posture (process)

Not statically assessed — these 40 Level A/AA criteria need runtime or manual evaluation (WCAG-EM): 1.2.1, 1.2.3, 1.2.4, 1.3.2, 1.3.3, 1.3.4, 1.3.5, 1.4.1, 1.4.2, 1.4.5, 1.4.10, 1.4.11, 1.4.12, 1.4.13, 2.1.2, 2.1.4, 2.2.2, 2.3.1, 2.4.4, 2.4.5, 2.4.6, 2.4.11, 2.5.1, 2.5.2, 2.5.3, 2.5.4, 2.5.7, 2.5.8, 3.1.2, 3.2.1, 3.2.2, 3.2.3, 3.2.4, 3.2.6, 3.3.1, 3.3.3, 3.3.4, 3.3.7, 3.3.8, 4.1.3.

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 Health80%StrongSolid.
Architecture80%StrongStrongest area.
Maturity65%Adequate — gated by M2Capped at Fair by a Critical contributor — resolve it before relying on this lens.
Readiness65%AdequateAcceptable, with room to improve.
Security43%Weak — gated by D28, D29, D31, D38Capped at Fair by a Critical contributor — resolve it before relying on this lens.
Domain Modelling59%Adequate — gated by DM2, DM5Capped at Fair by a Critical contributor — resolve it before relying on this lens.
Accessibility40%Weak — gated by AC1, AC4Capped at Fair by a Critical contributor — resolve it before relying on this lens.
Not included — 64 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.

  • AX1 Captive dependencies — no DI registrations detected
  • AX10 Code composition — not assessed — code composition is computed by ROLE over a document set 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
  • AX2 Stateful singletons — no singleton implementations detected
  • AX3 Project dependency cycles — not assessed — project cycles and dependency direction are computed over a project-reference graph 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
  • AX4 Dependency direction — not applicable to a CQRS architecture (the inward-dependency rule is for layered/clean styles)
  • AX6 Interface segregation — not assessed — interface segregation is computed over a type surface that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
  • AX7 Slice cohesion — not applicable — not a vertical-slice architecture
  • AX8 Test isolation — not assessed — test isolation is computed from a project graph (which projects are test projects, and what they reference) 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
  • AX9 CQS / query purity — no CQRS query handlers detected — query purity is not applicable to this codebase
  • AXB2 Runtime readiness — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
  • C1 Data Protection — Not assessed: these personal data controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) that was not loaded for this repository — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of an idiom this check recognises is NOT evidence that this repository lacks personal data controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
  • C2 Access Controls — Not assessed: these authorization controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) that was not loaded for this repository — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of an idiom this check recognises is NOT evidence that this repository lacks authorization controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
  • C3 Audit Trail — Not assessed: these audit controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) that was not loaded for this repository — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of an idiom this check recognises is NOT evidence that this repository lacks audit controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
  • C4 Data Retention — Not assessed: these retention controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) that was not loaded for this repository — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of an idiom this check recognises is NOT evidence that this repository lacks retention controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
  • C5 Data-Subject Rights — Not assessed: these data-subject rights controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) that was not loaded for this repository — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of an idiom this check recognises is NOT evidence that this repository lacks data-subject rights controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
  • D10 Test Quality — ~106085 lines of test source are present (.py, .go, .ts) but the test-quality collector reads C# only, so skipped/assertion-free tests couldn't be counted. Not scored — this is a gap in the analyzer, not a finding about this repository.
  • D11 Test Reliability — Test reliability not included
  • D12 Dependency Hygiene — Dependency hygiene not measured — dependency manifest found but not parsed for hygiene
  • D14 License Compliance — Not scored — this repository's package manifest is not parsed for licence data yet. A gap in the analyzer's language coverage, NOT a finding that the repository's licenses are compliant (a Go module (go.mod/go.sum)), which this pass does not parse yet — so this dimension asserts nothing about this repository's licensing in either direction.
  • D17 Explicit Debt — explicit-debt markers are read through a C# workspace today, so they were not read for this repository's language — this asserts nothing about how many markers the code carries. Not scored — this is a gap in the analyzer, not a finding about this repository
  • D18 Solution Shape — D18 scores the shape of a .NET solution; this repository has no .NET solution or project files, so the dimension does not apply.
  • D20 ADR Quality — N/A — ADRs are expected on deployable products with a user-facing host, not consumed libraries; no ADR log is required here.
  • D22 Internal API Consistency — No exposed public API
  • D23 Boundary Type-Coupling — Production source is present (.go, .py, .ts) but bounded contexts are resolved over the C#/VB project set, which exposed none, so context scope could not be assessed. Not scored — this is a gap in the analyzer, not a verdict about this repository. Declaring the codebase's bounded contexts (≥2) would let cross-boundary type coupling be assessed — see the recommendation on this dimension for where. Declare them in `.codehealth/config.yaml` at the repository root (create it if absent), mapping each context name to the module-path or namespace prefixes that belong to it — e.g. `architecture:` → `contexts:` → `Billing: ["src/billing", "Acme.Billing"]`, `Catalog: ["src/catalog", "Acme.Catalog"]`.
  • D24 Comment Value — No inline comments to assess — comment value is not applicable here.
  • D25 ADR Conformance — no ADRs to check
  • D26 Project Cohesion — Project cohesion is assessed over the .NET project set; this target exposed no projects, so project size and spread could not be assessed. Not scored — this is a gap in the analyzer's reach, not a verdict about this repository.
  • D27 Navigability — No calls could be sampled, so navigability was not assessed — tracing effort is measured over resolved call sites and this target exposed none. Not scored — this is a gap in the analyzer's reach, not a verdict about this repository.
  • D30 Dependency Vulnerabilities — Not scored — no dependency manifest in a supported ecosystem was read for this repository. A gap in the analyzer's language coverage, NOT a finding that the repository is free of vulnerable dependencies (a Go module (go.mod/go.sum) — not scanned yet) — where an OSV-supported manifest exists, dependency vulnerabilities for this repository are reported under D38 instead.
  • 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.
  • D40 Network Egress Confinement — No Kubernetes/orchestration workloads found in the repository manifests; network egress policy is a cluster-native control that may live at the platform/firewall layer, so there is nothing to assess here.
  • D41 Kernel & Syscall Confinement — No Kubernetes/orchestration workloads found in the repository manifests; seccomp/AppArmor/SELinux confinement is a workload-level control, so there is nothing to assess here.
  • D42 Runtime Threat Enforcement — No Kubernetes/orchestration workloads found in the repository manifests; runtime threat-detection and admission-control policy are cluster-level controls, so there is nothing to assess here.
  • D5 Coupling — Inter-project coupling could not be assessed — no analyzable project graph was found for this repository. Not scored: a gap in the analyzer's reach, not a verdict about this repository. (Coupling here is Martin afferent/efferent/instability plus reference cycles across a project-reference graph, read today from .NET project files; other ecosystems' module graphs are not read yet.)
  • D6 Cohesion (LCOM4) — Cohesion (LCOM4) is measured over a C#/VB class graph, and this repository's production source is mostly .go, .py, .ts, which this pass does not read, so cohesion was not assessed for this repository. Not scored — this is a gap in the analyzer, not a finding about this repository.
  • D7 Architectural Integrity — no checkable ADRs, and no project-reference graph for the cycle pass to read — so this dimension makes no claim about dependency cycles in either direction (where this repository's language has an import-cycle lens, cycles are reported there). Architectural integrity not assessed
  • D8 Code Coverage — Coverage not included — suite not readable by the collector
  • D9 Test Distribution — Test source is present (.py, .go, .ts) but the test-pyramid classifier reads C# only, so its unit/integration/BDD/E2E split couldn't be counted. Not scored — this is a gap in the analyzer, not a finding about this repository.
  • DM3 Integration-event coupling — no integration events detected — coupling check not applicable
  • DM6 Domain ↔ infrastructure boundary — no domain-layer types detected — domain↔infrastructure boundary check not applicable
  • ED1 Handler temporal coupling — no events and no event/broker handlers detected — event-driven integration not assessable
  • ED2 Event/command shape — no events and no event/broker handlers detected — event-driven integration not assessable
  • ED3 Event naming — no events and no event/broker handlers detected — event-driven integration not assessable
  • ED4 Outbox / dual-write — no events and no event/broker handlers detected — event-driven integration not assessable
  • ED5 Idempotency — no mutating command handlers or message consumers detected — idempotency check not applicable
  • ES1 Event Sourcing — not scored — this repository shows only 1 of the 3 signals this check looks for (9 Go aggregate(s) recording domain events (own events-slice append / raise-record))
  • GD1 Unfinished & placeholder code — no source files
  • IC1 Incompleteness & stubs — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
  • P12 CI test-gate honesty — Reported, not scored — this card publishes what the CI gate does with the test inventory rather than grading it. The findings above are its output.
  • P2 Observability — Observability was not assessed: this check reads a source model that does not carry this repository's product — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of a logging idiom this check recognises is NOT evidence that this repo lacks structured logging (it may log through its own ecosystem's logger). This is a gap in the analyzer, not a finding about this repository.
  • P7 Outbound HTTP resilience — not measured — the application kind could not be determined for this repo
  • P8 Schema migrations — not assessed — schema-migration practice is read from 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
  • P9 Domain vs controller coverage — no coverage report found on disk — produce a coverage report in a standard format (`go test -coverprofile=coverage.out ./...`) into the repo working tree before the scan — a CI step is the usual place, since the artefact is commonly gitignored, or wire coverage collection into CI, to enable this cross-layer check
  • PF1 Benchmark discipline — Performance was not assessed: this lens reads a source model that was not loaded for this repository, because the repository is written in a language this lens does not yet model or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository — in particular it is NOT a statement that this repo is unpackaged or performance-careless.
  • PF2 Allocation hygiene — Performance was not assessed: this lens reads a source model that was not loaded for this repository, because the repository is written in a language this lens does not yet model or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository — in particular it is NOT a statement that this repo is unpackaged or performance-careless.
  • PF3 Async & latency hygiene — Performance was not assessed: this lens reads a source model that was not loaded for this repository, because the repository is written in a language this lens does not yet model or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository — in particular it is NOT a statement that this repo is unpackaged or performance-careless.
  • R11 Import Boundaries — No recognizable feature-sliced/layered src layout — boundary rules not applicable.
  • S1 Web-Security Posture — Not assessed: these web-security controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) that was not loaded for this repository — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of an idiom this check recognises is NOT evidence that this repository lacks web-security controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
  • SC1 Supply-chain hygiene — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
  • X1 Async correctness — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
  • 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
  • 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
  • X4 Structured logging — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
  • X5 Nullable reference types — not 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

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.

Issue — 115 finding(s)
D29 · Static Analysis (SAST) · High · ×49
  • High: dependabot-missing-cooldown .github/dependabot.yml:10 — This Dependabot configuration does not set a cooldown period. Newly published packages can be malicious or unstable. Add a `cooldown` block with `default-days: 7` to each `package-ecosystem` entry under `updates` to wait 7 days before proposing updates to newly published package versions. Reference: https://docs.github.com/en/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file#cooldown. This is a semgrep security-AUDIT rule reporting a POLICY that is absent or weaker than its recommendation, not an exploitable defect. Confirm whether the current setting is a deliberate decision for this repository — and apply the change where it is not; where it is (a policy your release process already enforces elsewhere, or one this repository has consciously opted out of), record the decision and leave the configuration as it is. This configuration file has 4 such entries; one cooldown decision clears them all — reported once.
  • High: github-actions-mutable-action-tag .github/workflows/CI.yml:53 — GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/checkout@<40-character SHA>`. This step references `actions/checkout@v7`; resolve the SHA it points at today with `gh api repos/actions/checkout/commits/v7 --jq .sha`.
  • High: github-actions-mutable-action-tag .github/workflows/CI.yml:57 — GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/setup-go@<40-character SHA>`. This step references `actions/setup-go@v5`; resolve the SHA it points at today with `gh api repos/actions/setup-go/commits/v5 --jq .sha`.
  • High: github-actions-mutable-action-tag .github/workflows/CI.yml:63 — GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/cache@<40-character SHA>`. This step references `actions/cache@v4`; resolve the SHA it points at today with `gh api repos/actions/cache/commits/v4 --jq .sha`.
  • High: github-actions-mutable-action-tag .github/workflows/CI.yml:107 — GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: codecov/codecov-action@<40-character SHA>`. This step references `codecov/codecov-action@v7`; resolve the SHA it points at today with `gh api repos/codecov/codecov-action/commits/v7 --jq .sha`.
  • High: github-actions-mutable-action-tag .github/workflows/CI.yml:121 — GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/checkout@<40-character SHA>`. This step references `actions/checkout@v7`; resolve the SHA it points at today with `gh api repos/actions/checkout/commits/v7 --jq .sha`.
  • High: github-actions-mutable-action-tag .github/workflows/CI.yml:125 — GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/setup-go@<40-character SHA>`. This step references `actions/setup-go@v5`; resolve the SHA it points at today with `gh api repos/actions/setup-go/commits/v5 --jq .sha`.
  • High: github-actions-mutable-action-tag .github/workflows/CI.yml:169 — GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/upload-artifact@<40-character SHA>`. This step references `actions/upload-artifact@v6`; resolve the SHA it points at today with `gh api repos/actions/upload-artifact/commits/v6 --jq .sha`.
  • High: github-actions-mutable-action-tag .github/workflows/CI.yml:184 — GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/checkout@<40-character SHA>`. This step references `actions/checkout@v7`; resolve the SHA it points at today with `gh api repos/actions/checkout/commits/v7 --jq .sha`.
  • High: github-actions-mutable-action-tag .github/workflows/CI.yml:188 — GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/setup-go@<40-character SHA>`. This step references `actions/setup-go@v5`; resolve the SHA it points at today with `gh api repos/actions/setup-go/commits/v5 --jq .sha`.
  • High: github-actions-mutable-action-tag .github/workflows/CI.yml:233 — GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/upload-artifact@<40-character SHA>`. This step references `actions/upload-artifact@v6`; resolve the SHA it points at today with `gh api repos/actions/upload-artifact/commits/v6 --jq .sha`.
  • High: github-actions-mutable-action-tag .github/workflows/CI.yml:246 — GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/checkout@<40-character SHA>`. This step references `actions/checkout@v7`; resolve the SHA it points at today with `gh api repos/actions/checkout/commits/v7 --jq .sha`.
  • High: github-actions-mutable-action-tag .github/workflows/CI.yml:250 — GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/setup-go@<40-character SHA>`. This step references `actions/setup-go@v5`; resolve the SHA it points at today with `gh api repos/actions/setup-go/commits/v5 --jq .sha`.
  • High: github-actions-mutable-action-tag .github/workflows/CI.yml:293 — GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/upload-artifact@<40-character SHA>`. This step references `actions/upload-artifact@v6`; resolve the SHA it points at today with `gh api repos/actions/upload-artifact/commits/v6 --jq .sha`.
  • High: github-actions-mutable-action-tag .github/workflows/CI.yml:306 — GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/checkout@<40-character SHA>`. This step references `actions/checkout@v7`; resolve the SHA it points at today with `gh api repos/actions/checkout/commits/v7 --jq .sha`.
  • High: github-actions-mutable-action-tag .github/workflows/CI.yml:310 — GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/setup-go@<40-character SHA>`. This step references `actions/setup-go@v5`; resolve the SHA it points at today with `gh api repos/actions/setup-go/commits/v5 --jq .sha`.
  • High: github-actions-mutable-action-tag .github/workflows/CI.yml:359 — GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/setup-node@<40-character SHA>`. This step references `actions/setup-node@v6`; resolve the SHA it points at today with `gh api repos/actions/setup-node/commits/v6 --jq .sha`.
  • High: github-actions-mutable-action-tag .github/workflows/CI.yml:362 — GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/checkout@<40-character SHA>`. This step references `actions/checkout@v7`; resolve the SHA it points at today with `gh api repos/actions/checkout/commits/v7 --jq .sha`.
  • High: github-actions-mutable-action-tag .github/workflows/CI.yml:373 — GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: codecov/codecov-action@<40-character SHA>`. This step references `codecov/codecov-action@v7`; resolve the SHA it points at today with `gh api repos/codecov/codecov-action/commits/v7 --jq .sha`.
  • High: github-actions-mutable-action-tag .github/workflows/api-schema-check.yml:16 — GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/checkout@<40-character SHA>`. This step references `actions/checkout@v7`; resolve the SHA it points at today with `gh api repos/actions/checkout/commits/v7 --jq .sha`.
  • High: github-actions-mutable-action-tag .github/workflows/api-schema-check.yml:19 — GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: delimit-ai/delimit-action@<40-character SHA>`. This step references `delimit-ai/delimit-action@v1`; resolve the SHA it points at today with `gh api repos/delimit-ai/delimit-action/commits/v1 --jq .sha`.
  • High: github-actions-mutable-action-tag .github/workflows/auto_assign_prs.yml:16 — GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: kentaro-m/auto-assign-action@<40-character SHA>`. This step references `kentaro-m/auto-assign-action@v2.0.2`; resolve the SHA it points at today with `gh api repos/kentaro-m/auto-assign-action/commits/v2.0.2 --jq .sha`. Note that `v2.0.2` is an exact release tag rather than a floating major: it is still mutable (a tag can be repointed), but by convention it moves only on a force-push.
  • High: github-actions-mutable-action-tag .github/workflows/build-package.yml:26 — GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/checkout@<40-character SHA>`. This step references `actions/checkout@v7`; resolve the SHA it points at today with `gh api repos/actions/checkout/commits/v7 --jq .sha`.
  • High: github-actions-mutable-action-tag .github/workflows/build-package.yml:27 — GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: jitterbit/get-changed-files@<40-character SHA>`. This step references `jitterbit/get-changed-files@v1`; resolve the SHA it points at today with `gh api repos/jitterbit/get-changed-files/commits/v1 --jq .sha`.
  • High: github-actions-mutable-action-tag .github/workflows/build-package.yml:45 — GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: docker/setup-qemu-action@<40-character SHA>`. This step references `docker/setup-qemu-action@v4`; resolve the SHA it points at today with `gh api repos/docker/setup-qemu-action/commits/v4 --jq .sha`.
  • + 24 more in this group — see findings.md.
D38 · OSV Dependency Vulnerabilities · High CVE · ×25
  • High CVE: [GHSA redacted] src/portal/package-lock.json — @angular/common 21.2.13: [GHSA redacted] — upgrade to 21.2.17. This is 1 of 5 advisories with a published fix this scan raises against @angular/common 21.2.13, and their fixed versions do not agree — anything below 21.2.19 still leaves at least one of them open. Take this package to 21.2.19 or later: that is the floor for the package, not this row's target alone. This one row stands for the 5 advisories this scan raises against @angular/common 21.2.13: [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted].
  • High CVE: [GHSA redacted] src/portal/package-lock.json — @angular/compiler 21.2.13: [GHSA redacted] — upgrade to 21.2.19. This is 1 of 3 advisories with a published fix this scan raises against @angular/compiler 21.2.13, and their fixed versions do not agree — anything below 21.2.19 still leaves at least one of them open. Take this package to 21.2.19 or later: that is the floor for the package, not this row's target alone. This one row stands for the 3 advisories this scan raises against @angular/compiler 21.2.13: [GHSA redacted], [GHSA redacted], [GHSA redacted].
  • High CVE: [GHSA redacted] src/portal/package-lock.json — @angular/core 21.2.13: [GHSA redacted] — upgrade to 21.2.19. This is 1 of 4 advisories with a published fix this scan raises against @angular/core 21.2.13, and their fixed versions do not agree — anything below 21.2.19 still leaves at least one of them open. Take this package to 21.2.19 or later: that is the floor for the package, not this row's target alone. This one row stands for the 4 advisories this scan raises against @angular/core 21.2.13: [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted].
  • High CVE: [GHSA redacted] src/portal/app-swagger-ui/package-lock.json — axios 1.17.0: [GHSA redacted] — axios is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin axios to 1.18.0 with an `overrides` entry). This one row stands for the 10 advisories this scan raises against axios 1.17.0: [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted].
  • High CVE: [GHSA redacted] src/portal/package-lock.json — brace-expansion 1.1.14: [GHSA redacted] — brace-expansion is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin brace-expansion to 1.1.16 with an `overrides` entry). This is 1 of 3 advisories with a published fix this scan raises against brace-expansion 1.1.14, and their fixed versions do not agree — anything below 1.1.18 still leaves at least one of them open. Take this package to 1.1.18 or later: that is the floor for the package, not this row's target alone. This one row stands for the 3 advisories this scan raises against brace-expansion 1.1.14: [GHSA redacted], [GHSA redacted], [GHSA redacted].
  • High CVE: [GHSA redacted] src/portal/app-swagger-ui/package-lock.json — brace-expansion 1.1.15: [GHSA redacted] — brace-expansion is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin brace-expansion to 1.1.16 with an `overrides` entry). This is 1 of 3 advisories with a published fix this scan raises against brace-expansion 1.1.15, and their fixed versions do not agree — anything below 1.1.18 still leaves at least one of them open. Take this package to 1.1.18 or later: that is the floor for the package, not this row's target alone. This one row stands for the 3 advisories this scan raises against brace-expansion 1.1.15: [GHSA redacted], [GHSA redacted], [GHSA redacted].
  • High CVE: [GHSA redacted] src/portal/app-swagger-ui/package-lock.json — brace-expansion 5.0.6: [GHSA redacted] — brace-expansion is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin brace-expansion to 5.0.7 with an `overrides` entry). This is 1 of 3 advisories with a published fix this scan raises against brace-expansion 5.0.6, and their fixed versions do not agree — anything below 5.0.9 still leaves at least one of them open. Take this package to 5.0.9 or later: that is the floor for the package, not this row's target alone. (in 2 dependency files: src/portal/app-swagger-ui/package-lock.json, src/portal/package-lock.json) This one row stands for the 3 advisories this scan raises against brace-expansion 5.0.6: [GHSA redacted], [GHSA redacted], [GHSA redacted].
  • High CVE: [GHSA redacted] src/portal/app-swagger-ui/package-lock.json — fast-uri 3.1.2: [GHSA redacted] — fast-uri is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin fast-uri to 3.1.3 with an `overrides` entry). This is 1 of 3 advisories with a published fix this scan raises against fast-uri 3.1.2, and their fixed versions do not agree — anything below 3.1.5 still leaves at least one of them open. Take this package to 3.1.5 or later: that is the floor for the package, not this row's target alone. (in 2 dependency files: src/portal/app-swagger-ui/package-lock.json, src/portal/package-lock.json) This one row stands for the 3 advisories this scan raises against fast-uri 3.1.2: [GHSA redacted], [GHSA redacted], [GHSA redacted].
  • High CVE: [GHSA redacted] src/portal/app-swagger-ui/package-lock.json — form-data 4.0.5: [GHSA redacted] — form-data is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin form-data to 4.0.6 with an `overrides` entry).
  • High CVE: [GHSA redacted] src/portal/package-lock.json — hono 4.12.19: [GHSA redacted] — hono is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin hono to 4.12.25 with an `overrides` entry). This is 1 of 13 advisories with a published fix this scan raises against hono 4.12.19, and their fixed versions do not agree — anything below 4.12.34 still leaves at least one of them open. Take this package to 4.12.34 or later: that is the floor for the package, not this row's target alone. This one row stands for the 13 advisories this scan raises against hono 4.12.19: [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted].
  • High CVE: [GHSA redacted] src/portal/package-lock.json — http-proxy-middleware 3.0.5: [GHSA redacted] — http-proxy-middleware is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin http-proxy-middleware to 3.0.7 with an `overrides` entry). This is 1 of 2 advisories with a published fix this scan raises against http-proxy-middleware 3.0.5, and their fixed versions do not agree — anything below 3.0.7 still leaves at least one of them open. Take this package to 3.0.7 or later: that is the floor for the package, not this row's target alone. This one row stands for the 2 advisories this scan raises against http-proxy-middleware 3.0.5: [GHSA redacted], [GHSA redacted].
  • High CVE: [GHSA redacted] src/portal/app-swagger-ui/package-lock.json — immutable 3.8.3: [GHSA redacted] — immutable is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (— 4.3.9 is a MAJOR ahead of the resolved 3.8.3, so an `overrides` pin would force a breaking version under a dependent written against 3.8.3; upgrading the declaring package is the remedy, and where no patched release exists in your major line, record the exposure instead). This one row stands for the 2 advisories this scan raises against immutable 3.8.3: [GHSA redacted], [GHSA redacted].
  • High CVE: [GHSA redacted] src/portal/package-lock.json — immutable 5.1.5: [GHSA redacted] — immutable is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin immutable to 5.1.8 with an `overrides` entry). This one row stands for the 2 advisories this scan raises against immutable 5.1.5: [GHSA redacted], [GHSA redacted].
  • High CVE: [GHSA redacted] src/portal/package-lock.json — ip-address 10.2.0: [GHSA redacted] — ip-address is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin ip-address to 10.3.1 with an `overrides` entry). This is 1 of 3 advisories with a published fix this scan raises against ip-address 10.2.0, and their fixed versions do not agree — anything below 10.3.1 still leaves at least one of them open. Take this package to 10.3.1 or later: that is the floor for the package, not this row's target alone. This one row stands for the 3 advisories this scan raises against ip-address 10.2.0: [GHSA redacted], [GHSA redacted], [GHSA redacted].
  • High CVE: [GHSA redacted] src/portal/package-lock.json — js-yaml 3.14.2: [GHSA redacted] — this repo declares js-yaml 4.1.1, but the vulnerable 3.14.2 is a SEPARATE copy on another release line, so editing your own js-yaml entry cannot move it: upgrade the dependency that pulls it in (or pin js-yaml to 3.15.0 with an `overrides` entry). This one row stands for the 2 advisories this scan raises against js-yaml 3.14.2: [GHSA redacted], [GHSA redacted].
  • High CVE: [GHSA redacted] src/portal/app-swagger-ui/package-lock.json — js-yaml 4.1.1: [GHSA redacted] — js-yaml is not declared by the manifests that govern this lockfile: it is pulled in transitively here (the 4.1.1 this repo declares for it belongs to a separate install root and does not reach this one), so upgrade the dependency that requires it (or pin js-yaml to 4.3.0 with an `overrides` entry). This is 1 of 2 advisories with a published fix this scan raises against js-yaml 4.1.1, and their fixed versions do not agree — anything below 4.3.0 still leaves at least one of them open. Take this package to 4.3.0 or later: that is the floor for the package, not this row's target alone. (in 2 dependency files: src/portal/app-swagger-ui/package-lock.json, src/portal/package-lock.json) This one row stands for the 2 advisories this scan raises against js-yaml 4.1.1: [GHSA redacted], [GHSA redacted].
  • High CVE: [GHSA redacted] src/portal/package-lock.json — piscina 5.1.4: [GHSA redacted] — piscina is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin piscina to 5.2.0 with an `overrides` entry).
  • High CVE: [GHSA redacted] src/portal/app-swagger-ui/package-lock.json — shell-quote 1.8.4: [GHSA redacted] — shell-quote is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin shell-quote to 1.9.0 with an `overrides` entry).
  • High CVE: [GHSA redacted] src/portal/package-lock.json — sigstore 4.1.0: [GHSA redacted] — sigstore is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin sigstore to 4.1.1 with an `overrides` entry).
  • High CVE: [GHSA redacted] src/portal/package-lock.json — socket.io-parser 4.2.6: [GHSA redacted] — socket.io-parser is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin socket.io-parser to 4.2.7 with an `overrides` entry).
  • High CVE: [GHSA redacted] src/portal/package-lock.json — tmp 0.2.5: [GHSA redacted] — tmp is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin tmp to 0.2.6 with an `overrides` entry).
  • High CVE: [GHSA redacted] src/portal/package-lock.json — undici 6.25.0: [GHSA redacted] — undici is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin undici to 6.27.0 with an `overrides` entry). This is 1 of 7 advisories with a published fix this scan raises against undici 6.25.0, and their fixed versions do not agree — anything below 6.28.0 still leaves at least one of them open. Take this package to 6.28.0 or later: that is the floor for the package, not this row's target alone. This one row stands for the 7 advisories this scan raises against undici 6.25.0: [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted].
  • High CVE: [GHSA redacted] src/portal/package-lock.json — undici 7.24.4: [GHSA redacted] — undici is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin undici to 7.29.0 with an `overrides` entry). This is 1 of 12 advisories with a published fix this scan raises against undici 7.24.4, and their fixed versions do not agree — anything below 7.29.0 still leaves at least one of them open. Take this package to 7.29.0 or later: that is the floor for the package, not this row's target alone. This one row stands for the 12 advisories this scan raises against undici 7.24.4: [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted].
  • High CVE: [GHSA redacted] src/portal/package-lock.json — vite 7.3.2: [GHSA redacted] — vite is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin vite to 7.3.5 with an `overrides` entry). This one row stands for the 2 advisories this scan raises against vite 7.3.2: [GHSA redacted], [GHSA redacted].
  • High CVE: [GHSA redacted] src/portal/package-lock.json — ws 8.18.3: [GHSA redacted] — ws is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin ws to 8.21.0 with an `overrides` entry). This is 1 of 2 advisories with a published fix this scan raises against ws 8.18.3, and their fixed versions do not agree — anything below 8.21.0 still leaves at least one of them open. Take this package to 8.21.0 or later: that is the floor for the package, not this row's target alone. This one row stands for the 2 advisories this scan raises against ws 8.18.3: [GHSA redacted], [GHSA redacted].
D31 · IaC & Container Security · High IaC · ×21
  • High IaC: DS-0002 make/photon/common/Dockerfile — Image user should not be 'root' A container that starts as root runs your process with root's capabilities inside the namespace, so a compromise of the process starts from there. The step: create an unprivileged account in the image (`RUN useradd -r -M app`), give it ownership of the paths the process writes at runtime (`COPY --chown=` on those layers, or a `RUN chown -R`), and end the final stage with `USER app` so it is the default at start. Build stages that only compile can stay root; it is the stage that RUNS that needs the account. If the process genuinely requires root — it manages the container runtime, ptraces another process or opens raw devices — say so here rather than making a change that breaks it.
  • High IaC: DS-0002 make/photon/core/Dockerfile.base — Image user should not be 'root' A container that starts as root runs your process with root's capabilities inside the namespace, so a compromise of the process starts from there. The step: create an unprivileged account in the image (`RUN useradd -r -M app`), give it ownership of the paths the process writes at runtime (`COPY --chown=` on those layers, or a `RUN chown -R`), and end the final stage with `USER app` so it is the default at start. Build stages that only compile can stay root; it is the stage that RUNS that needs the account. If the process genuinely requires root — it manages the container runtime, ptraces another process or opens raw devices — say so here rather than making a change that breaks it.
  • High IaC: DS-0002 make/photon/db/Dockerfile.base — Image user should not be 'root' A container that starts as root runs your process with root's capabilities inside the namespace, so a compromise of the process starts from there. The step: create an unprivileged account in the image (`RUN useradd -r -M app`), give it ownership of the paths the process writes at runtime (`COPY --chown=` on those layers, or a `RUN chown -R`), and end the final stage with `USER app` so it is the default at start. Build stages that only compile can stay root; it is the stage that RUNS that needs the account. If the process genuinely requires root — it manages the container runtime, ptraces another process or opens raw devices — say so here rather than making a change that breaks it.
  • High IaC: DS-0019 make/photon/db/Dockerfile.base — 'dnf clean all' missing The install step leaves the package manager's index and downloaded packages behind in that layer, so every pull carries them and every CVE in them is attributed to your image. The step: this file installs with `tdnf`, so end the SAME `RUN` that installs with `&& tdnf clean all` — a later `RUN` cannot help, because the cache is already committed to the earlier layer. (The rule's title names the command for a different package manager; the defect it measures is the same one.) Where the builder supports it, `RUN --mount=type=cache` is the alternative: the cache is mounted for the step and never enters a layer at all.
  • High IaC: DS-0002 make/photon/exporter/Dockerfile.base — Image user should not be 'root' A container that starts as root runs your process with root's capabilities inside the namespace, so a compromise of the process starts from there. The step: create an unprivileged account in the image (`RUN useradd -r -M app`), give it ownership of the paths the process writes at runtime (`COPY --chown=` on those layers, or a `RUN chown -R`), and end the final stage with `USER app` so it is the default at start. Build stages that only compile can stay root; it is the stage that RUNS that needs the account. If the process genuinely requires root — it manages the container runtime, ptraces another process or opens raw devices — say so here rather than making a change that breaks it.
  • High IaC: DS-0002 make/photon/jobservice/Dockerfile.base — Image user should not be 'root' A container that starts as root runs your process with root's capabilities inside the namespace, so a compromise of the process starts from there. The step: create an unprivileged account in the image (`RUN useradd -r -M app`), give it ownership of the paths the process writes at runtime (`COPY --chown=` on those layers, or a `RUN chown -R`), and end the final stage with `USER app` so it is the default at start. Build stages that only compile can stay root; it is the stage that RUNS that needs the account. If the process genuinely requires root — it manages the container runtime, ptraces another process or opens raw devices — say so here rather than making a change that breaks it.
  • High IaC: DS-0002 make/photon/log/Dockerfile — Image user should not be 'root' A container that starts as root runs your process with root's capabilities inside the namespace, so a compromise of the process starts from there. The step: create an unprivileged account in the image (`RUN useradd -r -M app` — or whatever this base image's account tooling is, `adduser` and `useradd` are not both present everywhere`), give it ownership of the paths the process writes at runtime (`COPY --chown=` on those layers, or a `RUN chown -R`), and end the final stage with `USER app` so it is the default at start. Build stages that only compile can stay root; it is the stage that RUNS that needs the account. If the process genuinely requires root — it manages the container runtime, ptraces another process or opens raw devices — say so here rather than making a change that breaks it.
  • High IaC: DS-0002 make/photon/log/Dockerfile.base — Image user should not be 'root' A container that starts as root runs your process with root's capabilities inside the namespace, so a compromise of the process starts from there. The step: create an unprivileged account in the image (`RUN useradd -r -M app`), give it ownership of the paths the process writes at runtime (`COPY --chown=` on those layers, or a `RUN chown -R`), and end the final stage with `USER app` so it is the default at start. Build stages that only compile can stay root; it is the stage that RUNS that needs the account. If the process genuinely requires root — it manages the container runtime, ptraces another process or opens raw devices — say so here rather than making a change that breaks it.
  • High IaC: DS-0002 make/photon/nginx/Dockerfile.base — Image user should not be 'root' A container that starts as root runs your process with root's capabilities inside the namespace, so a compromise of the process starts from there. The step: create an unprivileged account in the image (`RUN useradd -r -M app`), give it ownership of the paths the process writes at runtime (`COPY --chown=` on those layers, or a `RUN chown -R`), and end the final stage with `USER app` so it is the default at start. Build stages that only compile can stay root; it is the stage that RUNS that needs the account. If the process genuinely requires root — it manages the container runtime, ptraces another process or opens raw devices — say so here rather than making a change that breaks it.
  • High IaC: DS-0002 make/photon/portal/Dockerfile.base — Image user should not be 'root' A container that starts as root runs your process with root's capabilities inside the namespace, so a compromise of the process starts from there. The step: create an unprivileged account in the image (`RUN useradd -r -M app`), give it ownership of the paths the process writes at runtime (`COPY --chown=` on those layers, or a `RUN chown -R`), and end the final stage with `USER app` so it is the default at start. Build stages that only compile can stay root; it is the stage that RUNS that needs the account. If the process genuinely requires root — it manages the container runtime, ptraces another process or opens raw devices — say so here rather than making a change that breaks it.
  • High IaC: DS-0002 make/photon/prepare/Dockerfile — Image user should not be 'root' A container that starts as root runs your process with root's capabilities inside the namespace, so a compromise of the process starts from there. The step: create an unprivileged account in the image (`RUN useradd -r -M app` — or whatever this base image's account tooling is, `adduser` and `useradd` are not both present everywhere`), give it ownership of the paths the process writes at runtime (`COPY --chown=` on those layers, or a `RUN chown -R`), and end the final stage with `USER app` so it is the default at start. Build stages that only compile can stay root; it is the stage that RUNS that needs the account. If the process genuinely requires root — it manages the container runtime, ptraces another process or opens raw devices — say so here rather than making a change that breaks it.
  • High IaC: DS-0002 make/photon/prepare/Dockerfile.base — Image user should not be 'root' A container that starts as root runs your process with root's capabilities inside the namespace, so a compromise of the process starts from there. The step: create an unprivileged account in the image (`RUN useradd -r -M app`), give it ownership of the paths the process writes at runtime (`COPY --chown=` on those layers, or a `RUN chown -R`), and end the final stage with `USER app` so it is the default at start. Build stages that only compile can stay root; it is the stage that RUNS that needs the account. If the process genuinely requires root — it manages the container runtime, ptraces another process or opens raw devices — say so here rather than making a change that breaks it.
  • High IaC: DS-0019 make/photon/prepare/Dockerfile.base — 'dnf clean all' missing The install step leaves the package manager's index and downloaded packages behind in that layer, so every pull carries them and every CVE in them is attributed to your image. The step: this file installs with `tdnf`, so end the SAME `RUN` that installs with `&& tdnf clean all` — a later `RUN` cannot help, because the cache is already committed to the earlier layer. (The rule's title names the command for a different package manager; the defect it measures is the same one.) Where the builder supports it, `RUN --mount=type=cache` is the alternative: the cache is mounted for the step and never enters a layer at all.
  • High IaC: DS-0002 make/photon/registry/Dockerfile.base — Image user should not be 'root' A container that starts as root runs your process with root's capabilities inside the namespace, so a compromise of the process starts from there. The step: create an unprivileged account in the image (`RUN useradd -r -M app`), give it ownership of the paths the process writes at runtime (`COPY --chown=` on those layers, or a `RUN chown -R`), and end the final stage with `USER app` so it is the default at start. Build stages that only compile can stay root; it is the stage that RUNS that needs the account. If the process genuinely requires root — it manages the container runtime, ptraces another process or opens raw devices — say so here rather than making a change that breaks it.
  • High IaC: DS-0002 make/photon/registryctl/Dockerfile.base — Image user should not be 'root' A container that starts as root runs your process with root's capabilities inside the namespace, so a compromise of the process starts from there. The step: create an unprivileged account in the image (`RUN useradd -r -M app`), give it ownership of the paths the process writes at runtime (`COPY --chown=` on those layers, or a `RUN chown -R`), and end the final stage with `USER app` so it is the default at start. Build stages that only compile can stay root; it is the stage that RUNS that needs the account. If the process genuinely requires root — it manages the container runtime, ptraces another process or opens raw devices — say so here rather than making a change that breaks it.
  • High IaC: DS-0002 make/photon/trivy-adapter/Dockerfile.base — Image user should not be 'root' A container that starts as root runs your process with root's capabilities inside the namespace, so a compromise of the process starts from there. The step: create an unprivileged account in the image (`RUN useradd -r -M app`), give it ownership of the paths the process writes at runtime (`COPY --chown=` on those layers, or a `RUN chown -R`), and end the final stage with `USER app` so it is the default at start. Build stages that only compile can stay root; it is the stage that RUNS that needs the account. If the process genuinely requires root — it manages the container runtime, ptraces another process or opens raw devices — say so here rather than making a change that breaks it.
  • High IaC: DS-0002 make/photon/valkey/Dockerfile.base — Image user should not be 'root' A container that starts as root runs your process with root's capabilities inside the namespace, so a compromise of the process starts from there. The step: create an unprivileged account in the image (`RUN useradd -r -M app`), give it ownership of the paths the process writes at runtime (`COPY --chown=` on those layers, or a `RUN chown -R`), and end the final stage with `USER app` so it is the default at start. Build stages that only compile can stay root; it is the stage that RUNS that needs the account. If the process genuinely requires root — it manages the container runtime, ptraces another process or opens raw devices — say so here rather than making a change that breaks it.
  • High IaC: DS-0019 make/photon/valkey/Dockerfile.base — 'dnf clean all' missing The install step leaves the package manager's index and downloaded packages behind in that layer, so every pull carries them and every CVE in them is attributed to your image. The step: this file installs with `tdnf`, so end the SAME `RUN` that installs with `&& tdnf clean all` — a later `RUN` cannot help, because the cache is already committed to the earlier layer. (The rule's title names the command for a different package manager; the defect it measures is the same one.) Where the builder supports it, `RUN --mount=type=cache` is the alternative: the cache is mounted for the step and never enters a layer at all.
  • High IaC: DS-0002 tools/migrate_chart/Dockerfile — Image user should not be 'root' A container that starts as root runs your process with root's capabilities inside the namespace, so a compromise of the process starts from there. The step: create an unprivileged account in the image (`RUN useradd -r -M app` — or whatever this base image's account tooling is, `adduser` and `useradd` are not both present everywhere`), give it ownership of the paths the process writes at runtime (`COPY --chown=` on those layers, or a `RUN chown -R`), and end the final stage with `USER app` so it is the default at start. Build stages that only compile can stay root; it is the stage that RUNS that needs the account. If the process genuinely requires root — it manages the container runtime, ptraces another process or opens raw devices — say so here rather than making a change that breaks it.
  • High IaC: DS-0002 tools/spectral/Dockerfile — Image user should not be 'root' A container that starts as root runs your process with root's capabilities inside the namespace, so a compromise of the process starts from there. The step: create an unprivileged account in the image (`RUN useradd -r -M app` — or whatever this base image's account tooling is, `adduser` and `useradd` are not both present everywhere`), give it ownership of the paths the process writes at runtime (`COPY --chown=` on those layers, or a `RUN chown -R`), and end the final stage with `USER app` so it is the default at start. Build stages that only compile can stay root; it is the stage that RUNS that needs the account. If the process genuinely requires root — it manages the container runtime, ptraces another process or opens raw devices — say so here rather than making a change that breaks it.
  • High IaC: DS-0002 tools/swagger/Dockerfile — Image user should not be 'root' A container that starts as root runs your process with root's capabilities inside the namespace, so a compromise of the process starts from there. The step: create an unprivileged account in the image (`RUN useradd -r -M app` — or whatever this base image's account tooling is, `adduser` and `useradd` are not both present everywhere`), give it ownership of the paths the process writes at runtime (`COPY --chown=` on those layers, or a `RUN chown -R`), and end the final stage with `USER app` so it is the default at start. Build stages that only compile can stay root; it is the stage that RUNS that needs the account. If the process genuinely requires root — it manages the container runtime, ptraces another process or opens raw devices — say so here rather than making a change that breaks it.
D28 · Secrets (history) · Secret · ×10
  • Secret: private-key make/photon/prepare/templates/core/private_key.pem:1 — matched rule 'private-key'
  • Secret: private-key src/jobservice_v2/server.key:1 — matched rule 'private-key'
  • Secret: private-key contrib/helm/harbor/values.yaml:55 — matched rule 'private-key'
  • Secret: private-key make/common/templates/ui/private_key.pem:1 — matched rule 'private-key'
  • Secret: private-key Deploy/config/ui/private_key.pem:1 — matched rule 'private-key'
  • Secret: private-key Deploy/config/ui/private_key.pem:1 — matched rule 'private-key'
  • Secret: private-key Deploy/private_key.pem:1 — matched rule 'private-key'
  • Secret: private-key k8s/dockerfiles/config/ui/private_key.pem:1 — matched rule 'private-key'
  • Secret: private-key conf/private_key.pem:1 — matched rule 'private-key'
  • Secret: private-key src/jobservice/server.key:1 — matched rule 'private-key'
D38 · OSV Dependency Vulnerabilities · Critical CVE · ×3
  • Critical CVE: [GHSA redacted] src/portal/package-lock.json — shell-quote 1.8.3: [GHSA redacted] — shell-quote is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin shell-quote to 1.8.4 with an `overrides` entry). This is 1 of 2 advisories with a published fix this scan raises against shell-quote 1.8.3, and their fixed versions do not agree — anything below 1.9.0 still leaves at least one of them open. Take this package to 1.9.0 or later: that is the floor for the package, not this row's target alone. This one row stands for the 2 advisories this scan raises against shell-quote 1.8.3: [GHSA redacted], [GHSA redacted].
  • Critical CVE: [GHSA redacted] src/portal/package-lock.json — tar 7.5.15: [GHSA redacted] — tar is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin tar to 7.5.19 with an `overrides` entry). This is 1 of 6 advisories with a published fix this scan raises against tar 7.5.15, and their fixed versions do not agree — anything below 7.5.21 still leaves at least one of them open. Take this package to 7.5.21 or later: that is the floor for the package, not this row's target alone. This one row stands for the 6 advisories this scan raises against tar 7.5.15: [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted].
  • Critical CVE: [GHSA redacted] src/portal/package-lock.json — websocket-driver 0.7.4: [GHSA redacted] — websocket-driver is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin websocket-driver to 0.7.5 with an `overrides` entry). This one row stands for the 2 advisories this scan raises against websocket-driver 0.7.4: [GHSA redacted], [GHSA redacted].
D38 · OSV Dependency Vulnerabilities · High vulnerability · ×3
  • High vulnerability: [GHSA redacted] src/portal/package-lock.json — postcss 8.5.12: [GHSA redacted] — postcss is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin postcss to 8.5.18 with an `overrides` entry). This is 1 of 2 advisories with a published fix this scan raises against postcss 8.5.12, and their fixed versions do not agree — anything below 8.5.23 still leaves at least one of them open. Take this package to 8.5.23 or later: that is the floor for the package, not this row's target alone. This one row stands for the 2 advisories this scan raises against postcss 8.5.12: [GHSA redacted], [GHSA redacted].
  • High vulnerability: [GHSA redacted] src/portal/app-swagger-ui/package-lock.json — postcss 8.5.15: [GHSA redacted] — postcss is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin postcss to 8.5.18 with an `overrides` entry). This is 1 of 2 advisories with a published fix this scan raises against postcss 8.5.15, and their fixed versions do not agree — anything below 8.5.23 still leaves at least one of them open. Take this package to 8.5.23 or later: that is the floor for the package, not this row's target alone. This one row stands for the 2 advisories this scan raises against postcss 8.5.15: [GHSA redacted], [GHSA redacted].
  • High vulnerability: [GHSA redacted] src/portal/app-swagger-ui/package-lock.json — serialize-javascript 6.0.2: [GHSA redacted] — serialize-javascript is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (— 7.0.3 is a MAJOR ahead of the resolved 6.0.2, so an `overrides` pin would force a breaking version under a dependent written against 6.0.2; upgrading the declaring package is the remedy, and where no patched release exists in your major line, record the exposure instead). This is 1 of 2 advisories with a published fix this scan raises against serialize-javascript 6.0.2, and their fixed versions do not agree — anything below 7.0.5 still leaves at least one of them open. Take this package to 7.0.5 or later: that is the floor for the package, not this row's target alone. This one row stands for the 2 advisories this scan raises against serialize-javascript 6.0.2: [GHSA redacted], [GHSA redacted].
D35 · Change Coupling · Boundary-crossing change coupling · ×2
  • Boundary-crossing change coupling: const.go ↔ model.go src/common/const.go — `src/common/const.go` (context common) and `src/lib/config/models/model.go` (context config) sit in DIFFERENT parts of the tree yet change together 85% of the time (23 of the 27 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well) — 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.
  • Boundary-crossing change coupling: project.go ↔ project_metadata.go src/pkg/project/models/project.go — `src/pkg/project/models/project.go` (context pkg) and `src/server/v2.0/handler/project_metadata.go` (context v2.0) sit in DIFFERENT parts of the tree yet change together 80% of the time (8 of the 10 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well) — 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.
D13 · Secret Scanning · Leaked secret · ×1
  • Leaked secret: private-key src/jobservice/server.key:1 — private-key detected. Treat the value as compromised: it is readable by everyone who has ever had the repository, and deleting the line does not un-publish it. In order — (1) REVOKE it at whatever issued it and issue a replacement, which is the only step that actually closes the exposure; (2) load the replacement at run time from your platform's secret store or the process environment instead of from the tree, so no future value is committable; (3) remove the file or line and add its path to the repository's ignore rules, so it cannot come back; (4) if the value was ever live, purge it from the history as well, since a clone taken before the deletion still carries it. If this is instead a FIXTURE — key material generated for tests and valid nowhere — then the exposure is nil and the fix is to make that legible: generate it in test setup, or keep it under a test-data path, so a reader (and this scan) can tell it from the real thing.
D34 · Knowledge Freshness · Orphaned knowledge · ×1
  • Orphaned knowledge src/server/v2.0/handler/replication.go — No living knowledge remains for this large file — its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites.
Warning — 406 finding(s)
D31 · IaC & Container Security · Medium IaC · ×25
  • Medium IaC: DS-0013 make/photon/portal/Dockerfile — 'RUN cd ...' to change directory
  • Medium IaC: DS-0013 make/photon/valkey/Dockerfile.base — 'RUN cd ...' to change directory
  • Medium IaC: DS-0013 src/portal/docker-build/Dockerfile — 'RUN cd ...' to change directory
  • Medium IaC: CKV_DOCKER_7 make/photon/portal/Dockerfile:4 — Ensure the base image uses a non latest version tag
  • Medium IaC: CKV_DOCKER_3 make/photon/log/Dockerfile.base:1 — Ensure that a user for the container has been created
  • Medium IaC: CKV_DOCKER_4 make/photon/trivy-adapter/Dockerfile.binary:4 — Ensure that COPY is used instead of ADD in Dockerfiles
  • Medium IaC: CKV_DOCKER_7 make/photon/trivy-adapter/Dockerfile.binary:2 — Ensure the base image uses a non latest version tag
  • Medium IaC: CKV_DOCKER_3 make/photon/trivy-adapter/Dockerfile.binary:1 — Ensure that a user for the container has been created
  • Medium IaC: CKV_DOCKER_7 make/photon/exporter/Dockerfile:7 — Ensure the base image uses a non latest version tag
  • Medium IaC: CKV_DOCKER_3 make/photon/prepare/Dockerfile:1 — Ensure that a user for the container has been created
  • Medium IaC: CKV_DOCKER_3 make/photon/exporter/Dockerfile.base:1 — Ensure that a user for the container has been created
  • Medium IaC: CKV_DOCKER_3 make/photon/registry/Dockerfile.base:1 — Ensure that a user for the container has been created
  • Medium IaC: CKV_DOCKER_3 make/photon/common/Dockerfile:1 — Ensure that a user for the container has been created
  • Medium IaC: CKV_DOCKER_3 make/photon/nginx/Dockerfile.base:1 — Ensure that a user for the container has been created
  • Medium IaC: CKV_DOCKER_3 make/photon/db/Dockerfile.base:1 — Ensure that a user for the container has been created
  • Medium IaC: CKV_DOCKER_3 make/photon/prepare/Dockerfile.base:1 — Ensure that a user for the container has been created
  • Medium IaC: CKV_DOCKER_4 tools/migrate_chart/Dockerfile:7 — Ensure that COPY is used instead of ADD in Dockerfiles
  • Medium IaC: CKV_DOCKER_3 tools/migrate_chart/Dockerfile:1 — Ensure that a user for the container has been created
  • Medium IaC: CKV_DOCKER_2 make/photon/standalone-db-migrator/Dockerfile:1 — Ensure that HEALTHCHECK instructions have been added to container images
  • Medium IaC: CKV_DOCKER_3 make/photon/trivy-adapter/Dockerfile.base:1 — Ensure that a user for the container has been created
  • Medium IaC: CKV_DOCKER_7 tools/spectral/Dockerfile:2 — Ensure the base image uses a non latest version tag
  • Medium IaC: CKV_DOCKER_3 tools/spectral/Dockerfile:1 — Ensure that a user for the container has been created
  • Medium IaC: CKV_DOCKER_7 tools/swagger/Dockerfile:2 — Ensure the base image uses a non latest version tag
  • Medium IaC: CKV_DOCKER_3 tools/swagger/Dockerfile:1 — Ensure that a user for the container has been created
  • Medium IaC: CKV_DOCKER_3 make/photon/core/Dockerfile.base:1 — Ensure that a user for the container has been created
D4 · Code Duplication · Duplicated block (11 lines × 2) · ×18
  • Duplicated block (11 lines × 2) src/controller/artifact/processor/image/manifest_v2.go:103 — src/controller/artifact/processor/image/manifest_v2.go:103-113 | src/controller/artifact/processor/wasm/wasm.go:119-129 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/controller/artifact/processor/image/manifest_v2.go:103` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (11 lines × 2) src/controller/event/handler/replication/replication.go:103 — src/controller/event/handler/replication/replication.go:103-113 | src/controller/event/handler/replication/replication.go:164-174 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/controller/event/handler/replication/replication.go:103` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (11 lines × 2) src/controller/gc/controller.go:133 — src/controller/gc/controller.go:133-143 | src/controller/gc/controller.go:151-161 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/controller/gc/controller.go:133` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (11 lines × 2) src/controller/replication/execution.go:233 — src/controller/replication/execution.go:233-243 | src/controller/replication/execution.go:270-280 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/controller/replication/execution.go:233` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (11 lines × 2) src/jobservice/job/impl/notification/slack_job.go:138 — src/jobservice/job/impl/notification/slack_job.go:138-148 | src/jobservice/job/impl/notification/webhook_job.go:122-132 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `src/jobservice/job/impl/notification/slack_job.go:138` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
  • Duplicated block (11 lines × 2) src/pkg/audit/dao/dao.go:167 — src/pkg/audit/dao/dao.go:167-177 | src/pkg/auditext/dao/dao.go:93-103 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/audit/dao/dao.go:167` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (11 lines × 2) src/pkg/cached/artifact/redis/manager.go:98 — src/pkg/cached/artifact/redis/manager.go:98-108 | src/pkg/cached/artifact/redis/manager.go:122-132 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/cached/artifact/redis/manager.go:98` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (11 lines × 2) src/pkg/cached/repository/redis/manager.go:91 — src/pkg/cached/repository/redis/manager.go:91-101 | src/pkg/cached/repository/redis/manager.go:115-125 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/cached/repository/redis/manager.go:91` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (11 lines × 2) src/pkg/reg/adapter/dockerhub/adapter.go:131 — src/pkg/reg/adapter/dockerhub/adapter.go:131-141 | src/pkg/reg/adapter/quay/adapter.go:153-163 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/reg/adapter/dockerhub/adapter.go:131` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (11 lines × 2) src/pkg/reg/adapter/githubcr/adapter.go:96 — src/pkg/reg/adapter/githubcr/adapter.go:96-107 | src/pkg/reg/adapter/huawei/huawei_adapter.go:273-283 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/reg/adapter/githubcr/adapter.go:96` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (11 lines × 2) src/pkg/reg/adapter/githubcr/adapter.go:202 — src/pkg/reg/adapter/githubcr/adapter.go:202-212 | src/pkg/reg/adapter/native/adapter.go:217-227 — 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. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (11 lines × 2) src/pkg/reg/adapter/harbor/v1/client.go:33 — src/pkg/reg/adapter/harbor/v1/client.go:33-43 | src/pkg/reg/adapter/harbor/v2/client.go:40-50 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/reg/adapter/harbor/v1/client.go:33` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (11 lines × 2) src/server/middleware/cosign/cosign.go:125 — src/server/middleware/cosign/cosign.go:125-135 | src/server/middleware/blob/put_manifest.go:70-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. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (11 lines × 2) src/server/v2.0/handler/preheat.go:262 — src/server/v2.0/handler/preheat.go:262-272 | src/server/v2.0/handler/preheat.go:295-305 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/v2.0/handler/preheat.go:262` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (11 lines × 2) src/server/v2.0/handler/project.go:646 — src/server/v2.0/handler/project.go:646-656 | src/server/v2.0/handler/scanner.go:149-159 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once.
  • Duplicated block (11 lines × 2) src/server/v2.0/handler/scanexport.go:115 — src/server/v2.0/handler/scanexport.go:115-125 | src/server/v2.0/handler/scanexport.go:164-174 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/v2.0/handler/scanexport.go:115` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (11 lines × 2) src/server/v2.0/handler/scanexport.go:135 — src/server/v2.0/handler/scanexport.go:135-145 | src/server/v2.0/handler/scanexport.go:232-242 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/v2.0/handler/scanexport.go:135` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (11 lines × 2) src/server/v2.0/handler/scanner.go:73 — src/server/v2.0/handler/scanner.go:73-83 | src/server/v2.0/handler/scanner.go:213-223 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/v2.0/handler/scanner.go:73` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (12 lines × 2) · ×14
  • Duplicated block (12 lines × 2) src/common/http/client.go:212 — src/common/http/client.go:212-223 | src/pkg/reg/adapter/gitlab/client.go:151-162 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/common/http/client.go:212` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (12 lines × 2) src/controller/artifact/processor/cnai/parser/license.go:44 — src/controller/artifact/processor/cnai/parser/license.go:44-55 | src/controller/artifact/processor/cnai/parser/readme.go:44-55 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `src/controller/artifact/processor/cnai/parser/license.go:44` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (12 lines × 2) src/controller/event/handler/replication/replication.go:70 — src/controller/event/handler/replication/replication.go:70-81 | src/controller/event/handler/replication/replication.go:130-141 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/controller/event/handler/replication/replication.go:70` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (12 lines × 2) src/controller/event/handler/webhook/artifact/replication.go:70 — src/controller/event/handler/webhook/artifact/replication.go:70-81 | src/controller/event/handler/webhook/artifact/retention.go:74-85 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `src/controller/event/handler/webhook/artifact/replication.go:70` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (12 lines × 2) src/controller/scan/base_controller.go:1055 — src/controller/scan/base_controller.go:1055-1066 | src/pkg/scan/vulnerability/vul.go:118-129 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/controller/scan/base_controller.go:1055` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (12 lines × 2) src/pkg/immutable/model/rule.go:52 — src/pkg/immutable/model/rule.go:52-63 | src/pkg/retention/policy/rule/models.go:52-63 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/immutable/model/rule.go:52` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (12 lines × 2) src/pkg/notification/policy/dao/dao.go:142 — src/pkg/notification/policy/dao/dao.go:142-153 | src/pkg/replication/dao/dao.go:118-129 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/notification/policy/dao/dao.go:142` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (12 lines × 2) src/pkg/reg/adapter/aliacr/adapter.go:336 — src/pkg/reg/adapter/aliacr/adapter.go:336-347 | src/pkg/reg/adapter/dockerhub/adapter.go:328-339 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/reg/adapter/aliacr/adapter.go:336` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (12 lines × 2) src/pkg/reg/adapter/dockerhub/adapter.go:414 — src/pkg/reg/adapter/dockerhub/adapter.go:414-425 | src/pkg/reg/adapter/dockerhub/adapter.go:441-452 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/reg/adapter/dockerhub/adapter.go:414` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
  • Duplicated block (12 lines × 2) src/pkg/reg/adapter/dtr/client.go:88 — src/pkg/reg/adapter/dtr/client.go:88-99 | src/pkg/reg/adapter/gitlab/client.go:144-155 — 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 (12 lines × 2) src/pkg/registry/client.go:182 — src/pkg/registry/client.go:182-193 | src/pkg/registry/client.go:229-240 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/registry/client.go:182` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
  • Duplicated block (12 lines × 2) src/pkg/registry/client.go:373 — src/pkg/registry/client.go:373-384 | src/pkg/registry/client.go:401-412 — 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. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
  • Duplicated block (12 lines × 2) src/pkg/registry/client.go:654 — src/pkg/registry/client.go:654-665 | src/registryctl/client/client.go:123-134 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/registry/client.go:654` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (12 lines × 2) src/pkg/retention/policy/rule/index/index.go:193 — src/pkg/retention/policy/rule/index/index.go:193-204 | src/pkg/retention/policy/rule/index/index.go:230-241 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/retention/policy/rule/index/index.go:193` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (9 lines × 2) · ×13
  • Duplicated block (9 lines × 2) src/controller/proxy/controller.go:310 — src/controller/proxy/controller.go:310-318 | src/controller/proxy/manifestcache.go:242-250 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `src/controller/proxy/controller.go:310` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
  • Duplicated block (9 lines × 2) src/pkg/exporter/statistics_collector.go:123 — src/pkg/exporter/statistics_collector.go:123-131 | src/server/v2.0/handler/statistic.go:65-73 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/exporter/statistics_collector.go:123` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (9 lines × 2) src/pkg/notification/policy/dao/dao.go:130 — src/pkg/notification/policy/dao/dao.go:130-138 | src/pkg/replication/dao/dao.go:59-67 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/notification/policy/dao/dao.go:130` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (9 lines × 2) src/pkg/reg/adapter/googlegcr/adapter.go:217 — src/pkg/reg/adapter/googlegcr/adapter.go:217-225 | src/pkg/reg/adapter/googlegcr/adapter.go:240-248 — 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. The matched lines also register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
  • Duplicated block (9 lines × 2) src/pkg/reg/adapter/huawei/huawei_adapter.go:197 — src/pkg/reg/adapter/huawei/huawei_adapter.go:197-205 | src/pkg/reg/adapter/huawei/image_registry.go:136-145 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
  • Duplicated block (9 lines × 2) src/pkg/user/dao/user.go:62 — src/pkg/user/dao/user.go:62-70 | src/pkg/user/dao/user.go:82-90 — 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. Note what the matched lines are: every one of them assigns one field to another, so the block is a hand-written mapper between two data shapes rather than behaviour with a helper inside it. Extracting one shared function only works if both sites map the SAME pair of types in the same direction — check that first, because inverse or differently-typed mappers have no single function they can both call. Where they do not, the moves that exist are a generated or reflective mapper, a common embedded/base type the fields live on once, or accepting the run and covering it with a test that fails when a field is added to one side only.
  • Duplicated block (9 lines × 2) src/server/v2.0/handler/artifact.go:112 — src/server/v2.0/handler/artifact.go:112-120 | src/server/v2.0/handler/project.go:751-759 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (9 lines × 2) src/server/v2.0/handler/artifact.go:322 — src/server/v2.0/handler/artifact.go:322-330 | src/server/v2.0/handler/artifact.go:365-373 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/v2.0/handler/artifact.go:322` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (9 lines × 2) src/server/v2.0/handler/base.go:200 — src/server/v2.0/handler/base.go:200-208 | src/server/v2.0/handler/base.go:218-226 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/v2.0/handler/base.go:200` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (9 lines × 2) src/server/v2.0/handler/permissions.go:87 — src/server/v2.0/handler/permissions.go:87-95 | src/server/v2.0/handler/permissions.go:98-106 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/v2.0/handler/permissions.go:87` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (9 lines × 2) src/server/v2.0/handler/project_metadata.go:52 — src/server/v2.0/handler/project_metadata.go:52-60 | src/server/v2.0/handler/project_metadata.go:121-129 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/v2.0/handler/project_metadata.go:52` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (9 lines × 2) src/server/v2.0/handler/repository.go:96 — src/server/v2.0/handler/repository.go:96-104 | src/server/v2.0/handler/repository.go:184-192 — 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) src/server/v2.0/handler/webhook.go:251 — src/server/v2.0/handler/webhook.go:251-259 | src/server/v2.0/handler/webhook.go:295-303 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/v2.0/handler/webhook.go:251` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D38 · OSV Dependency Vulnerabilities · Medium CVE · ×11
  • Medium CVE: [GHSA redacted] src/portal/package-lock.json — @sigstore/core 3.2.0: [GHSA redacted] — @sigstore/core is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin @sigstore/core to 3.2.1 with an `overrides` entry).
  • Medium CVE: [GHSA redacted] src/portal/package-lock.json — @sigstore/verify 3.1.0: [GHSA redacted] — @sigstore/verify is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin @sigstore/verify to 3.1.1 with an `overrides` entry).
  • Medium CVE: PYSEC-2026-2132 make/photon/prepare/Pipfile.lock — click 8.2.1: PYSEC-2026-2132 — upgrade to 8.3.3
  • Medium CVE: [GHSA redacted] src/portal/app-swagger-ui/package-lock.json — dompurify 3.4.8: [GHSA redacted] — dompurify is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin dompurify to 3.4.11 with an `overrides` entry). This is 1 of 3 advisories with a published fix this scan raises against dompurify 3.4.8, and their fixed versions do not agree — anything below 3.4.12 still leaves at least one of them open. Take this package to 3.4.12 or later: that is the floor for the package, not this row's target alone. This one row stands for the 3 advisories this scan raises against dompurify 3.4.8: [GHSA redacted], [GHSA redacted], [GHSA redacted].
  • Medium CVE: [GHSA redacted] src/portal/package-lock.json — echarts 5.6.0: [GHSA redacted] — upgrade to 6.1.0
  • Medium CVE: [GHSA redacted] src/portal/package-lock.json — http-proxy-middleware 2.0.9: [GHSA redacted] — http-proxy-middleware is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin http-proxy-middleware to 2.0.10 with an `overrides` entry).
  • Medium CVE: [GHSA redacted] src/portal/package-lock.json — launch-editor 2.13.2: [GHSA redacted] — launch-editor is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin launch-editor to 2.14.1 with an `overrides` entry).
  • Medium CVE: [GHSA redacted] make/photon/prepare/Pipfile.lock — pytest 8.4.1: [GHSA redacted] — upgrade to 9.0.3
  • Medium CVE: [GHSA redacted] src/portal/package-lock.json — qs 6.14.2: [GHSA redacted] — qs is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin qs to 6.15.2 with an `overrides` entry).
  • Medium CVE: [GHSA redacted] src/portal/package-lock.json — uuid 8.3.2: [GHSA redacted] — uuid is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (— 11.1.1 is a MAJOR ahead of the resolved 8.3.2, so an `overrides` pin would force a breaking version under a dependent written against 8.3.2; upgrading the declaring package is the remedy, and where no patched release exists in your major line, record the exposure instead).
  • Medium CVE: [GHSA redacted] src/portal/package-lock.json — webpack-dev-server 5.2.3: [GHSA redacted] — webpack-dev-server is not declared by the manifests that govern this lockfile: it is pulled in transitively here (the ^6.0.0 this repo declares for it belongs to a separate install root and does not reach this one), so upgrade the dependency that requires it (or pin webpack-dev-server to 5.2.4 with an `overrides` entry). This is 1 of 4 advisories with a published fix this scan raises against webpack-dev-server 5.2.3, and their fixed versions do not agree — anything below 5.2.6 still leaves at least one of them open. Take this package to 5.2.6 or later: that is the floor for the package, not this row's target alone. This one row stands for the 4 advisories this scan raises against webpack-dev-server 5.2.3: [GHSA redacted], [GHSA redacted], [GHSA redacted], [GHSA redacted].
D4 · Code Duplication · Duplicated block (10 lines × 2) · ×11
  • Duplicated block (10 lines × 2) src/controller/event/metadata/tag.go:39 — src/controller/event/metadata/tag.go:39-48 | src/controller/event/metadata/tag.go:66-75 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/controller/event/metadata/tag.go:39` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 2) src/core/auth/ldap/ldap.go:61 — src/core/auth/ldap/ldap.go:61-70 | src/core/auth/ldap/ldap.go:276-286 — 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. The matched lines also register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
  • Duplicated block (10 lines × 2) src/pkg/reg/adapter/dtr/adapter.go:156 — src/pkg/reg/adapter/dtr/adapter.go:156-165 | src/pkg/reg/adapter/jfrog/adapter.go:120-129 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/reg/adapter/dtr/adapter.go:156` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (10 lines × 2) src/server/middleware/repoproxy/proxy.go:140 — src/server/middleware/repoproxy/proxy.go:140-149 | src/server/middleware/repoproxy/proxy.go:309-318 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/middleware/repoproxy/proxy.go:140` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
  • Duplicated block (10 lines × 2) src/server/v2.0/handler/auditlog.go:105 — src/server/v2.0/handler/auditlog.go:105-114 | src/server/v2.0/handler/project.go:321-330 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once.
  • Duplicated block (10 lines × 2) src/server/v2.0/handler/gc.go:94 — src/server/v2.0/handler/gc.go:94-103 | src/server/v2.0/handler/gc.go:121-130 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/v2.0/handler/gc.go:94` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 2) src/server/v2.0/handler/preheat.go:379 — src/server/v2.0/handler/preheat.go:379-388 | src/server/v2.0/handler/preheat.go:684-693 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/v2.0/handler/preheat.go:379` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 2) src/server/v2.0/handler/robot.go:130 — src/server/v2.0/handler/robot.go:130-139 | src/server/v2.0/handler/robot.go:264-273 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/v2.0/handler/robot.go:130` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 2) src/server/v2.0/handler/robot.go:223 — src/server/v2.0/handler/robot.go:223-232 | src/server/v2.0/handler/robot.go:242-251 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/v2.0/handler/robot.go:223` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (10 lines × 2) src/pkg/reg/adapter/volcenginecr/helper.go:63 — src/pkg/reg/adapter/volcenginecr/helper.go:63-72 | src/pkg/reg/util/util.go:49-58 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/reg/adapter/volcenginecr/helper.go:63` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (10 lines × 2) src/server/middleware/blob/post_initiate_blob_upload.go:36 — src/server/middleware/blob/post_initiate_blob_upload.go:36-45 | src/server/middleware/blob/put_manifest.go:57-66 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/middleware/blob/post_initiate_blob_upload.go:36` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (8 lines × 2) · ×11
  • Duplicated block (8 lines × 2) src/controller/event/topic.go:177 — src/controller/event/topic.go:177-184 | src/controller/event/topic.go:208-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. Read the line range as the matched WINDOW rather than a finished unit: at `src/controller/event/topic.go:177` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (8 lines × 2) src/pkg/reg/adapter/dtr/client.go:105 — src/pkg/reg/adapter/dtr/client.go:105-112 | src/pkg/reg/adapter/dtr/client.go:160-167 — 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) src/pkg/reg/adapter/huawei/image_registry.go:51 — src/pkg/reg/adapter/huawei/image_registry.go:51-58 | src/pkg/reg/adapter/huawei/image_registry.go:222-229 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/reg/adapter/huawei/image_registry.go:51` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (8 lines × 2) src/server/middleware/repoproxy/proxy.go:399 — src/server/middleware/repoproxy/proxy.go:399-406 | src/server/middleware/repoproxy/proxy.go:449-456 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/middleware/repoproxy/proxy.go:399` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (8 lines × 2) src/server/v2.0/handler/label.go:77 — src/server/v2.0/handler/label.go:77-84 | src/server/v2.0/handler/label.go:147-154 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/v2.0/handler/label.go:77` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (8 lines × 2) src/server/v2.0/handler/model/gc.go:96 — src/server/v2.0/handler/model/gc.go:96-103 | src/server/v2.0/handler/purge.go:275-282 — 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) src/server/v2.0/handler/preheat.go:652 — src/server/v2.0/handler/preheat.go:652-659 | src/server/v2.0/handler/preheat.go:766-773 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/v2.0/handler/preheat.go:652` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (8 lines × 2) src/server/v2.0/handler/project.go:699 — src/server/v2.0/handler/project.go:699-706 | src/server/v2.0/handler/webhook.go:110-118 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (8 lines × 2) src/server/v2.0/handler/purge.go:84 — src/server/v2.0/handler/purge.go:84-91 | src/server/v2.0/handler/purge.go:312-319 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/v2.0/handler/purge.go:84` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (8 lines × 2) src/server/v2.0/handler/registry.go:93 — src/server/v2.0/handler/registry.go:93-102 | src/server/v2.0/handler/replication.go:208-215 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/v2.0/handler/registry.go:93` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (8 lines × 2) src/server/registry/route.go:54 — src/server/registry/route.go:54-61 | src/server/registry/route.go:62-69 — 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 (13 lines × 2) · ×10
  • Duplicated block (13 lines × 2) src/controller/quota/controller.go:227 — src/controller/quota/controller.go:227-239 | src/controller/quota/controller.go:297-309 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/controller/quota/controller.go:227` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (13 lines × 2) src/controller/scan/base_controller.go:1076 — src/controller/scan/base_controller.go:1076-1088 | src/pkg/scan/vulnerability/vul.go:139-151 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/controller/scan/base_controller.go:1076` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (13 lines × 2) src/pkg/artifact/manager.go:74 — src/pkg/artifact/manager.go:74-86 | src/pkg/artifact/manager.go:154-166 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/artifact/manager.go:74` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (13 lines × 2) src/pkg/audit/dao/dao.go:90 — src/pkg/audit/dao/dao.go:90-102 | src/pkg/auditext/dao/dao.go:159-171 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/audit/dao/dao.go:90` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (13 lines × 2) src/pkg/reg/adapter/dtr/client.go:146 — src/pkg/reg/adapter/dtr/client.go:146-159 | src/pkg/reg/adapter/dtr/client.go:227-239 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/reg/adapter/dtr/client.go:146` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (13 lines × 2) src/pkg/retention/policy/rule/dayspl/evaluator.go:78 — src/pkg/retention/policy/rule/dayspl/evaluator.go:78-90 | src/pkg/retention/policy/rule/daysps/evaluator.go:78-90 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/retention/policy/rule/dayspl/evaluator.go:78` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (13 lines × 2) src/server/v2.0/handler/preheat.go:705 — src/server/v2.0/handler/preheat.go:705-717 | src/server/v2.0/handler/webhook.go:266-278 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/v2.0/handler/preheat.go:705` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (13 lines × 2) src/server/v2.0/handler/preheat.go:789 — src/server/v2.0/handler/preheat.go:789-801 | src/server/v2.0/handler/webhook.go:310-322 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/v2.0/handler/preheat.go:789` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (13 lines × 2) src/server/v2.0/handler/replication.go:106 — src/server/v2.0/handler/replication.go:106-118 | src/server/v2.0/handler/replication.go:182-194 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/v2.0/handler/replication.go:106` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (13 lines × 2) src/pkg/reg/adapter/volcenginecr/volccr.go:229 — src/pkg/reg/adapter/volcenginecr/volccr.go:229-241 | src/pkg/reg/adapter/volcenginecr/volccr.go:273-285 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/reg/adapter/volcenginecr/volccr.go:229` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (7 lines × 2) · ×8
  • Duplicated block (7 lines × 2) src/core/controllers/base.go:77 — src/core/controllers/base.go:77-83 | src/core/controllers/base.go:121-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. Read the line range as the matched WINDOW rather than a finished unit: at `src/core/controllers/base.go:77` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (7 lines × 2) src/server/v2.0/handler/preheat.go:229 — src/server/v2.0/handler/preheat.go:229-235 | src/server/v2.0/handler/preheat.go:423-429 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/v2.0/handler/preheat.go:229` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (7 lines × 2) src/server/v2.0/handler/project_metadata.go:69 — src/server/v2.0/handler/project_metadata.go:69-75 | src/server/v2.0/handler/project_metadata.go:100-106 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/v2.0/handler/project_metadata.go:69` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (7 lines × 2) src/server/v2.0/handler/repository.go:230 — src/server/v2.0/handler/repository.go:230-236 | src/server/v2.0/handler/repository.go:248-254 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/v2.0/handler/repository.go:230` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (7 lines × 2) src/server/v2.0/handler/retention.go:222 — src/server/v2.0/handler/retention.go:222-230 | src/server/v2.0/handler/retention.go:300-306 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/v2.0/handler/retention.go:222` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (7 lines × 2) src/server/v2.0/handler/retention.go:301 — src/server/v2.0/handler/retention.go:301-307 | src/server/v2.0/handler/retention.go:358-364 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/v2.0/handler/retention.go:301` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (7 lines × 2) src/server/v2.0/handler/retention.go:316 — src/server/v2.0/handler/retention.go:316-322 | src/server/v2.0/handler/retention.go:346-352 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/v2.0/handler/retention.go:316` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (7 lines × 2) src/server/v2.0/handler/scanner.go:127 — src/server/v2.0/handler/scanner.go:127-136 | src/server/v2.0/handler/user.go:108-114 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/v2.0/handler/scanner.go:127` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (14 lines × 2) · ×6
  • Duplicated block (14 lines × 2) src/pkg/audit/dao/dao.go:182 — src/pkg/audit/dao/dao.go:182-195 | src/pkg/auditext/dao/dao.go:108-121 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/audit/dao/dao.go:182` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (14 lines × 2) src/pkg/project/dao/dao.go:59 — src/pkg/project/dao/dao.go:59-72 | src/testing/suite.go:170-183 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/project/dao/dao.go:59` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (14 lines × 2) src/pkg/reg/adapter/aliacr/adapter.go:356 — src/pkg/reg/adapter/aliacr/adapter.go:356-369 | src/pkg/reg/adapter/tencentcr/artifact_registry.go:130-145 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/reg/adapter/aliacr/adapter.go:356` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (14 lines × 2) src/pkg/reg/adapter/githubcr/adapter.go:181 — src/pkg/reg/adapter/githubcr/adapter.go:181-196 | src/pkg/reg/adapter/harbor/v1/adapter.go:83-96 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/reg/adapter/githubcr/adapter.go:181` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (14 lines × 2) src/pkg/p2p/preheat/provider/mock.go:44 — src/pkg/p2p/preheat/provider/mock.go:44-57 | src/pkg/p2p/preheat/provider/mock.go:96-109 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/p2p/preheat/provider/mock.go:44` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (14 lines × 2) src/pkg/p2p/preheat/provider/mock.go:71 — src/pkg/p2p/preheat/provider/mock.go:71-84 | src/pkg/p2p/preheat/provider/mock.go:123-136 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/p2p/preheat/provider/mock.go:71` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (6 lines × 2) · ×6
  • Duplicated block (6 lines × 2) src/controller/robot/controller.go:399 — src/controller/robot/controller.go:399-404 | src/server/v2.0/handler/user.go:443-448 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/controller/robot/controller.go:399` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (6 lines × 2) src/jobservice/job/impl/notification/slack_job.go:125 — src/jobservice/job/impl/notification/slack_job.go:125-130 | src/jobservice/job/impl/notification/webhook_job.go:102-107 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `src/jobservice/job/impl/notification/slack_job.go:125` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (6 lines × 2) src/server/v2.0/handler/artifact.go:401 — src/server/v2.0/handler/artifact.go:401-406 | src/server/v2.0/handler/artifact.go:443-448 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/v2.0/handler/artifact.go:401` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (6 lines × 2) src/server/v2.0/handler/replication.go:355 — src/server/v2.0/handler/replication.go:355-360 | src/server/v2.0/handler/replication.go:426-431 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/v2.0/handler/replication.go:355` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (6 lines × 2) src/server/v2.0/handler/scan.go:94 — src/server/v2.0/handler/scan.go:94-99 | src/server/v2.0/handler/scan.go:111-116 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/v2.0/handler/scan.go:94` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (6 lines × 2) src/server/v2.0/handler/user.go:266 — src/server/v2.0/handler/user.go:266-271 | src/server/v2.0/handler/usergroup.go:187-192 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `src/server/v2.0/handler/user.go:266` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
D4 · Code Duplication · Duplicated block (17 lines × 2) · ×5
  • Duplicated block (17 lines × 2) src/controller/p2p/preheat/controller.go:504 — src/controller/p2p/preheat/controller.go:504-520 | src/controller/p2p/preheat/enforcer.go:573-589 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `src/controller/p2p/preheat/controller.go:504` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (17 lines × 2) src/controller/scan/base_controller.go:1021 — src/controller/scan/base_controller.go:1021-1037 | src/pkg/scan/vulnerability/vul.go:179-195 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/controller/scan/base_controller.go:1021` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (17 lines × 2) src/pkg/reg/adapter/dtr/client.go:282 — src/pkg/reg/adapter/dtr/client.go:282-298 | src/pkg/reg/adapter/dtr/client.go:325-341 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/reg/adapter/dtr/client.go:282` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
  • Duplicated block (17 lines × 2) src/pkg/reg/adapter/jfrog/adapter.go:183 — src/pkg/reg/adapter/jfrog/adapter.go:183-199 | src/pkg/reg/adapter/native/adapter.go:155-171 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/reg/adapter/jfrog/adapter.go:183` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (17 lines × 2) src/pkg/registry/client.go:162 — src/pkg/registry/client.go:162-178 | src/pkg/registry/client.go:209-225 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/registry/client.go:162` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
D15 · Churn × Complexity Hotspots · Hotspot · ×4
  • Hotspot: src/server/middleware/repoproxy/proxy.go src/server/middleware/repoproxy/proxy.go — src/server/middleware/repoproxy/proxy.go changed 3 times in last 90 days, max complexity 22. 1 of those changes was a fix/bug commit, and the other 2 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, cover the area it touches with tests, 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.
  • Hotspot: src/pkg/auditext/event/member/member.go src/pkg/auditext/event/member/member.go — src/pkg/auditext/event/member/member.go changed 2 times in last 90 days, max complexity 21. 1 of those changes was a fix/bug commit, and the other 1 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, cover the area it touches with tests, 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.
  • Hotspot: src/pkg/registry/client.go src/pkg/registry/client.go — src/pkg/registry/client.go changed 2 times in last 90 days, max complexity 16. 1 of those changes was a fix/bug commit, and the other 1 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, cover the area it touches with tests, 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.
  • Hotspot: src/portal/src/app/base/left-side-nav/replication/replication/create-edit-rule/create-edit-rule.component.ts src/portal/src/app/base/left-side-nav/replication/replication/create-edit-rule/create-edit-rule.component.ts — src/portal/src/app/base/left-side-nav/replication/replication/create-edit-rule/create-edit-rule.component.ts changed 2 times in last 90 days, max complexity 15. 1 of those changes was a fix/bug commit, and the other 1 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, cover the area it touches with tests, 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.
D4 · Code Duplication · Duplicated block (15 lines × 2) · ×4
  • Duplicated block (15 lines × 2) src/pkg/p2p/preheat/provider/client/http_client.go:126 — src/pkg/p2p/preheat/provider/client/http_client.go:126-141 | src/pkg/p2p/preheat/provider/client/http_client.go:193-207 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/p2p/preheat/provider/client/http_client.go:126` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
  • Duplicated block (15 lines × 2) src/pkg/reg/adapter/dockerhub/adapter.go:232 — src/pkg/reg/adapter/dockerhub/adapter.go:232-246 | src/pkg/reg/adapter/quay/adapter.go:237-251 — 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. Read the line range as the matched WINDOW rather than a finished unit: at `src/pkg/reg/adapter/dockerhub/adapter.go:232` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns inste...

    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.