You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/modules/secret-operator/pages/secretclass.adoc
+26Lines changed: 26 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -40,6 +40,31 @@ CAUTION: Attributes of the certificate (such as the expiration date, fingerprint
40
40
41
41
xref:scope.adoc[Scopes] are used to populate the claims (such as `subjectAlternateName`) of the provisioned certificates.
42
42
43
+
[#backend-autotls-byo-ca]
44
+
==== Providing your own certificate authority
45
+
46
+
Instead of letting the Secret Operator generate a certificate authority, you can provide your own.
47
+
A common reason to do this is verifying the TLS certificate of an external service such as an LDAP or S3 server: you create a SecretClass that holds that service's CA certificate and reference it from the product CRD (see xref:concepts:tls-server-verification.adoc[]).
48
+
49
+
Store the CA certificate (in PEM format) in a Secret under the key `ca.crt`:
Then reference that Secret from a SecretClass and set `autoGenerate: false`:
57
+
58
+
[source,yaml]
59
+
----
60
+
include::example$secretclass-byo-ca.yaml[]
61
+
----
62
+
<1> The Secret created above. It must contain the CA certificate under the key `ca.crt`.
63
+
<2> Disable CA generation so that the provided CA is used as-is instead of generating a new one.
64
+
65
+
When the SecretClass is only used to *verify* servers and does not issue any certificates, the Secret needs nothing but `ca.crt`, the `ca.key` entry can be omitted.
66
+
If you also want the Secret Operator to issue certificates signed by this CA, the Secret must additionally contain the private key under `ca.key`.
67
+
43
68
[#backend-tls-certificate-key-pair-generation]
44
69
==== `TLS certificate key pair generation`
45
70
@@ -132,6 +157,7 @@ spec:
132
157
`autoTls.ca`:: Configures the certificate authority used to issue `Pod` certificates.
133
158
`autoTls.ca.secret`:: Reference (`name` and `namespace`) to a K8s `Secret` object where the CA certificate and key is stored in the keys `ca.crt`
134
159
and `ca.key` respectively.
160
+
When the SecretClass is only used to verify servers (see xref:#backend-autotls-byo-ca[]), only `ca.crt` is required and `ca.key` may be omitted.
135
161
`autoTls.ca.autoGenerate`:: Whether the certificate authority should be provisioned and managed by the Secret Operator.
136
162
`autoTls.ca.caCertificateLifetime` :: The lifetime of the certificate authority's root certificate.
137
163
`autoTls.ca.caCertificateRetirementDuration` :: Duration at the end of the CA certificate lifetime where no signed certificate will exist.
0 commit comments