I just upgraded from 2.12.1 to 2.15 tonite, and AccountingHandled is
broken. The cause appears to be that the default behavior for a
non-handled request changed. Below is the patch I used to fix it
for illustrative purposes (and to get back on the air), I simply restored
the original non-handled behavior for accounting requests.
Oh, since it's here. I guess I'll mention that I think Handler.pm is the
wrong place to cleaning up the session db. First off, an access request
is not a start record, there isn't any explicit gaurantee that an access
request is actually going to result in a session. Second, the real start
record will clean it up by itself. Third, since there is no locking on
SessDBM databases (we are running split authentication/accounting
processes here for performance) it's an opportunity for an access
collision. So that's why I commented it out locally.
Also the Hook syntax changed from 2.12.1, but since someone else mentioned
that on the list (which I regret I can no longer pay much attention to due
to the rapidly declining s/n ratio) I was able to repair it quickly. May I
suggest that future releases include version migration notes?
Cheers,
Aaron
*** Radiator-2.15/Radius/Handler.pm Mon Feb 14 23:09:41 2000
--- Radiator-2.15-local/Radius/Handler.pm Mon Mar 20 01:59:41 2000
***************
*** 262,268 ****
if ($p->code eq 'Access-Request')
{
# If we lost a Stop for this port, clean up the session database
! $sessdb->delete($original_username, $nas_id, $nas_port, $p);
if (defined $self->{MaxSessions}
&& $sessdb->exceeded($self->{MaxSessions}, $original_username, $p))
--- 262,268 ----
if ($p->code eq 'Access-Request')
{
# If we lost a Stop for this port, clean up the session database
! # $sessdb->delete($original_username, $nas_id, $nas_port, $p);
if (defined $self->{MaxSessions}
&& $sessdb->exceeded($self->{MaxSessions}, $original_username, $p))
***************
*** 480,485 ****
--- 480,486 ----
# $handled can be IGNORE, ACCEPT or REJECT
my $handled = $main::REJECT; # If there is no handlers
+ $handled = $main::IGNORE if ($p->code eq 'Accounting-Request');
# Make sure we always copy the Proxy-State
my $ps = $p->getAttrByNum($Radius::Radius::PROXY_STATE);
===
Archive at http://www.starport.net/~radiator/
Announcements on [EMAIL PROTECTED]
To unsubscribe, email '[EMAIL PROTECTED]' with
'unsubscribe radiator' in the body of the message.