match client's shortname in huntgroups file
Jakob Hirsch
jh at plonk.de
Mon Jan 22 16:30:51 CET 2007
Hi,
is there an easy/good way to determine the huntgroup depending on the
the shortname from clients.conf? We have more than 100 clients
configured (with a "ProviderLocationCounter" pattern), so the
information is duplicated in the huntgroups file (multiple times, as the
huntgroup is also determined by Called-Station-Id). So it would really
simplify things to have the shortname available for matching in the
huntgroups file.
I could extend one of our custom modules to put the name into a VSA and
use that like 'Client-Shortname == "blub"' (already did it in a test
environment and it works fine), but that seems a little clumsy to me, so
I wondered if there's an easier way.
unrelated side note: As I see, client_find() walks linearly through the
client list. Shouldn't we keep this in a more appropriate data
structure, like a btree or a trie, and/or save the once found RADCLIENT*
pointer in the REQUEST struct? I understand that it doesn't matter for
most installations (and we don't have any performance problems, either),
it just does not feel right to waste so many cpu cycles :)
regards,
J
More information about the Freeradius-Users
mailing list