Skip to content

Verify drone-ssh binary checksum after download#410

Open
and9000 wants to merge 1 commit intoappleboy:masterfrom
and9000:verify-drone-ssh-checksum
Open

Verify drone-ssh binary checksum after download#410
and9000 wants to merge 1 commit intoappleboy:masterfrom
and9000:verify-drone-ssh-checksum

Conversation

@and9000
Copy link
Copy Markdown

@and9000 and9000 commented May 2, 2026

Problem

entrypoint.sh downloads the drone-ssh binary from GitHub releases over HTTPS but never verifies its integrity. If the release artifact is replaced or corrupted, the action silently executes the tampered binary — and since this action runs SSH commands with credentials against remote hosts, that's a meaningful supply-chain risk for every workflow consuming appleboy/ssh-action.

Summary

  • Download checksums.txt from the drone-ssh release alongside the binary and verify it with shasum -c --ignore-missing before chmod'ing the binary executable.
  • Verification only runs on fresh downloads — cached binaries (already executable from a prior run) are not re-verified, avoiding an extra checksums.txt fetch on every invocation.

Download checksums.txt from the drone-ssh release alongside the binary and verify it. Protects against tampered or corrupted release artifacts.
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