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: CHANGELOG.md
+2
Original file line number
Diff line number
Diff line change
@@ -14,11 +14,13 @@ All notable changes to this project will be documented in this file.
14
14
- Use new annotation builder ([#341]).
15
15
-`autoTLS` certificate authorities will now be rotated regularly ([#350]).
16
16
-[BREAKING] This changes the format of the CA secrets. Old secrets will be migrated automatically, but manual intervention will be required to downgrade back to 23.11.x.
17
+
-`autoTLS` certificate authority lifetimes are now configurable ([#357]).
Copy file name to clipboardExpand all lines: deploy/helm/secret-operator/crds/crds.yaml
+9
Original file line number
Diff line number
Diff line change
@@ -47,6 +47,15 @@ spec:
47
47
default: false
48
48
description: Whether the certificate authority should be managed by Secret Operator, including being generated if it does not already exist.
49
49
type: boolean
50
+
caCertificateLifetime:
51
+
default: 730d
52
+
description: |-
53
+
The lifetime of each generated certificate authority.
54
+
55
+
Should always be more than double `maxCertificateLifetime`.
56
+
57
+
If `autoGenerate: true` then the Secret Operator will prepare a new CA certificate the old CA approaches expiration. If `autoGenerate: false` then the Secret Operator will log a warning instead.
58
+
type: string
50
59
secret:
51
60
description: Reference (name and namespace) to a Kubernetes Secret object where the CA certificate and key is stored in the keys `ca.crt` and `ca.key` respectively.
Copy file name to clipboardExpand all lines: docs/modules/secret-operator/pages/secretclass.adoc
+4-2
Original file line number
Diff line number
Diff line change
@@ -62,8 +62,8 @@ Users can use podOverrides to extend the certificate lifetime by adding volume a
62
62
63
63
Certificate authorities also have a limited lifetime, and need to be rotated before they expire to avoid cluster disruption.
64
64
65
-
If configured to provision its own CA (`autoTls.ca.autoGenerate`), the Secret Operator will create CA certificates that are valid for 2 years,
66
-
and initiate rotation when there is less than 1 year remaining. If configured _not_ to provision its own CA, a warning will be issued when there is less than 1 year remaining.
65
+
If configured to provision its own CA (`autoTls.ca.autoGenerate`), the Secret Operator will create CA certificates that are valid for 2 years (`autoTls.ca.caCertificateLifetime`),
66
+
and initiate rotation once less than half of that time remains. If configured _not_ to provision its own CA, a warning will instead be issued in that case.
67
67
68
68
To avoid disruption and let the new CA propagate through the cluster, the Secret Operator will prefer using the oldest CA that will last for the entire lifetime of the issued certificate.
69
69
@@ -81,6 +81,7 @@ spec:
81
81
name: secret-provisioner-tls-ca
82
82
namespace: default
83
83
autoGenerate: true
84
+
caCertificateLifetime: 700d
84
85
maxCertificateLifetime: 15d # optional
85
86
----
86
87
@@ -89,6 +90,7 @@ spec:
89
90
`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`
90
91
and `ca.key` respectively.
91
92
`autoTls.ca.autoGenerate`:: Whether the certificate authority should be provisioned and managed by the Secret Operator.
93
+
`autoTls.ca.caCertificateLifetime` :: The lifetime of the certificate authority's root certificate.
92
94
`autoTls.maxCertificateLifetime`:: Maximum lifetime the created certificates are allowed to have. In case consumers request a longer lifetime than allowed by this setting, the lifetime will be the minimum of both.
0 commit comments