Skip to content

http: add support for checksum requests and pgp signatures for http sources#6527

Merged
tonistiigi merged 2 commits intomoby:masterfrom
tonistiigi:http-checksum-pgp
Feb 20, 2026
Merged

http: add support for checksum requests and pgp signatures for http sources#6527
tonistiigi merged 2 commits intomoby:masterfrom
tonistiigi:http-checksum-pgp

Conversation

@tonistiigi
Copy link
Copy Markdown
Member

These requests allow computing additional checksum algorithms
for the payload of HTTP sources.

Optionally, a suffix can be passed that is added to the payload. This
is needed to make validation of PGP signatures possible remotely.

Add detached PGP verification for HTTP sources during metadata resolution
and expose LLB options/caps/attrs for signature validation.

Extract shared OpenPGP verification/parsing logic into util/pgpsign and
reuse it from git signing, plus add integration and source-level tests.

If preferred, I can open these individually to ease review. I'm mostly interested in the first commit. Second is more for consistency with the Git source.

Comment on lines +613 to +614
default:
return pb.ChecksumRequest_CHECKSUM_ALGO_SHA256
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This fallback silently rewrites invalid/unsupported checksum algorithms instead of rejecting them. Could hide client bugs no?

Can we either return an error for unknown values or pass through the raw enum value so the server-side validation can reject it explicitly?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated

These requests allow computing additional checksum algorithms
for the payload of HTTP sources.

Optionally suffix can be passed that is added to payload. This
is needed to make validation of PGP signatures possible remotely.

Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Add detached PGP verification for HTTP sources during metadata resolution
and expose LLB options/caps/attrs for signature validation.

Extract shared OpenPGP verification/parsing logic into util/pgpsign and
reuse it from git signing, plus add integration and source-level tests.

Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
@tonistiigi tonistiigi merged commit 6aac08d into moby:master Feb 20, 2026
189 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants