Debian Codegraph @

verifier/models/token_options.go

raw
1 // Package models contains models needed in client and server
2 package models
3
4 // TokenOptions contains fields that will be passed to the Attestation Service TokenOptions field.
5 // These fields are used to customize several claims in the token from the Attestation service.
6 type TokenOptions struct {
7 Audience string `json:"audience"`
8 Nonces []string `json:"nonces"`
9 TokenType string `json:"token_type"`
10 PrincipalTagOptions *AWSPrincipalTagsOptions `json:"aws_principal_tag_options"`
11 }
12
13 // AWSPrincipalTagsOptions represents the options for the AWSPrincipalTag token type.
14 type AWSPrincipalTagsOptions struct {
15 AllowedPrincipalTags *AllowedPrincipalTags `json:"allowed_principal_tags"`
16 }
17
18 // AllowedPrincipalTags allows for requestors to configure what principal tags are contained in the
19 // resulting GCA token.
20 type AllowedPrincipalTags struct {
21 ContainerImageSignatures *ContainerImageSignatures `json:"container_image_signatures"`
22 }
23
24 // ContainerImageSignatures represents the configuration for AllowedPrincipalTags for
25 // ContainerImageSignature claims
26 type ContainerImageSignatures struct {
27 KeyIDs []string `json:"key_ids"`
28 }