With caddy x509: certificate relies on legacy Common Name field, use SANs instead

1. Caddy version:

v2.6.2 h1:wKoFIxpmOJLGl3QXoo6PNbYvGW4xLEgo32GPBEjWL8o=

2. How I installed, and run Caddy:

Rpm install

a. System environment:

Red Hat Enterprise Linux release 8.7 (Ootpa)

b. Command:

c. Service/unit/compose file:

d. My complete Caddy config:

gitlab.ok.com {
        tls /etc/ssl/eamb.apicil.com.crt /etc/ssl/eamb.apicil.com.pem
        reverse_proxy /* https://gitlab.eamb.apicil.com:8443

3. The problem I’m having:

No show of gitlab

4. Error messages and/or full log output:

"msg":"x509: certificate relies on legacy Common Name field, use SANs instead","request":

5. What I already tried:

put in /etc/profile/

6. Links to relevant resources:

The error message is self explanatory. Your certificate isn’t valid. It needs to use the SubjectAlternativeNames field (SAN).

I know but in a work place i can changed the mistake of another people ^^

I don’t understand what you’re trying to say.

Either way, Caddy doesn’t support invalid certificates.

Specifically, CommonName has been deprecated for 23 years, and this error message comes from the Go standard library because it is no longer a supported field.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.