[squid-users] squid bind username to same ip but different port

Amos Jeffries squid3 at treenet.co.nz
Wed Dec 14 01:10:02 UTC 2016

On 14/12/2016 3:18 a.m., --Ahmad-- wrote:
> im not sure if the directive :
> external_acl_type type-name %SRC %LOGIN /path/to/ext_file_userip_acl -f /path/to/config.file
> will help becuase its description on ip/mask , not ip:port

If you want to write your own helper you could base it on that ones code
easily enough. But as you see it does not consider port numbers, since
HTTP is multiplexed it is rare for ports to matter beyond the 80, 443,
3128 triplet which have different syntaxes.

You could use the ext_sql_session_acl helper. Just pass it the port and
username as the session key. It has the extra benefit of not
auto-creating sessions but relying on you filling the database via some
other registration system.


More information about the squid-users mailing list