Keep Server Online
If you find the Apache Lounge, the downloads and overall help useful, please express your satisfaction with a donation.
or
A donation makes a contribution towards the costs, the time and effort that's going in this site and building.
Thank You! Steffen
Your donations will help to keep this site alive and well, and continuing building binaries. Apache Lounge is not sponsored.
| |
|
Topic: Mod_proxy How do I specify which external ip to use |
|
Author |
|
dustinhigh
Joined: 18 Apr 2010 Posts: 1
|
Posted: Sun 18 Apr '10 16:11 Post subject: Mod_proxy How do I specify which external ip to use |
|
|
I have looked all over the place and can't find anything on this (at least that I am able to understand and modify to meet m
y needs). I have an ubuntu vps running apache2. I have to external ip addresses I can use. I want to set up proxy servers so I can access the internet through my vps and specify which external ip address to use. I also don't want any Via headers or X_forwarded_for headers (I don't want sites to know I am accessing them via a proxy).
What I have setup now:
I enabled apache2 mod_proxy and have this in my /etc/apache2/sites-enabled/proxy.conf:
Code: | <IfModule mod_proxy.c>
#turning ProxyRequests on and allowing proxying from all may allow
#spammers to use your proxy to send email.
ProxyRequests On
<Proxy *>
AddDefaultCharset off
Order deny,allow
Deny from all
Allow from 127.0.0.1
#Allow from .example.com
</Proxy>
# Enable/disable t
he handling of HTTP/1.1 "Via:" headers.
# ("Full" adds the server version; "Block" removes all outgoing Via: headers)
# Set to one of: Off | On | Full | Block
ProxyVia Block
</IfModule> |
Now I am able to connect via my local machine using putty to ssh and create a tunnel through a port that I choose. I set up my browser (Firefox) to access through a socks proxy at localhostot using the port that I set up the tunnel and am able to access the internet using my vps ip.
The problem: I can't seem to set it up to use the second ip of my vps when I want to use that instead (sometimes simultaneously using one local cpu for the first addess and a second cpu for the second address). Even if I tunnel through putty to the second ip, the first ip address is always displayed as my external ip address when accessing the internet. I can't seem to find any information anywhere about this. If you could help or point me in the right direction, that would be great.
Edit: I should also specify that the two local computers will be accessing the same types of data (mostly http) simultaneously. |
|
Back to top |
|
James Blond Moderator
Joined: 19 Jan 2006 Posts: 7371 Location: Germany, Next to Hamburg
|
Posted: Fri 04 Jun '10 15:24 Post subject: |
|
|
For the x forward see proxypreservehost and proxyvia. IMHO you already use proxyvia correct.
If you want to use a specific external IP you can use IP based vhosts and use two Listen and put the proxy in a vhost with the second IP.
e.g
Listen 1.2.3.4:80
Listen 1.2.3.5:8080 |
|
Back to top |
|
|
|
|
|
|