Skip to content

⬆️ fix(deps): raise Go to 1.26.6 to clear 7 called stdlib advisories - #296

Merged
konih merged 2 commits into
mainfrom
fix/perf-fix-06-go-toolchain
Aug 16, 2026
Merged

konih merged 2 commits into
mainfrom
fix/perf-fix-06-go-toolchain

Conversation

@konih

@konih konih commented Aug 16, 2026

Copy link
Copy Markdown
Collaborator

PERF-FIX-06

task vulncheck was red on clean main — 7 standard-library vulnerabilities with called paths, all Fixed in: go1.26.6. Reachable traces named by govulncheck included internal/inventory/server.go:77 (Server.Start → ListenAndServe), internal/sink/s3/backend.go:111 (Backend.Export → xml.Decoder), and internal/sink/mongodb/backend.go:136 (Backend.Close).

Because these are stdlib advisories, the fix is a toolchain bump, not a dependency bump.

Two places had to move together

File Why
go.mod go directive → 1.26.6 CI resolves Go via go-version-file: go.mod, so this covers every workflow at once
Dockerfile + Dockerfile.pipeline (golang:1.26.5 → 1.26.6, digest-pinned) Left alone, the shipped image keeps compiling against the vulnerable stdlib while go.mod claims otherwise. The released binary is what users run.

Verification

  • task vulncheck → exit 0, "No vulnerabilities found" (was 7 called)
  • task test:run → exit 0, all packages ok
  • go build ./... → exit 0

The one remaining advisory is in a required module with no called path — the pre-existing SR-2026-06 exception already documented in docs/SECURITY-REVIEW.md.

Note

vulncheck is not one of protect-main's required checks (preflight, test, kind-smoke, Analyze (Go)) — which is precisely how it stayed red without blocking anything. It is a CI job and is now green.

PERF-FIX-06. `task vulncheck` was red on clean `main` with 7 standard-library
vulnerabilities that this code actually calls -- reachable paths named by
govulncheck included `inventory.Server.Start`, `s3.Backend.Export`, and
`mongodb.Backend.Close`. All seven are `Fixed in: go1.26.6`.

Because these are stdlib advisories, the fix is a toolchain bump, not a
dependency bump. Two places had to move together:

- `go.mod` `go` directive 1.26.5 -> 1.26.6. CI resolves its Go version via
  `go-version-file: go.mod`, so this covers every workflow at once.
- `Dockerfile` and `Dockerfile.pipeline` pin `golang:1.26.5` by digest. Left
  alone, the *shipped image* would keep compiling against the vulnerable
  stdlib while `go.mod` claimed otherwise -- the released binary, not the
  local one, is what users run.

`task vulncheck` now exits 0 (0 called vulnerabilities, down from 7). The one
remaining advisory is in a required module with no called path, which is the
pre-existing SR-2026-06 exception already documented in docs/SECURITY-REVIEW.md.

Note `vulncheck` is not one of protect-main's required checks, which is how it
stayed red unnoticed; it is a CI job and is now green.
@codecov

codecov Bot commented Aug 16, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

…uilds

Independent review of the 1.26.6 bump caught that `.devcontainer/devcontainer.json`
still pinned `golang:1.26.4`. That drift was pre-existing -- it was already
behind `main`'s 1.26.5 -- but raising the `go.mod` floor converts it from stale
to fatal: the official golang image sets `GOTOOLCHAIN=local`, so the devcontainer
cannot silently fetch a newer toolchain and instead hard-fails with

    go: go.mod requires go >= 1.26.6 (running go 1.26.5; GOTOOLCHAIN=go1.26.5)

Pin it to the same digest the Dockerfiles use, so the three cannot drift apart
again without it being visible in one grep.

Also correct `docs/development/setup.md`, which advertised a 1.26.4+ floor.
@sonarqubecloud

Copy link
Copy Markdown

@konih
konih merged commit 71bf197 into main Aug 16, 2026
36 checks passed
@konih
konih deleted the fix/perf-fix-06-go-toolchain branch August 16, 2026 06:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant