Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have an old legacy website that I have migrated to wordpress.

Some of the functionality will remain on the old server and be accessed via IP address, however this functionality requires a secure http connection and our current certificate is valid for the domain name which is being switched across.

I have added a redirect using mod_write to our htaccess file

Redirect /mySecurePage

However a warning is presented to user as certificate is registered to the domain name - the same domain name which now points to different ip (insecurely, and redirects to secure page on old server/different ip).

What is the best solution ?

I have full access to both servers, but wanted to avoid transferring the old functionality across to new server - its a right mess. Can I change the certificate, or do some fancy url rewriting ?

share|improve this question
up vote 1 down vote accepted

Add a subdomain and let this subdomain serves as the old legacy website.

Then replace the IP in the "Redirect" rule with the subdomain you created.

share|improve this answer
OK, I think I understand, thats very clever. – NimChimpsky Dec 18 '12 at 12:46
Wouldn't this only work if he has a wildcard certificate for the domain. If the cert is for than redirecting the request to still throws the SSL warning. – Peter Hahndorf Dec 18 '12 at 14:14
@PeterHahndorf I do have a wildcard certificate, it looks like it saved me a lot of headache. This answer is one of the best answers I have received on stack sites, I love the lateral thinking. – NimChimpsky Dec 18 '12 at 20:34


You can use the Redirect Option as already mentioned. You are correct that you will need to use a SSL certificate that matches the old domain exactly.

Often two single SSL certificates are cheaper than a wildcard.

Proxy Method

You can use a SSL Proxy on your new server to proxy traffic to the old system.

See the ProxyPass directives.

Also don't forget: SSLProxyEngine On

Unless you want to not add a new domain, I would opt for the redirect version. It is a much less complicated and simple implementation.

If the site is for internal use, just buy a cheap SSL certificate for that legacy domain.

share|improve this answer

Your Answer


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.