>   I would suggest using the Perl module.  It does everything the
> rewrite functions do, and more.
> 
>   Alan DeKok.

Following this advice, I learned a bit of perl and tried this aproach.
There were alot of problems I met, most of them are VoIP related.
In my opinion the perl module is *exactly* what I was looking for - very flexible, and 
hopfully fast enough (is it?) comarably to exec-progam-wait.
I suspect that I hit a few bugs in this module (is it an experimental module?..) or, 
maybe, I haven't learned perl well enough ;))
Ok... here:
1) function authenticate (in supplied example.pl script) HAS NEVER been called, and I 
wasn't able to make it called in any circumstances. The script only worked if I used 
authorize function in authorize section. (please, explain me the difference and what's 
wrong in that case)
2)Statement $RAD_REPLY{'h323-credit-amount'} = "100"; is probably is not correct, 
since changing it to a similar statement $RAD_REPLY{'h323-credit-amount'} = "100"; 
(credit-amount replaced by credit-time) didn't take any effect - gnugk was rejecting 
calls even though radius said AccessAccept. Changing it to 
$RAD_REPLY{'h323-credit-amount'} = "h323-credit-amount=100"; fixed the problem.
3)While trying to fix the h323-credit-time I tried to use Seesion-Timeout like this: 
$RAD_REPLY{'Session-Timeout'} = 100; but it didn't work. Solution was to use 
$RAD_REPLY{'Session-Timeout'} = '100'; (integer 100 is replaced by string '100') even 
though this parameter is declared as integer in radius dictionary:
ATTRIBUTE       Session-Timeout         27      integer
Changing 100 to '100' made radius to send this atribute, BUT it still wasn't 
recognezed by gnugk! Gnugk only accepts this parametr as a string, and not integer! 
(in gnugk changing something like param->AsString() to param->AsInteger() fixes this 
problem... BUT I don't think this is the problem of gnugk, as it's been successfull 
managing this atribute limiting calls for many people...)

If I'm wrong in any place please correct me.

PS. Is there anybody who uses this module in production enviroment????




- 
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html

Reply via email to