Skip to content

fix: [CI-23219]: remediate vulnerabilities in harnesssecure/github-actions#24

Closed
chhawchharia wants to merge 2 commits into
drone-plugins:mainfrom
chhawchharia:CI-23219
Closed

fix: [CI-23219]: remediate vulnerabilities in harnesssecure/github-actions#24
chhawchharia wants to merge 2 commits into
drone-plugins:mainfrom
chhawchharia:CI-23219

Conversation

@chhawchharia

@chhawchharia chhawchharia commented Jun 25, 2026

Copy link
Copy Markdown
Collaborator

Vulnerability Remediation: harnesssecure/github-actions

Fully resolves CI-23219.

This branch incorporates the dependency + base-image remediation from #23 (by the vuln-remediation bot) plus a required CI toolchain fix that #23 was missing, so it can be reviewed and merged as a single, complete, mergeable change. Supersedes #23.

Changes

File Change
docker/Dockerfile.linux.amd64 FROM docker:dindFROM docker:29.6.0-dind (latest stable dind; pins the previously-floating tag that was the source of the Alpine/openssl/git HIGHs); nektos/act v0.2.61v0.2.89 (latest release)
go.mod / go.sum go directive 1.22.71.25.0 + go get -u of flagged direct/transitive deps: golang.org/x/crypto, x/net, x/sys, x/exp; go-git/go-git/v5 5.13.1 → 5.19.1; go-billy/v5 5.6.1 → 5.9.0; ProtonMail/go-crypto 1.1.3 → 1.4.1; cloudflare/circl 1.3.7 → 1.6.4; cyphar/filepath-securejoin 0.3.6 → 0.7.0
.drone.yml build image golang:1.22.7golang:1.25.11 — required so CI can build the now-go 1.25.0 module cleanly (a 1.22 toolchain fails under GOTOOLCHAIN=local), and so the compiled plugin binary ships with a patched Go stdlib (incl. CVE-2025-47910).

CVE delta — Trivy (local scan)

Severity Before After Change
Critical 8 2 -6
High 100 41 -59
Medium 117 39 -78
Low 50 4 -46
Total 276 87 -189

Harness OnDemand (Snyk + PrismaCloud) collapses from thousands of paginated baseline findings to ~80 in the after image.

Verification

  • go build ./cmd
  • go test ./... ✅ (cloner + utils suites pass)
  • go mod verify
  • Built with Go 1.25.x.

Residual CVEs (upstream-blocked — not introduced by this PR)

8 advisories remain after the bump:

  • containerd/v2 v2.2.x + otel/sdk — shipped inside the docker:29.6.0-dind base via docker-compose/ctr. No docker:29.x-dind tag ships containerd ≥ 2.2.5 yet.
  • Go-stdlib CVE-2025-47910 in the prebuilt act binary — act v0.2.89 is built with Go 1.25.0; fixed only in Go 1.25.1+. Needs nektos to retag.

These can only be tracked upstream; bump the base image / act when fixed releases land.


Refs: baseline & after OnDemand scans linked in #23.

Made with Cursor

ci-vuln-bot and others added 2 commits June 24, 2026 04:20
…tions

- bump base image docker:dind -> docker:29.6.0-dind
- bump nektos/act v0.2.61 -> v0.2.89
- update go.mod toolchain + key dependencies (go-git, x/crypto, x/net, etc.)
The vuln remediation raised the go.mod directive to `go 1.25.0`, but the
.drone.yml build step still used `golang:1.22.7`. A 1.22 toolchain cannot
cleanly build a 1.25 module (auto-toolchain download is fragile and fails
under GOTOOLCHAIN=local), and it would compile the plugin binary with an
outdated Go stdlib, re-introducing stdlib CVEs into the image. Pin the build
image to the latest 1.25 patch (1.25.11), which also carries the stdlib fix
for CVE-2025-47910.

Co-authored-by: Cursor <cursoragent@cursor.com>
@chhawchharia

Copy link
Copy Markdown
Collaborator Author

Closing in favor of #23 to keep a single PR for CI-23219. The one missing piece (the .drone.yml build image golang:1.22.7 -> golang:1.25.11) has been posted as a review comment on #23 for the author to fold in: #23 (comment)

@chhawchharia

Copy link
Copy Markdown
Collaborator Author

Reopened as the complete, verified PR for CI-23219 (supersedes #23, which is missing the .drone.yml build-image bump). Full "no breaking changes" verification below.

Build & test

  • CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build ./cmd → OK
  • go test ./... → PASS (cloner, utils)
  • go vet ./... → clean
  • go mod verify → all modules verified

act v0.2.61 → v0.2.89 — CLI compatibility (runtime risk)

The plugin shells out to act (plugin.go), so flag removals wouldn't be caught by tests. Audited every flag the plugin passes against act v0.2.89 cmd/root.go — all still present:

Flag v0.2.89
-W / --workflows present
-P / --platform present
--secret-file present
--env-file present
-b / --bind present
--detect-event present
--container-options present
--actor present
--eventpath present
-v / --verbose present

Full image build (docker/Dockerfile.linux.amd64, --platform linux/amd64)

  • Base docker:29.6.0-dind pulls; apk add ca-certificates curl OK
  • act installer resolves + installs v0.2.89 for Linux/x86_64
  • act is on PATH at /bin/act (so exec.Command("act", …) resolves)
  • act --versionact version 0.2.89 (verified on a native run; the amd64-under-QEMU run crashes, which is an emulation artifact, not a defect)
  • plugin binary present at /bin/plugin

Reachable-CVE note (govulncheck)

The plugin binary has 11 reachable Go-stdlib CVEs when built with Go ≤1.25.5 (e.g. crypto/tls via cloner.Clone → git.PlainClone), all fixed by ≤1.25.9 — so the .drone.yml builder bump to golang:1.25.11 clears them.

No source changes were required; the toolchain, base-image, and act bumps are drop-in.

@chhawchharia

Copy link
Copy Markdown
Collaborator Author

Superseded by #25, which ships the identical changes from an origin branch (CI-23219) instead of a fork. Origin-branch PRs let Drone CI access build/publish secrets (docker_username/docker_password), which fork PRs are denied. Closing in favor of #25.

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