App Services incorrectly refuse setting SSL certificates

Bear 20 Reputation points
2025-01-29T13:50:28.3133333+00:00

I have a certificate installed (Cloudflare Origin certificate), which has an wildcard domain as *.example.com

I can successfully use this certificate for Web App Service custom domain, auth.example.com.

However, when I tried to bind this certificate to another slot which has custom domain auth.staging.example.com, I got

Failed to configured SSL Binding for auth.staging.example.com with <hash> The certificate with thumbprint '<hash>' does not match the hostname 'auth.staging.example.com'.

Since it is a wildcard certificate, the refusal seems incorrect.

Azure App Service
Azure App Service
Azure App Service is a service used to create and deploy scalable, mission-critical web apps.
8,257 questions
{count} votes

Accepted answer
  1. Laxman Reddy Revuri 2,315 Reputation points Microsoft Vendor
    2025-01-31T15:31:39.8066667+00:00

    Hi @bear bear
    apologize for any inconvenience caused on this.
    I'm glad that you were able to resolve your issue and thank you for posting your solution so that others experiencing the same thing can easily reference this! Since the Microsoft Q&A community has a policy that "The question author cannot accept their own answer. They can only accept answers by others ", I'll repost your solution in case you'd like to accept the answer
    Ask: App Services incorrectly refuse setting SSL certificates
    Solution: After some research, it seems the Azure Web Apps only allow the wildcard certificate to cover one level of the subdomains, i.e., xxx.example.com, yyy.example.com, but not aaa.bbb.example.com

    Uploading another wildcard certificate which covers *.staging.example.com will enable domains such as auth.staging.example.com.

    The behaviors is expected, as explained in https://serverfault.com/questions/104160/wildcard-ssl-certificate-for-second-level-subdomain
    Please don’t forget to Accept Answer and Yes for "was this answer helpful" wherever the information provided helps you, this can be beneficial to other community members. 

    0 comments No comments

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.