Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New subject-checksums input param #198

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

bdehamer
Copy link
Collaborator

Adds support for a new subject-checksums input parameter which allows the user to identify the attestation subjects by passing the path of the checksums file.

This enables direct integration with tools like goreleaser, jreleaser, and the sha*sum suite of tools which generate a checksums file.

@bdehamer bdehamer requested a review from a team as a code owner January 15, 2025 19:17
@bdehamer bdehamer force-pushed the bdehamer/subject-checksums branch from 77a6ee2 to 7802356 Compare January 15, 2025 19:43
@bdehamer bdehamer force-pushed the bdehamer/subject-checksums branch from 7802356 to d8c307e Compare January 15, 2025 20:17
}

/* istanbul ignore next */
if (stats.size > MAX_SUBJECT_CHECKSUM_SIZE_BYTES) {

Choose a reason for hiding this comment

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

Love this check ❤️

@@ -151,3 +225,14 @@ const parseList = (input: string): string[] => {

return res.filter(item => item).map(pat => pat.trim())
}

const digestAlgorithm = (digest: string): string => {

Choose a reason for hiding this comment

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

Should we also verify that the digest is of expected format (hex encoded) too, and fail early if not?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Good idea. Added a check to ensure the digest is a hex string.

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.

2 participants