Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

Hello I have multiple test websites I host on an offsite server hosted by the company I work for. The websites are not really related to one another and so have different domain names. The machine has one IP address and I want to keep it that way.

I would like for example, two of the websites to have SSL enabled for specific pages. One website is testsite01 and the other testsite02. From the office I work from on our local DNS server we have two names testsite01 and testsite02 pointing to the offsite server. In IIS each of those sites are hosted on port 80 and have different host headers matching the ones specified above.

The problem is when I create two self signed certs through IIS and apply them to each website hosted on different ports as IIS doesn't allow multiple HTTPS sites running on 443. I decided to give testsite01 a HTTPS port 443 and testsite02 HTTPS port 444.

When I visit testsite01 and visit a secure page under that site login.aspx I get a cert warning as this is a self signed certificate and I land on the correct page login page with the https address in the browser address bar. When I go to testsite02 and try to go to the same and visit the login.aspx page of that site which should also be secured, I get taken to the secure login page of testsite001.

I'm having real trouble understanding why this is happening, perhaps it is because I am using self singed certs and SSL cannot be run on port 444. The reason I am trying to do this using self signed certs is because this i only for testing and we don't want to buy an expensive wilcard cert for this purpose.

Please could anyone help or advise me?

share|improve this question

migrated from stackoverflow.com Jun 1 '11 at 10:23

This question came from our site for professional and enthusiast programmers.

3 Answers 3

You can create a wildcard certificate with the IIS Resource Toolkit (called selfssl.exe) if you need it to last longer than (I think) the 30 days that the built-in certificate generator in IIS Manager gives you (don't recall off the top of my head where that is; believe it's under "Certificates" in the right-side panel). If not, just use the built-in one.

This self-signed wildcard certificate (*.example.com), once created and in the certificate store, can be assigned to all your sites under IIS under the Bindings that are configured with a corresponding host header.

share|improve this answer

It's likely not related to the cert. If the cert is bad, it will fail earlier than your description. When you created the binding for the 444 port (testsite002), did you make sure to select https instead of http for the protocol?

I assume that you're testing with https://testsite002:444. The port has to be explicitly used in the URL when it's not the default 443.

If it's "redirecting", it sounds like it's binding correctly, but then something else is causing a redirect. Do you have any URL Rewrite rules or anything else that would cause a redirect? Any code that would do it?

Try testing with a test.htm page, and with web.config temporary renamed (e.g. web.config_backup). That will avoid some common redirects for testing.

share|improve this answer

Check your redirects to make sure you're redirecting to https://testsite002:444

Also, you can setup each site to respond to different host headers and as long as DNS or a hosts file on a testing machine will go to the right IP, you can run both sites on 443.

Check out this youtube video for some instruction:http://www.youtube.com/watch?v=zVCmzBfx3BE

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.