Repository navigation
Use a username as a CN... forbidden? #2770
|
I am trying to get client certificates issued with this template: That I am then calling with I have policies in place to only allow certain hostnames: what should I do to allow also plain usernames, that I can use to authenticate my functional accounts, to be used as CN? |
Answered by
CasperKristiansson
Aug 24, 2026
Replies: 1 comment 3 replies
|
Your policy allows DNS names and email addresses, but the certificate's Subject CN is checked separately. Add the literal CN with the step ca policy authority x509 allow cn "svc-k3s" \
--admin-cert=stepca/data/admin.crt \
--admin-key=stepca/data/admin.keyUse the exact CN shown in the CA error—it reports |
3 replies
Answer selected by
flixman
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Your policy allows DNS names and email addresses, but the certificate's Subject CN is checked separately. Add the literal CN with the
cnpolicy action:step ca policy authority x509 allow cn "svc-k3s" \ --admin-cert=stepca/data/admin.crt \ --admin-key=stepca/data/admin.keyUse the exact CN shown in the CA error—it reports
svc-k3s, notsvc_k3s—and keep the existing email rule for the SAN. Smallstep's CN matcher is exact and case-insensitive, and*is not supported for Common Names, so each functional-account CN needs an explicit entry.