[squid-users] Variables and external_acl_types

From: Alan Schmidt <saltamontes_at_gmail.com>
Date: Wed, 16 Jan 2013 14:28:44 -0300

Hi list,

Due to my employer's specific requirement, I'm writing an external_acl
helper that allows us to query an LDAP server for valid dstdomains.
It's actually working (not in the cleanest way :S), but i think i'm
lacking squid basic knoledge to get it done properly.

I can see from squid_ldap_group helper configuration

external_acl_type ldap_group ttl=1 negative_ttl=1 %LOGIN
/usr/sbin/squid_ldap_group -d -D $ADMIN_DN -w $PASS -b $SUFFIX -f
"(&(memberUid=%u)(cn=%g))" -h 127.0.0.1 -v 3

that it uses %LOGIN format and %u/%g variables.

I don't fully understand this, is there any list of this squid's
available variables??? where do they come from (squid environmental??)
???.
Using %DST i managed to get the info i need from squid (requested url
and name of the acl) via standard input. Helper works this way, but
it's quite awkward.

The question: is there any variable (like %u or %g from the example
above) i could use to pass the requested url and acl via helper
parameter?
This way i could generate a much more flexible code.

What i want to do woud be something like:

external_acl_type validsites ttl=1 negative_ttl=1 %DST
/usr/sbin/squid_ldap_checksite -D $ADMIN_DN -w %PASS -b $SUFFIX -h
127.0.0.1 -f "urlattribute=%something"
being %something a variable containing the requested url.

I'm sorry if this is not the place to ask, or if the info is available
somewhere already. I've been searching on manuals, faqs, etc, without
any luck.
I'm relatively new to this kind of stuff (both lists and
external_acl_types :S). If someone coud point me at least at the right
documentation i'll be very grateful.

Thanks in advance.

--
Alan
Received on Wed Jan 16 2013 - 17:28:50 MST

This archive was generated by hypermail 2.2.0 : Thu Jan 17 2013 - 12:00:04 MST