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

Architect a "Verified Reproducible Build Attestation" #3950

Open
Tracked by #3948
andrew-m-leonard opened this issue Sep 24, 2024 · 10 comments
Open
Tracked by #3948

Architect a "Verified Reproducible Build Attestation" #3950

andrew-m-leonard opened this issue Sep 24, 2024 · 10 comments
Assignees
Labels
secure-dev testing Issues that enhance or fix our test suites

Comments

@andrew-m-leonard
Copy link
Contributor Author

@tellison @smlambert fyi

@andrew-m-leonard andrew-m-leonard changed the title Architect a "Reproducible Build Attestation" Architect a "Verified Reproducible Build Attestation" Sep 24, 2024
@smlambert
Copy link
Contributor

Also:

@tellison
Copy link
Contributor

Sigstore seems to be a center of gravity in the secure supply chain processes.
We should seriously consider using the formats supported by Rekor to be able to use that infrastructure downstream.

@andrew-m-leonard
Copy link
Contributor Author

Sigstore seems to be a center of gravity in the secure supply chain processes. We should seriously consider using the formats supported by Rekor to be able to use that infrastructure downstream.

An interesting read, this is what I understand from reading their various docs:

  • CoSign's primary aim is in providing signing of "containers" stored in an OCI Registry.
  • CoSign signing process is usually interactive involving opening of a Browser window for Identity verification during the signing
  • CoSign keyless signing uses Rekor attestation ledger allowing "Signature" to be "verified" against the Rekor ledger entry identity and timestamp, hence does not require a "key"
  • Rekor provides a append only transparency log, for things like attestations
  • Rekor provide a public server: https://rekor.sigstore.dev

I take from that we could maybe:

@smlambert
Copy link
Contributor

smlambert commented Sep 25, 2024

in-toto/attestation#82
in-toto/attestation#129

@andrew-m-leonard
Copy link
Contributor Author

andrew-m-leonard commented Sep 26, 2024

in-toto/attestation#82 in-toto/attestation#129

Thanks Shelley, I am going to follow up with some questions to in-toto in their Slack (https://cloud-native.slack.com/archives/CM46K2VT2/p1727340094818479)

@andrew-m-leonard
Copy link
Contributor Author

Further research, and references:

@andrew-m-leonard
Copy link
Contributor Author

andrew-m-leonard commented Sep 26, 2024

Option 1:

I am currently thinking of this outline architecture:

  1. Temurin build (temurin-build) constructs a CycloneDX CDXA "provenance" attestation document at the end of the build along side the existing SBOM document, and links the SBOM->CDXA. The "Adoptium signed" CDXA will state the "provenance" of the built JDK tarball from an Adoptium "Producer" perspective, ie. something along the lines of a statement with evidence of "reproducible build", eg. binary hashes, and a "re-build" reproducible build evidence log?? Both SBOM and CDXA are published at release time.
  2. A 3rd party performs a successful "Reproducible Verification Build", and creates their own "3rd party signed" consumer CDXA "provenance" attestation document, which documents their statement of evidence of "reproducible build" for the given Temurin release JDK tarball. The 3rd party then publishes this CDXA attestation document to the Adoptium marketplace: https://adoptium.net/marketplace/.
  3. The last step by the Adoptium community as a consequence of a 3rd party publishing a "consumer" CDXA, is to run a "Verify" step, which compares the "producer" CDXA with the "consumer" CDXA, comparing the references and evidence, and upon success then lists the given 3rd party as "attesting" to the reproducibility of the given Temurin JDK release. This last step could also update a "reference", maybe a "bom-link" in the Temurin SBOM, to reference the "verified" consumer CDXA, the "version" number of the SBOM would be incremented by 1, as with accordance to the "CycloneDX Authorative Guide to SBOMs".

Future:

  • Add capability of 3rd party uploading a CycloneDX CDXA document to the public Sigstore Rekor instance, and allowing the step(3) "Verify" stage to reference the Rekor transparency log entry. The "bom-link" would then reference the Rekor entry.
  • Leverage in-toto producer policy auditing in the Adoptium CI build&test pipelines to sign the various stage completions eg.checkout, compile, smokeTest, aqaTest,..., package...

@andrew-m-leonard
Copy link
Contributor Author

From talking to members of the in-toto community, their suggestion points to looking at https://github.com/in-toto/witness
Which from the front cover looks a possibility.

@andrew-m-leonard
Copy link
Contributor Author

Option 2:

  • Temurin ci.adoptium.net pipeline produces an in-toto attestation of reproducible-build provenance using the in-toto-witness tooling
  • 3rd party performs a Temurin re-build, and produces their own in-toto attestation using in-toto-witness
  • Eclipse Adoptium runs an in-toto-policy verification using in-toto-witness that verifies the Adoptium attestation and the 3rd party attestation evidence matches, to attest the claim of an independent Verified Reproducible Build

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
secure-dev testing Issues that enhance or fix our test suites
Projects
Status: In Progress
Development

No branches or pull requests

3 participants