Re: [squid-users] Return IP Address

From: Colin Campbell <sgcccdc@dont-contact.us>
Date: Thu, 21 Mar 2002 08:23:42 +1000 (EST)

Hi,

On Wed, 20 Mar 2002, Chandrakant Sharma wrote:

> Dear John,
>
> Thanks for your prompt response. Let me explain the
> problem in proper way.
>
> The Squid is configured with two NICs (we will call it
> as WAN and LAN NIC). The WAN NIC IP Address is
> 192.168.0.1/30, the LAN IP Address is 192.168.1.1/30.
> The same box is acting as a DHCP Server providing IP
> addresses from scope 192.168.2.0 -to- 192.168.2.254.
>
> Say a customer is connected to my Network and gets
> 192.168.2.1 from DHCP pool. My query is when the squid
> service is enabled, the outgoing request goes with WAN
> IP i.e 192.168.0.1, which i do not want. I want the
> outgoing IP Address should be client IP Address i.e.
> 192.168.2.1. This I can achieve when I stop the Squid
> Service, then the outgoing request is with actual IP
> Address i.e. 192.168.2.1.

Squid is a proxy. That means when a browser accesses a server ther are two
connections, not one. The first connection is from the browser to the
proxy. The second connection is from the proxy to the server.

If the packets headed for the server had the browser source address, the
server response would not be cached. The packets would not be sent to the
squid box but the browser so the squid software would never see the data
from the server.

There is an HTTP header that can include the browser's IP address and is
configurable in squid - see squid.conf cos I don't recall what it is.

Colin
Received on Wed Mar 20 2002 - 15:23:59 MST

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 17:07:00 MST