Renewing SSL Certificate for an Azure Website

Having just renewed the SSL certificate responsible for allowing SSL/HTTPS access to our customer facing websites, I've just spent a little while grappling with how to apply the new certificate to our Windows Azure Website instances in place of the existing, soon to expire one.

Before getting to this point, there was a little head scratching in remembering how to convert the certificate provided by our registrar into a .pfx file as required by Microsoft Azure. Thanks to a couple of pieces of StackOverflow help, I got the certificate into a .pfx file and uploaded it into the Azure portal for the website in question.

I then attempted to remove the expiring certificate from the list by clicking the x button on the right hand side of the certificates listing as shown below:

Azure Website Certificate Renewal

Saving the configuration, resulted in a pretty non-descript error message informing me:

Updating the configuration for web site 'xyz' failed. Could not save changes for web site 'xyz'. Please try again. If the problem persists, contact support.

This left me frustrated but I went away for a while assuming it was a temporary Azure issue. When I returned to try again I received the same error.

I was about to file a support request when I saw the problem a little further down the page.

The SSL bindings section hadn't been amended to tell Azure to use the new certificate instead of the old one, thus, I couldn't remove the old certificate.

Setting the binding to be to the new certificate, which is no easy task since the expiry dates are cropped off in the dropdown box, I tried to remove the old certificate again which predictably failed.

As before though, it was my fault. We run several websites, all within the same Standard mode virtual machine and so I had to change the certificate to the new one, in the SSL bindings section in each site before I could delete the expiring certificate entry.

Easy when you know how!