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

Attestations docs #3260

Merged
merged 2 commits into from
Dec 5, 2022
Merged

Attestations docs #3260

merged 2 commits into from
Dec 5, 2022

Conversation

jedevc
Copy link
Member

@jedevc jedevc commented Nov 8, 2022

This PR adds two pieces of documentation:

  • A user-facing guide to how to enable and use attestations (to likely be later migrated to the buildx repository, once we implement an appropriate user-facing syntax). For now this includes SBOM documentation, but we can later expand this to also include SLSA provenance info (Support for provenance attestations #3240).
  • A developer-facing guide for how the SBOM scanning protocol works, which should be useful for anyone building custom integrations down the road.

docs/attestations.md Outdated Show resolved Hide resolved
docs/attestations.md Outdated Show resolved Hide resolved
docs/attestations.md Outdated Show resolved Hide resolved
docs/attestations.md Outdated Show resolved Hide resolved
--opt build-arg:SBOM_SCAN_CONTEXT=true \
--opt attest:sbom=generator=jedevc/buildkit-syft-scanner
```

Copy link
Member

Choose a reason for hiding this comment

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

We could show a snippet of how the SPDX content actually looks like.

How to add custom packages to SBOM using the nested SBOM technique.

How to read the layer info from the SPDX record.

Copy link
Member Author

Choose a reason for hiding this comment

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

  1. Added an SPDX snippet ✔️
  2. This is scanner-specific behaviour - we should document this in the scanner itself, since a scanner may not include this information. Also, this behaviour isn't fully implemented in syft, and is partially blocked on SBOM cataloger anchore/syft#1029. ✖️
  3. Added info on the layer data ✔️

Copy link
Member Author

Choose a reason for hiding this comment

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

Copy link
Member

Choose a reason for hiding this comment

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

Does the default scanner support the nested files now that the PR looks to be merged?

I think this should be documented in the regular sbom docs like the Dockerfile ARGs. This is something that we expect the users to know and modify their Dockerfiles to get better sboms. We can mention that this works in default scanner and if user uses custom scanner then it is up to that implementation to decide if it is supported.

Copy link
Member Author

Choose a reason for hiding this comment

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

Ahh, so yes syft has merged it, but it's not made into a release.

I think we should aim to follow syft releases for buildkit-syft-scanner, instead of building off of master?

Copy link
Member

Choose a reason for hiding this comment

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


> **Note**
>
> Currently, only SBOMs in the [SPDX](https://spdx.dev) JSON format are
Copy link
Member

Choose a reason for hiding this comment

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

Follow-up: could we use some labels to track what is supported so we have a upgrade path?

Copy link
Member Author

Choose a reason for hiding this comment

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

I assume you mean in the image labels? Yup, I'll do a follow-up 😄

docs/sbom-protocol.md Outdated Show resolved Hide resolved
docs/attestations.md Outdated Show resolved Hide resolved
docs/attestations.md Outdated Show resolved Hide resolved
@jedevc
Copy link
Member Author

jedevc commented Nov 9, 2022

Added do-not-merge label - this PR documents functionality that is added in:

Additionally, we need to move jedevc/buildkit-syft-scanner to another location 😄

Signed-off-by: Justin Chadwell <me@jedevc.com>
Signed-off-by: Justin Chadwell <me@jedevc.com>
Copy link
Member

@crazy-max crazy-max left a comment

Choose a reason for hiding this comment

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

LGTM

@jedevc jedevc merged commit 9624ab4 into moby:master Dec 5, 2022
@jedevc jedevc deleted the attestations-docs branch December 5, 2022 15:09
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.

None yet

4 participants