certificates

package
v1.7.0-beta.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 21, 2022 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ExpectCARootCertificate

func ExpectCARootCertificate(certificate *cmapi.Certificate, secret *corev1.Secret) error

ExpectCARootCertificate checks if the CA cert is root CA if one is provided

func ExpectCertificateDNSNamesToMatch

func ExpectCertificateDNSNamesToMatch(certificate *cmapi.Certificate, secret *corev1.Secret) error

ExpectCertificateDNSNamesToMatch checks if the issued certificate has all DNS names it requested

func ExpectCertificateOrganizationToMatch

func ExpectCertificateOrganizationToMatch(certificate *cmapi.Certificate, secret *corev1.Secret) error

ExpectCertificateOrganizationToMatch checks if the issued certificate has the same Organization as the requested one

func ExpectCertificateURIsToMatch

func ExpectCertificateURIsToMatch(certificate *cmapi.Certificate, secret *corev1.Secret) error

ExpectCertificateURIsToMatch checks if the issued certificate has all URI SANs names it requested

func ExpectConditionReadyObservedGeneration

func ExpectConditionReadyObservedGeneration(certificate *cmapi.Certificate, secret *corev1.Secret) error

ExpectConditionReadyObservedGeneration checks that the ObservedGeneration field on the Ready condition which must be true, is set to the Generation of the Certificate.

func ExpectCorrectTrustChain

func ExpectCorrectTrustChain(certificate *cmapi.Certificate, secret *corev1.Secret) error

ExpectCorrectTrustChain checks if the cert is signed by the root CA if one is provided

func ExpectEmailsToMatch

func ExpectEmailsToMatch(certificate *cmapi.Certificate, secret *corev1.Secret) error

ExpectEmailsToMatch check if the issued certificate has all requested email SANs

func ExpectKeyUsageExtKeyUsageClientAuth

func ExpectKeyUsageExtKeyUsageClientAuth(certificate *cmapi.Certificate, secret *corev1.Secret) error

ExpectKeyUsageExtKeyUsageClientAuth checks if the issued certificate has the extended key usage of client auth

func ExpectKeyUsageExtKeyUsageServerAuth

func ExpectKeyUsageExtKeyUsageServerAuth(certificate *cmapi.Certificate, secret *corev1.Secret) error

ExpectKeyUsageExtKeyUsageServerAuth checks if the issued certificate has the extended key usage of server auth

func ExpectKeyUsageUsageDataEncipherment

func ExpectKeyUsageUsageDataEncipherment(certificate *cmapi.Certificate, secret *corev1.Secret) error

ExpectKeyUsageUsageDataEncipherment checks if a cert has the KeyUsageDataEncipherment key usage set

func ExpectKeyUsageUsageDigitalSignature

func ExpectKeyUsageUsageDigitalSignature(certificate *cmapi.Certificate, secret *corev1.Secret) error

UsageDigitalSignature checks if a cert has the KeyUsageDigitalSignature key usage set

func ExpectValidAdditionalOutputFormats added in v1.7.0

func ExpectValidAdditionalOutputFormats(certificate *cmapi.Certificate, secret *corev1.Secret) error

ExpectValidAdditionalOutputFormats assert that if additional output formats are requested It contains the additional output format keys in the secret and the content are valid.

func ExpectValidAnnotations

func ExpectValidAnnotations(certificate *cmapi.Certificate, secret *corev1.Secret) error

ExpectValidAnnotations checks if the correct annotations on the secret are present

func ExpectValidBasicConstraints

func ExpectValidBasicConstraints(certificate *cmapi.Certificate, secret *corev1.Secret) error

ExpectValidBasicConstraints asserts that basicConstraints are set correctly on issued certificates

func ExpectValidCertificate

func ExpectValidCertificate(certificate *cmapi.Certificate, secret *corev1.Secret) error

ExpectValidCertificate checks if the certificate is a valid x509 certificate

func ExpectValidCommonName

func ExpectValidCommonName(certificate *cmapi.Certificate, secret *corev1.Secret) error

ExpectValidCommonName checks if the issued certificate has the requested CN or one of the DNS SANs

func ExpectValidKeysInSecret added in v1.7.0

func ExpectValidKeysInSecret(_ *cmapi.Certificate, secret *corev1.Secret) error

ExpectValidKeysInSecret checks that the secret contains valid keys

func ExpectValidNotAfterDate

func ExpectValidNotAfterDate(certificate *cmapi.Certificate, secret *corev1.Secret) error

ExpectValidNotAfterDate checks if the issued certificate matches the requested duration

func ExpectValidPrivateKeyData

func ExpectValidPrivateKeyData(certificate *cmapi.Certificate, secret *corev1.Secret) error

ExpectValidPrivateKeyData checks of the secret's private key matches the request

Types

type ValidationFunc

type ValidationFunc func(certificate *cmapi.Certificate, secret *corev1.Secret) error

ValidationFunc describes a Certificate validation helper function

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL