-
Notifications
You must be signed in to change notification settings - Fork 47
Description
This issue is to track the refactoring the certificate management code bits in follow-up PRs:
-
Return and handle error for
ValidityDurationcheck.
refs: https://github.com/etcd-io/etcd-operator/blob/main/internal/controller/utils.go#L572-L574
https://github.com/etcd-io/etcd-operator/blob/main/internal/controller/utils.go#L605-L607
AddAutoProvidercertificate manager #227 (comment)
Fix PR: Handle invalid ValidityDuration user input #253 -
Refactor Auto Cert Provider struct to include
userAutoConfig
refs: https://github.com/etcd-io/etcd-operator/blob/main/pkg/certificate/auto/provider.go#L34-L46
AddAutoProvidercertificate manager #227 (comment)
Fix PR: Include userAutoConfig in Auto Provider struct #255 -
Add
parseCert.NotBeforecheck for the CertManager and Auto provider validity.
refs: https://github.com/etcd-io/etcd-operator/blob/main/pkg/certificate/cert_manager/provider.go#L145-L147
https://github.com/etcd-io/etcd-operator/blob/main/pkg/certificate/auto/provider.go#L122-L124
AddAutoProvidercertificate manager #227 (comment)
Fix PR: Add parseCert.NotBefore check for certificate validation #254 -
Refactor interfaces definition and its usages to pass
ctrlruntimeclient.ObjectKeyinstead ofsecretName , namespacecombination. Refs: AddAutoProvidercertificate manager #227 (comment)
Fix PR: Refactor interfaces definition to usectrlruntimeclient.ObjectKey#252- EnsureCertificateSecret: https://github.com/etcd-io/etcd-operator/blob/main/pkg/certificate/interfaces/interface.go#L79
- ValidateCertificateSecret: https://github.com/etcd-io/etcd-operator/blob/main/pkg/certificate/interfaces/interface.go#L94C2-L94C27
- DeleteCertificateSecret: https://github.com/etcd-io/etcd-operator/blob/main/pkg/certificate/interfaces/interface.go#L107C2-L107C25
- RevokeCertificate: https://github.com/etcd-io/etcd-operator/blob/main/pkg/certificate/interfaces/interface.go#L118C2-L118C19
- GetCertificateConfig: https://github.com/etcd-io/etcd-operator/blob/main/pkg/certificate/interfaces/interface.go#L128C2-L128C22