Skip to content

gcs: Expose transparency-trust-list-base64 in security-context based on injected TTLs - #2991

Open
Tingmao Wang (micromaomao) wants to merge 1 commit into
microsoft:mainfrom
micromaomao:ttl-in-security-context
Open

Tingmao Wang (micromaomao) wants to merge 1 commit into
microsoft:mainfrom
micromaomao:ttl-in-security-context

Conversation

@micromaomao

Copy link
Copy Markdown
Member

In order to enable the application to provide with a relying party a full set of transparent endorsements, we also expose a "first party" TTL in the security context that we believe allows verification of the transparent UVM reference info and TCB reference info. Such a TTL will be delivered via the fragment injection mechanism like for TTLs for transparent fragments, and GCS identifies such a TTL via hard-coded issuer and subject strings. When such a TTL is injected, it is used to populate the transparency-trust-list-base64 file on next container start.

Using it as the content of transparency-trust-list-base64 is the only "special treatment" applied to such TTLs. GCS does not otherwise give it any more trust than allowed by the policy.

COSE signature and issuer certificate checks are applied to all injected TTLs, before this matching is done. A malformed or not-correctly-signed TTL would not be used for the security context file even if the COSE envelope header claims the correct issuer and subject.

Assisted-by: GitHub-Copilot

…on injected TTLs

In order to enable the application to provide with a relying party a full
set of transparent endorsements, we also expose a "first party" TTL in the
security context that we believe allows verification of the transparent
UVM reference info and TCB reference info.  Such a TTL will be delivered
via the fragment injection mechanism like for TTLs for transparent
fragments, and GCS identifies such a TTL via hard-coded issuer and subject
strings.  When such a TTL is injected, it is used to populate the
transparency-trust-list-base64 file on next container start.

Using it as the content of transparency-trust-list-base64 is the only
"special treatment" applied to such TTLs.  GCS does not otherwise give it
any more trust than allowed by the policy.

COSE signature and issuer certificate checks are applied to all injected
TTLs, before this matching is done.  A malformed or not-correctly-signed
TTL would not be used for the security context file even if the COSE
envelope header claims the correct issuer and subject.

Assisted-by: GitHub-Copilot
Signed-off-by: Tingmao Wang <tingmaowang@microsoft.com>

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🟡 Changes recommended

The new first-party TTL selection and export path lacks regression coverage for matching, SVN ordering, invalid-input cache preservation, and export behavior after policy rejection or in TTL-only cases.

1 open issue
What changed in this PR

This PR exposes an injected first-party transparency trust list (TTL) in the container security context, allowing applications to provide it alongside reference information to relying parties without granting it additional policy trust.

Changes:

  • Defines the transparency-trust-list-base64 filename.
  • Caches validated TTLs matching designated issuer/subject pairs, retaining the highest received SVN.
  • Exports the cached COSE bytes as base64 when creating a container’s security context.
File Description
pkg/​securitypolicy/​securitypolicy.go Adds the TTL security-context filename constant.
pkg/​securitypolicy/​securitypolicy_options.go Adds TTL matching, synchronized caching, SVN ordering, and security-context export.

Review effort: Balanced

Comment on lines +413 to +415
if len(s.transparencyTrustList) == 0 || s.transparencyTrustListSVN <= *svnFromCwt {
s.transparencyTrustList = append(s.transparencyTrustList[:0], raw...)
s.transparencyTrustListSVN = *svnFromCwt
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.

3 participants