Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetAthenzIdentity ¶ added in v1.11.36
func GetAthenzIdentity(athenzDomain, athenzService, athenzProvider, ztsUrl string, sanDNSDomains []string, spiffeTrustDomain string, csrSubjectFields util.CsrSubjectFields) (*util.SiaCertData, error)
GetAthenzIdentity this method can be called from within a GCF (Google Cloud Function) - to get an Athenz certificate from ZTS. See https://cloud.google.com/functions/docs/writing/write-http-functions#http-example-go
func StoreAthenzIdentityInSecretManager ¶ added in v1.11.36
func StoreAthenzIdentityInSecretManager(athenzDomain, athenzService, secretName string, siaCertData *util.SiaCertData) error
StoreAthenzIdentityInSecretManager store the retrieved athenz identity in the specified secret. The secret is stored in the following json format:
{ "<domain>.<service>.cert.pem":"<x509-cert-pem>, "<domain>.<service>.key.pem":"<pkey-pem>, "ca.cert.pem":"<ca-cert-pem>, "time": <utc-timestamp> }
The secret specified by the name must be pre-created and the service account that the function is invoked with must have been authorized to assume the "Secret Manager Secret Version Adder" role
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.