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.

I am using a hosted wiki service which runs over SSL, I have a CNAME redirect from my subdomain to it but browsers show a message saying it is being redirected.

Is there a way I can get around this? My host and the hosted site's tech are disagreeing on what to do (basically each is saying the other needs to do something)

The current set up is:

http://wiki.mydomain.org --> https://mydomain.externalhost.org

Any and all suggestions would be very much appreciated :)

edit

The server that my domain on is running Apache, I'm not sure about the external hosts (sorry I'm not so clued up technically as to versions etc)

Within my DNS panel it states: This CNAME record will point wiki.appsforgood.org to appsforgood.onconfluence.com.

I should explain I proposed installing a SSL cert on the wiki sub-domain but my hosts said this wouldn't stop the error message and it should installed at the external hosts server. Of course the external hosts say it needs to be installed on the wiki sub-domain leaving me banging my head on the table trying to get a definitive answer

share|improve this question

migrated from stackoverflow.com Aug 18 '11 at 12:59

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

    
Please add some informations about used webserver. Also this seems to be a serverfault question. –  Thomas Berger Aug 18 '11 at 11:17
2  
If, when you type http://wiki.mydomain.com in your browser, you get redirected to https://mydomain.externalhost.com, you're probably not using a CNAME (DNS) alias from wiki.mydomain.com to mydomain.externalhost.com. Instead, it looks like there's a website at wiki.mydomain.com that performs an HTTP redirection (e.g. 302) to the other site (that would be necessary to change from http:// to https:// as well). –  Bruno Aug 18 '11 at 11:19
add comment

1 Answer

You are using a CNAME. The problem is that the SSL Certificate is issued for the domain name you're CNAME is pointing to.

To explain where the "problem" is:

  1. Someone types into their browser wiki.example.com.
  2. The browser gets the IP address of that domain name (jumping through the CNAME, but the browser knows nothing of the CNAME, DNS does this behind the scenes, the browser just gets the IP back) and connects.
  3. The browser and server it connects to start the SSL negotiation process. The SSL Certificates says "Hi, I'm example.externalhost.com"
  4. The browser see that the server is using a different name than what the user typed in. Throws warning.

What you want is a server to pickup the wiki.example.com and do a Redirect (CNAMEs are NOT redirects). The redirecting server would say "Hi, I'm wiki.example.com; you need to go connect to example.externalhost.com". A browser would see the initial matching name, so no warning, then proceed to connect to the new host (which would also match the name, so no warning).

share|improve this answer
    
Thanks Chris, forgive my ignorance but what would be the easiest way to accomplish that? I dread trying to ask my host in case they send me off on a wild goose chase –  Mr Omneo Aug 18 '11 at 14:08
    
I'm not sure what solution you've got running. Host providers will usually let you setup a virtual host for the wiki.example.com site, then setup a 301 Redirect on that. If you call your provider and tell them that, they'll know exactly what you're talking about. –  Chris S Aug 18 '11 at 14:13
    
Thanks Chris, I'll throw that at them and see how helpful they are :) –  Mr Omneo Aug 18 '11 at 14:35
    
I suspect both CNAME and a redirect are currently in action in the OP's problem. He's typing http://wiki.mydomain.org, not https://. While the CNAME will effectively resolve wiki.mydomain.org to mydomain.externalhost.org, it won't change the protocol. It's likely that there is (a) a CNAME from wiki.mydomain.org to mydomain.externalhost.org and an HTTP redirect from http://wiki.mydomain.org (or the default server on that IP address if it's not configured for that particular host) to https://mydomain.externalhost.org. The certificate needs to match the target host name. –  Bruno Aug 19 '11 at 11:38
    
@Chris S, your description of the problem would be right for a certificate that doesn't match the host name in the URL. However, this didn't seem to be the OP's problem, rather it seems to be about "a message saying it is being redirected", which would almost certainly come from some HTTP-based redirect before any HTTPS connection, and this doesn't seem to be a certificate warning message. –  Bruno Aug 19 '11 at 11:42
show 2 more comments

Your Answer

 
discard

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.