Forum Index Search Forum Register Log in

Current

7.0 Production
build 6 Mar '07


7.1 Beta 5
build 7 Oct '07



A donation makes a contribution towards the time and effort that's going in to running this site.

Steffen

Contact:
My mail address is
at the top of the paypal form :

Your donations will help to keep this site alive and well.

Reverse Proxy

 
Post new topic   Reply to topic    Sambar Forum Index -> Lounge
View previous topic :: View next topic  
Author Message
JEMCOTECH



Joined: 20 Jun 2007
Posts: 5

PostPosted: Tue 15 Dec '09 1:34    Post subject: Reverse Proxy Reply with quote

Hello, I've been using Sambar for a while (mainly as a reverse proxy) and had a question. I have a internal server that I'd like to publish that is at, let say http://myserver.com:8080/dir/index.html. Now, I need sambar to "enter" at /dir/index.html. Is this possible? From my experience, sambar will only enter at http://myserver.com/index.html. Anyway, thanks for the help in advance.
Back to top
View user's profile
Johannes
Moderator


Joined: 27 Nov 2005
Posts: 145
Location: SK,Canada

PostPosted: Wed 16 Dec '09 3:24    Post subject: Reply with quote

Hello,

this is not an answer to your question but as you are using the Reverse Proxy with Sambar, I am a bit unsure how to enter the correct info for the "Destination server" in the admin area.

Lets assume the following:
2 machines running Sambar, both behind router with one external IP; Sambar A and Sambar B. Incoming requests forwarded to Sambar A ONLY.

setting up an Reverse Proxy on Sambar A using the admin area "Server > Create Revers Proxy"
Name: the domain name, say http://homesite.com
Destination Server: do I place here the IP of Sambar B ? or in which way do I say 'go to Sambar B' ?

Having said the above, homesite.com is setup as a virtual host on Sambar B.

That is the point where I am stuck. Could/Would you shed some light on this for me? I would appreciate it very much.

Thank you
Johannes
Back to top
View user's profile Visit poster's website
JEMCOTECH



Joined: 20 Jun 2007
Posts: 5

PostPosted: Wed 16 Dec '09 15:01    Post subject: Reply with quote

In my config, sambar sits in our server network, behind a monowall box. I open port 443 and point it to the sambar server (in monowall). In my network, we have a webmail server that lives at 192.168.0.20, so in sambar reverse proxy config, I enter webmail.mydomain.com as the host, http://192.168.0.20 as the path (destination). That's it. Now, 2 limitations; 1, this is not a desirable setup security wise. The proper way would be sambar outside the f/w, and open ports on the f/w to the hosts to be published. Set mac rules on f/w to only accept request from sambar machine and point sambar to f/w. And 2, if you need to pass host header to web server, then in path you would point to http://webmail.mydomain.internal, and set up a host file on the sambar proxy mapping to physical ip. Does this make any sense?

You know, I know this board is full the same minded people, but I just have to say it sucks sambar was discontinued. What a really wonderful product.
Back to top
View user's profile
rgibson



Joined: 20 Oct 2009
Posts: 26

PostPosted: Thu 17 Dec '09 0:05    Post subject: Reply with quote

just a thought on the reverse proxy /dir/index.htm question.

would creating a second vhost on the internal box, pointing to the /dir/
folder as the root. Then pointing the reverse proxy to the second vhost you just created.
vhost1 docs folder /docs/vhost1/www/
vhost2 docs folder /docs/vhost1/www/dir/
that way the root of vhost2 is actually the subfolder /dir of vhost1

P.S. You would have to make an entry in the XP hosts file of the reverse proxy box pointing to the internal box's IP like
vhost2name 192.168.0.20


Randy
Back to top
View user's profile
Johannes
Moderator


Joined: 27 Nov 2005
Posts: 145
Location: SK,Canada

PostPosted: Thu 17 Dec '09 0:28    Post subject: Reply with quote

Thank you Jemcotech for the good explanation.
I will have a chance in a few weeks to try the Reverse Proxy with my Sambar dev.-machine. Will try both ways.

Happens by chance that I am running monowall too, a HD-less hardware firewall. Nice application. Smile

Quote:
it sucks sambar was discontinued. What a really wonderful product.

You are correct, and that is exactly the reason why I am still using it, running 15 vhosts of which 2 are using the Sambar blog (a bit customised) publicy.

Johannes

PS: would you be willing to share your e-mail? If so, use the contact form on my website.
Back to top
View user's profile Visit poster's website

Post new topic   Reply to topic    Sambar Forum Index -> Lounge
Page 1 of 1