[Webinar] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 616
  • Last Modified:

Force HTTP URL to HTTPS - IIS 6

I'm running Windows Server 2003 with IIS 6.
My default website is setup with SSL.
When you browse to https://yadayada.com it works fine.
When you browse to http://yadayada.com you are directed to a 403 Forbidden site.

If you browse to http, I would like them redirected to https.
I thought by modifying the custom error pages I could add a redirector within the html, but there is no 403 error site.  (see screen shot).

....help please
ss.jpg
0
sknoll84
Asked:
sknoll84
  • 4
  • 4
1 Solution
 
tigermattCommented:

You would need to create a page to use as the custom error. Something as simple as the HTML code I have attached would be fine.

You then need to associate that custom error page with the 403;4 HTTP Error which you see in the IIS console. This will ensure the redirect is performed when users hit your HTTP site and are prompted they must use HTTPS.

-Matt
<html>
<head>
<title>Redirecting...</title>
<meta name="refresh" http-equiv="refresh" content="1; url=https://yadayada.com" />
</head>
<body>
<!-- custom error page by tigermatt, Experts Exchange Q http://www.e-e.com/Q_24150190.html -->
Redirecting you...
</body>
</html>

Open in new window

0
 
sknoll84Author Commented:
problem still exists - I also performed an iisreset a number of times.
see attached screen shot.
ss1.jpg
0
 
tigermattCommented:

That error is not the one I would expect for the 'You can only connect using HTTPS' error. It's something different.

Is it the same IIS site which is configured for SSL as it is for port 80 HTTP traffic?

-Matt
0
Configuration Guide and Best Practices

Read the guide to learn how to orchestrate Data ONTAP, create application-consistent backups and enable fast recovery from NetApp storage snapshots. Version 9.5 also contains performance and scalability enhancements to meet the needs of the largest enterprise environments.

 
sknoll84Author Commented:
you mean this?
ss2.jpg
0
 
tigermattCommented:

Yes. It seems as though you only have one IIS website object which handles both the HTTP and HTTPS traffic. Therefore the error you are seeing is a little odd.

What happens if you enter http://yadayada.com/path_to_any_file.html into a browser. Does it come up then?
0
 
sknoll84Author Commented:
as suggested I tried what was mentioned above and it returned the same Forbidden error.
0
 
tigermattCommented:

Ok, can you take out the 'SSL required' mark and then retest?
0
 
sknoll84Author Commented:
thanks, it worked
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

  • 4
  • 4
Tackle projects and never again get stuck behind a technical roadblock.
Join Now