[squid-users] Counting unique devices connected to squid proxy

Matus UHLAR - fantomas uhlar at fantomas.sk
Fri Jan 27 13:19:32 UTC 2023


>>On 20/01/2023 9:16 am, Marcus Kool wrote:
>>>The squid log file contains the IP address of clients and could be 
>>>a good field to use for counting users. But a NAT shows 1 IP for 
>>>all users behind the NAT...

>>>On 19/01/2023 15:48, Ben Goz wrote:
>>>>I have a certain task to count the number of unique devices 
>>>>connected (Could be also transparently) to squid proxy server. 
>>>>While the users can be on different networks and behind NAT.
>>>>Is it possible?

>On 21/01/2023 14:59, Amos Jeffries wrote:
>>No, not really. As Marcus said NAT erases information. As does any 
>>HTTP multiplexing being performed by downstream proxies.

On 22.01.23 14:37, Ben Goz wrote:
>Is it possible for squid to identify NAT?

not really.

>>>>What is the best approach of implement it?

>>Squid provides a management report "client_list" with all recently 
>>seen client devices. It is reliable for the *currently* connected 
>>clients, but once a client disconnects entries are discarded 
>>relative to how much traffic they have used.

>Does this report also words behind NAT? can you refer me to more 
>descriptive information about "client_list"?

you should understand that web pages consist of multiple (tens, hundreds) of 
objects and they are fetched using multiple HTTP transactions to multiple 
servers and between, connections may be closed between multiple clicks.

So, it's really hard to distinguish between one client fetching 100 objects 
from 10 servers and 5 clients fetching 20 objects from 2 servers each.


>>Or there are the logs which contain (or can be configured to record) 
>>a details of *completed* transactions.

-- 
Matus UHLAR - fantomas, uhlar at fantomas.sk ; http://www.fantomas.sk/
Warning: I wish NOT to receive e-mail advertising to this address.
Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
42.7 percent of all statistics are made up on the spot.


More information about the squid-users mailing list