I have a website running under IIS which has an SSL certificate applied. We would like to enforce HTTPS usage for the website which is easily done by checking the “Require Secure Channel” box, but this will immediately break the ability for people to connect over HTTP (as designed).
What I’d like to do is find a way to automatically redirect people from HTTP -> HTTPS if they type in the wrong thing (or connect from an old bookmark).
Is there a way to do this without creating a second website in IIS?
If you need to do it at the server level then you will have to create another site and have it forward the the https site.
If you can edit the code, you can not enforce ssl at the server level, instead you can do it in your website by detecting if the url starts with http: and redirecting to the same url with https: instead.