Skip to content

chore(deps): bump Go to 1.25.9 [security] (release-1.20)#965

Closed
phisco wants to merge 1 commit intocrossplane:release-1.20from
phisco:chore/bump-go-1.25.9-release-1.20
Closed

chore(deps): bump Go to 1.25.9 [security] (release-1.20)#965
phisco wants to merge 1 commit intocrossplane:release-1.20from
phisco:chore/bump-go-1.25.9-release-1.20

Conversation

@phisco
Copy link
Copy Markdown
Contributor

@phisco phisco commented Apr 15, 2026

Description of your changes

Mirrors #961 for release-1.20, adapted for Earthly.

govulncheck reports 5 reachable stdlib vulnerabilities on this branch
with the current Go 1.23.7 toolchain (same CVE set as release-2.0 and
release-2.1):

ID Package
GO-2026-4947 crypto/x509 (chain-building DoS)
GO-2026-4946 crypto/x509 (policy validation)
GO-2026-4870 crypto/tls (KeyUpdate DoS)
GO-2026-4865 html/template (XSS)
GO-2026-4601 net/url

Both Go 1.23 and Go 1.24 went end-of-life before the April 2026
security batch (1.23 EOL: 2025-08-12 when 1.25.0 shipped; 1.24 EOL:
2026-02-10 when 1.26.0 shipped). The latest 1.23 release (1.23.12)
does not contain these fixes and none will be backported. Fixing them
requires moving off the 1.23 line entirely.

This PR therefore jumps straight to Go 1.25.9 — a two-minor bump —
updating both the Earthfile toolchain and the `go.mod` directive.
The now-redundant `toolchain go1.23.7` line is dropped.

Alternatives worth considering before merging:

  • Is release-1.20 still receiving patches? If it's effectively
    archived, we could mark these CVEs as won't-fix on this branch.
  • A smaller jump to Go 1.24.x would not help — also EOL, no CVE fixes.
  • If a minor bump is too intrusive but the CVEs are a blocker, we
    could bump only `Earthfile`'s `GO_VERSION` and leave `go.mod`
    untouched, keeping library consumers unaffected.

Fixes #

I have:

govulncheck reports five reachable stdlib vulnerabilities on this branch
at the current Go 1.23.7 toolchain, in crypto/x509, crypto/tls, html/
template and net/url. Both Go 1.23 and Go 1.24 went end-of-life before
the April 2026 security batch (1.23 on 2025-08-12 when 1.25.0 shipped,
1.24 on 2026-02-10 when 1.26.0 shipped). The fixes only exist in Go
1.25.9 and 1.26.2, and no backport will be made.

This commit therefore does a two-minor-version bump to 1.25.9, in both
the Earthfile toolchain and the go.mod directive. The separate
toolchain directive is dropped since the go directive now matches.

Signed-off-by: Philippe Scorsolini <5697904+phisco@users.noreply.github.com>
@phisco phisco requested a review from a team as a code owner April 15, 2026 16:05
@phisco phisco requested review from negz and removed request for a team April 15, 2026 16:05
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Apr 15, 2026

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: a8126803-f4f3-4b5d-9e84-74922582ea08

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@phisco
Copy link
Copy Markdown
Contributor Author

phisco commented Apr 15, 2026

Closing as won't-fix.

Bumping Go to 1.25.9 on this branch hits two compounding issues that each
require non-trivial work well beyond a Go bump:

  1. golangci-lint v1 → v2 migration. GOLANGCI_LINT_VERSION on this
    branch is v1.64.8, on the v1.x line, built with Go ≤ 1.24. It refuses
    to lint code declaring go 1.25.9. The v2.x line (the only line still
    receiving releases) ships a new .golangci.yml config format, so a
    bump requires a config migration.

  2. x/tools v0.24.0 incompatibility with Go 1.25. check-diff's
    go generate fails with invalid array length -delta * delta from
    golang.org/x/tools@v0.24.0/internal/tokeninternal/tokeninternal.go.
    This requires bumping x/tools (and likely controller-gen, which
    pulls it in) in go.mod — a dep sweep on an old branch.

Given release-1.20 is three minor versions behind main and the 5 reachable
CVEs do not have backports in the 1.23 Go line (and won't: Go 1.23 EOL'd
on 2025-08-12, Go 1.24 on 2026-02-10), the cost/benefit of a full chain of
fixes here is poor. Tracking these CVEs as won't-fix on release-1.20.

Consumers on release-1.20 who care about the stdlib fixes should upgrade
to release-2.0 or later (#964 / #963 / #966 / #961).

@phisco phisco closed this Apr 15, 2026
phisco added a commit to phisco/crossplane-runtime that referenced this pull request Apr 17, 2026
…ports

This unblocks the security dep bumps queued for release-1.20:

* crossplane#918 - golang.org/x/net v0.45.0 (CVE-2025-47911, CVE-2025-58190; first
  patched version is v0.45.0 which declares `go 1.24.0` in its go.mod)
* crossplane#971 - google.golang.org/grpc v1.79.3 (CVE-2026-33186; also declares
  `go 1.24.0`)

Both deps require `go >= 1.24.0` so `go mod download` fails on this
branch under the pinned `GOTOOLCHAIN=local` with Go 1.23.7. Bumping the
`go` directive to `1.24.0` and the toolchain to the latest 1.24.x patch
(1.24.13) is the minimum change needed to unblock the backports.

Staying on the 1.24 line (not 1.25) deliberately avoids the golangci-lint
v1 -> v2 migration and `x/tools v0.24.0` incompatibility that blocked
the earlier 1.25 attempt (see crossplane#965). `go mod tidy`, `go build ./...`,
and `go vet ./...` are all clean; no code changes are needed.

Signed-off-by: Philippe Scorsolini <5697904+phisco@users.noreply.github.com>
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