Koozali.org: home of the SME Server

URL Redirection

Offline itguy2012

  • **
  • 23
  • +0/-0
URL Redirection
« on: October 12, 2012, 05:54:01 PM »
Hi, i wonder if someone can answer a quick question.
Is it posible to do url redirection?

By this i mean have two addresses, url1.abc.com and url2.abc.com and have them forwarded to different servers from the sme server.

Currently we have a port forwarding rule for 443 traffic to a server, but would like to send 443 traffic for the second url to a second server, so rather than port forward all 443 traffic to server 1 we would like to be able to distinguish the different urls and forward accordingly.

any ideas much appreciated.

Offline janet

  • *****
  • 4,812
  • +0/-0
Re: URL Redirection
« Reply #1 on: October 12, 2012, 07:34:40 PM »
itguy2012

Please read the available documentation starting from here:
http://wiki.contribs.org/Main_Page

Many questions are already answered and by doing some reading you will save yourself time

Then see the FAQ entry for Proxy Pass
http://wiki.contribs.org/SME_Server:Documentation:FAQ#Proxy_Pass

Please search before asking, an answer may already exist.
The Search & other links to useful information are at top of Forum.

Offline itguy2012

  • **
  • 23
  • +0/-0
Re: URL Redirection
« Reply #2 on: October 17, 2012, 01:09:08 PM »
thanks Mary that's useful, i'd had a quick look through the help but wasn't searching for the right term. Proxypass seems to be what i'm after.

Further to that...i've set up one of the domains using this, and over http works fine.
However using https there is a certificate error as it's using the certificate from the sme server - is this the desired effect with this, or is there a way to get it to get the certificate from the internal server itself.

(something that of course works using port forwarding but i want two different servers to be accessed over https)

thanks

Chris

Offline janet

  • *****
  • 4,812
  • +0/-0
Re: URL Redirection
« Reply #3 on: October 22, 2012, 05:53:59 AM »
itguy2012

A workaround is to incorporate all the certificates into the one certificate on the SME server
I'm not sure how proxypass is meant to behave here, other than current implementations supposedly support https.

Is the "problem" really at the client browser end ? ie if they install the self signed (or whichever) certificate or multiple domain certificate residing on SME server, then they will not get warnings on future accesses.

A further thought, upgrade to sme8.0, proxypass support might be better. Test first if critical to know.
« Last Edit: October 22, 2012, 05:57:24 AM by mary »
Please search before asking, an answer may already exist.
The Search & other links to useful information are at top of Forum.

Offline itguy2012

  • **
  • 23
  • +0/-0
Re: URL Redirection
« Reply #4 on: October 22, 2012, 12:58:35 PM »
Yes i was looking at the idea of combining the certificates into one and putting it on the sme server, that would in theory solve the issue.

It's not a problem at the client end as such but the server end not matching up (i.e the client is given a certificate from sme1 but url for the internal server, and traffic passed to internal-server1, the client therefore has a url that is on the internal server certificate but the certificate of the sme server which it throws out).
eg url - https://server1.domain.com
receives certificate that says sme.domain.com

If i can get the certifcates for the different uses i want combined then hopefully the proxy pass will work.

Ideally i was hoping to have the equivalent of port forwarding to route the traffic straight to the required servers, but different destinations for different urls, but i'm not sure this is actually feasible.


Offline janet

  • *****
  • 4,812
  • +0/-0
Re: URL Redirection
« Reply #5 on: October 23, 2012, 03:39:10 AM »
Please search before asking, an answer may already exist.
The Search & other links to useful information are at top of Forum.