Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Enabling SSL on localhost IIS

I run localhost on my Windows 8.1 (Bootcamp on Mac) and need to enable ssl.

I have already default server certificates on 127.0.0.1 and localhost. I have the localhost one assigned to my websites on port 443.

https still returns security error so I need to work on http

My websites run on 44300 port (eg. localhost:44300) I tried to bind the certificate to 44300, still it didn't work.

How to make my locahost to work with https? Thanks

enter image description here

enter image description here

enter image description here

EDIT

The certificate is issued by localhost and is within Trusted Root Certification Authorities:

enter image description here

Btw I followed this thread to issue the certificate for my website: Enable SSL in Visual Studio

like image 276
nickornotto Avatar asked May 14 '15 14:05

nickornotto


People also ask

Can SSL work with localhost?

Good News: SSL Certificates Can Work for Localhost The good news is, it's very much possible to get an SSL certificate working for your localhost. It might not be an SSL certificate verified and issued by a trusted certificate authority (CA), but you can make it work.


1 Answers

It is probably because it is not installed in Trusted Root Certification Authorities.

enter image description here

Solve this by starting mmc.exe.

Then go to:

File -> Add or Remove Snap-ins -> Certificates -> Add -> Computer account -> Local computer

Expand the Personal folder and you will see your localhost certificate:

enter image description here

Copy this into Trusted Root Certification Authorities - Certificates

The final step is to open Internet Information Services (IIS) Manager or simply inetmgr.exe. From there go to your site, select Bindings... and Add... or Edit.... Set https and select your certificate from the drop down.

enter image description here

Your certificate is now trusted:

enter image description here

Original answer:

https://stackoverflow.com/a/48790088/3850405

like image 111
Ogglas Avatar answered Sep 18 '22 13:09

Ogglas