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

Fixes for provenance attestations #3413

Merged
merged 5 commits into from
Dec 15, 2022
Merged

Conversation

tonistiigi
Copy link
Member

@tonistiigi tonistiigi commented Dec 15, 2022

  • Make sure same invocation ID is used for all platforms part of same build
  • Cut session identifiers from the provenance
  • Add Digestmapping to the provenance attestation. Instead of digests provenance uses more readable stepN names. But this means that build step can't be combined with the same step in the status logs or opentelemetry. To fix that I added a map that contains mapping from original LLB digests for each step.
  • Filter out cache imports. This may be improved in the future, but for now we want to make sure there is no leakage of cache backends that require authentication or type=local cache that is not reproducible.

Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
This allows matching spans from traces with provenance
and status records.

Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
@@ -233,6 +233,7 @@ func FilterArgs(m map[string]string) map[string]string {
"cgroup-parent": {},
"image-resolve-mode": {},
"platform": {},
"cache-imports": {},
Copy link
Member

Choose a reason for hiding this comment

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

Missing cache-exports?

Copy link
Member

Choose a reason for hiding this comment

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

In follow-up we could look also do smth smarter and detect if fields contain sensistive info, otherwise we keep them.

Copy link
Member Author

Choose a reason for hiding this comment

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

Frontends only have access to imports. Exports are handled directly by buildkit itself.

@tonistiigi tonistiigi merged commit a1befd5 into moby:master Dec 15, 2022
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.

None yet

3 participants