Utilizing Wildcard Certificate for Subdomains 2nd and 3rd level

1. Caddy version (caddy version):


2. How I run Caddy:

caddy run

a. System environment:


b. Command:

paste command here

c. Service/unit/compose file:

paste full file contents here

d. My complete Caddyfile or JSON config:

paste config here, replacing this text
DO NOT REDACT anything except credentials

3. The problem I’m having:

I have wild card certificates for domain *.edjx.com, so I should be able to access sub1.edjx.com and sub1.sub2.edjx.com also.

subjectAltName does not match sub1.sub2.edjx.com

  • SSL: no alternative certificate subject name matches target host name sub1.sub2.edjx.com

4. Error messages and/or full log output:

5. What I already tried:

I have tried

                            "match": {
                                "sni": [

6. Links to relevant resources:

*.*.edjx.com isn’t a valid certificate. You can only have *.edjx.com or *.sub.edjx.com, *.sub2.edjx.com and so on. RFC 6125 specifies that the * must be in the left position and only one can exist per name.


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