validations

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Nov 24, 2020 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Expect2Or3KeysInSecret

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

Expect2Or3KeysInSecret checks if the secret resource has the correct amount of fields in the secret data

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 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 ExpectValidAnnotations

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

ExpectValidAnnotations checks if the correct annotations on the secret are present

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 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

This section is empty.

Jump to

Keyboard shortcuts

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