Re: Squid + IP +CGI

From: Gustavo Aguiar <lnx-security@dont-contact.us>
Date: Mon, 05 Oct 1998 16:34:54 -0300

Hi,

Yes, thank you. It did help but I was wandering if someone have an exemple
in perl on how can I read the header X-Forwared-For. How do I have to put
this in my CGI script??

Thank's once again,
Gustavo Aguiar

At 16:42 05/10/1998 +0200, you wrote:
>
>-----Ursprüngliche Nachricht-----
>Von: Gustavo Aguiar <lnx-security@airnet.com.br>
>An: squid-users@ircache.net <squid-users@ircache.net>
>Datum: Montag, 5. Oktober 1998 16:34
>Betreff: Squid + IP +CGI
>
>
>>Hi all,
>>
>>I'm having a big problem with squid. At my local net I have same web pages
>>tha run cgi scripts. It work's like this:
>>
>>1- My user come and request a web page.
>>2- My script look out for his IP.
>>3- My script look up for his username reading a file using the IP found.
>>4- My script print the web page for tha specific user.
>>
>>My problem is:
>>
>>When I installed squid my script only gets my the IP of my squid server.
>>Can I configure squid to don't redirect my user to this page. This way my
>>user's browser will be forced to access directly my page.
>>
>>Is this possible? Can I do this by another way ??
>>
>enable the forwarded_for option in squid.conf. (usually: forwarded_for on)
>Further you should extend your script to scan the X-Forwarded-For variable
>in the header.
>Check if X-Forwarded-For exists.
>if it exist,
> use this ip-address
>else
> use your previous routine to determine the ip-adress of the client.
>
>Hope that helps!
>
>--Andy
>
>Dipl.-Inf. (FH)
>Andreas Vierengel
>
>
>
>
>
Received on Mon Oct 05 1998 - 12:36:13 MDT

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:42:20 MST