Skip to content

Use template for CA API (and configurable subject encoding) #2653

Description

@Gabgobie

Hello!

  • Vote on this issue by adding a 👍 reaction
  • If you want to implement this feature, comment to let us know (we'll work with you on design, scheduling, etc.)

Issue details

I am working with a constrained CA that uses the UTF-8 encoding. The name constraints dictate that the subject must be under one of two allowed base DNs.

  • DC=org,DC=example
  • O=Example Org,OU=Branch Office

To be valid, my leafs must use a subject like

O=Example Org,OU=Branch Office,CN=Webservice + for example SAN www.example.org

or

O=Example Org,OU=Branch Office,CN=www.example.org

As discussed in #1917, step-ca can only issue certificates using the PrintableString encoding, meaning all certificate are invalid.

Firefox rejects them with SEC_ERROR_CERT_NOT_IN_NAME_SPACE

My preferred fix would be to make the encoding either globally or per field configurable.

An alternative solution I have considered is the use of the subject.ExtraNames which seem to be a workaround for more complex DNs but I don't know how they are correctly used in the template.

Why is this needed?

Step CA is currently unable to issue valid certificates in my environment.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementneeds triageWaiting for discussion / prioritization by team

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions