Apache as proxy for the web

This is a discussion on Apache as proxy for the web within the Apache Web Server forums, part of the Web Server and Related Forums category; Hi all, I need to config Apache so that every request that is coming is redirected to the www. I'...


Go Back   Usenet Forums > Web Server and Related Forums > Apache Web Server

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 07-21-2003
Francesco M.
 
Posts: n/a
Default Apache as proxy for the web

Hi all,
I need to config Apache so that every request that is coming
is redirected to the www. I'd like in other words to use it as a proxy
for Internet. Is it possible ?
I've read about the proxy directive, but I cannot find a way to forward
a route to the web....
any help ?
Thanks a lot
Francesco


  #2 (permalink)  
Old 07-21-2003
Wesley Groleau
 
Posts: n/a
Default Re: Apache as proxy for the web

Richard Antony Burton wrote:
> Just make sure you keep your logs, or you'll find yourself without much
> defence if people use your proxy to down load kiddie porn.


How do you make it log hits from browsers
on localhost?

I would like to be able to check whether
the kids were doing their homework or
playing games on cartoon network. :-)

All hits (including downloads) from the other
machines on the LAN are logged, but NO requests
from browsers on the webserver are logged.

I've made sure that the proxy is mandated,
and indeed, if I kill Apache, the browsers
can't get out.

  #3 (permalink)  
Old 07-28-2003
Mark Edwards
 
Posts: n/a
Default Re: Apache as proxy for the web


"Francesco M." <markNoSpam@libero.it> wrote in message
news:DKLSa.191101$lK4.5457219@twister1.libero.it.. .
> Hi all,
> I need to config Apache so that every request that is coming
> is redirected to the www. I'd like in other words to use it as a proxy
> for Internet. Is it possible ?
> I've read about the proxy directive, but I cannot find a way to forward
> a route to the web....
> any help ?
> Thanks a lot
> Francesco
>
>


Hi Francesco,

Here's an extract from my httpd.conf file. I'm on Apache 2.0.45 on Win32.
Make sure you get this right otherwise you could end up as an open proxy!.

--Mark.


LoadModule proxy_module "modules/mod_proxy.so"
LoadModule proxy_connect_module "modules/mod_proxy_connect.so"
LoadModule proxy_http_module "modules/mod_proxy_http.so"


<IfModule mod_proxy.c>
#
# Proxy Server directives. Uncomment the following lines to
# enable the proxy server:
ProxyRequests On
#
<Proxy *>
Order deny,allow
Deny from all
Allow from 10.0.0.3 10.0.0.2 10.0.0.1 127.0.0.1
</Proxy>
#Proxy
#
# Enable/disable the 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

proxyblock glocksoft windowsupdate.microsoft.com

</IfModule>



  #4 (permalink)  
Old 07-28-2003
Wesley Groleau
 
Posts: n/a
Default Re: Apache as proxy for the web

Mark Edwards wrote:
> Here's an extract from my httpd.conf file. I'm on Apache 2.0.45 on Win32.


I've got Apache/1.3.26 (Darwin)
(just threw that in for context of what follows)

> LoadModule proxy_module "modules/mod_proxy.so"
> LoadModule proxy_connect_module "modules/mod_proxy_connect.so"
> LoadModule proxy_http_module "modules/mod_proxy_http.so"


I uncommented the first one, but didn't notice the others.
Perhaps that explains my difficulties...
Also, I had to uncomment the corresponding AddModule


> # Set to one of: Off | On | Full | Block
>
> proxyblock glocksoft windowsupdate.microsoft.com


1. I don't think the comment applies to the following line.

2. Is httpd.conf case-sensitive? I have ProxyBlock

3. My block worked when the browser and server were
on the same CPU. When the browser was on a Win32
on my home LAN, the block didn't work. I have no
idea why or how to fix it.

4. I _do_ know that the Wintel was using the proxy, because
all its requests appeared in the server log. (I also can't
figure out why the requests aren't logged when the browser
and server _are_ on the same CPU.)

  #5 (permalink)  
Old 07-29-2003
Wesley Groleau
 
Posts: n/a
Default Re: Apache as proxy for the web


> Requests from my server aren't logged either. Probably as i'm going
> directly out. If I was to use 127.0.0.1 for proxy requests in my browser
> config, my guess is that requests would then be served by Apache and
> appear in the log. Having said that, what you say in 3) seems to run
> contradictory to 4) ???


Yes, it seems contradictory. But I definitely set the browsers
on both machines to use the Mac as proxy. And I'm sure it's done
because the blocking works on the Mac, and the logging works
for the Wintel browsers. Why the difference? I dunno.

 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 08:50 PM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0