Salut Hugues !!!

Sorry but you sent a RECEIPE (;-)) for managing RADONLINE and I meant one
for managing RADPOOL. In fact, I want that a Calling-Station-Id to be add to
RADPOOL on the same line where STATE is put to '1' at Access-Request. Then,
for Stop packet, I want the state of the IPs of the Calling-Station-Id to be
put to 0.

I remind you that my problem is that I need that since sometimes my Cisco
AS5300 doesn't send an Alive packet with the Framed-IP-Address allocated by
Radiator so I receive Stop packet like that :

*** Received from 10.69.1.1 port 1646 ....
Code:       Accounting-Request
Identifier: 49
Authentic:  <158><194>O<169>x{O[{<202><215>al<243>3<16>
Attributes:
        NAS-IP-Address = 10.69.1.1
        NAS-Port = 27
        NAS-Port-Type = Async
        User-Name = "Carrefour"
        Called-Station-Id = "6641"
        Calling-Station-Id = "670487956"
        Acct-Status-Type = Stop
        Acct-Authentic = RADIUS
        Service-Type = Framed-User
        Acct-Session-Id = "0000004C"
        Framed-Protocol = PPP
        Acct-Input-Octets = 89
        Acct-Output-Octets = 137
        Acct-Input-Packets = 3
        Acct-Output-Packets = 7
        Acct-Session-Time = 4
        Acct-Delay-Time = 0

Wed Oct  4 11:53:44 2000: DEBUG: Rewrote user name to carrefour
Wed Oct  4 11:53:44 2000: DEBUG: Check if Handler  should be used to handle
this request
Wed Oct  4 11:53:44 2000: DEBUG: Handling request with Handler ''
Wed Oct  4 11:53:44 2000: DEBUG: SDBSQL Deleting session for Carrefour,
10.69.1.1, 27
Wed Oct  4 11:53:44 2000: DEBUG: do query is: delete from ONLINE where
USERNAME='carrefour' and NASPORT=27

Wed Oct  4 11:53:44 2000: DEBUG: Handling with Radius::AuthSQL
Wed Oct  4 11:53:44 2000: DEBUG: Handling accounting with Radius::AuthSQL
Wed Oct  4 11:53:44 2000: DEBUG: do query is: insert into 2000_10_04
                (USERNAME, TIME_STAMP, ACCTSTATUSTYPE, ACCTDELAYTIME,
ACCTINPUTOCTETS, ACCTOUTPUTOCTETS, ACCTSESSIONID, ACCTSESSIONTIME, NASPORT,
CALLINGID, CALLEDID)
                values
                ('carrefour', 970653224, 'Stop', 0, 89, 137, '0000004C', 4,
27, '670487956', '6641')

Wed Oct  4 11:53:44 2000: DEBUG: Handling with Radius::AuthDYNADDRESS
Wed Oct  4 11:53:44 2000: DEBUG: do query is: update RADPOOL set STATE=0,
TIME_STAMP=970653224
where YIADDR=''

You can see that YIADDR is empty so the IP allocated is never  freed. I
could put expiration in place but this is not a perfect job and I prefer to
free the IP in Stop with the Calling-Station-Id.

Thanks in advance for your help.                Gildas.

-----Message d'origine-----
De : Hugh Irvine [mailto:[EMAIL PROTECTED]]
Envoyé : mardi 3 octobre 2000 04:14
À : Gildas PERROT
Cc : [EMAIL PROTECTED]
Objet : RE: (RADIATOR) RE:



Salut Gildas -

On Tue, 03 Oct 2000, Gildas PERROT wrote:
> Sorry I meant a receipe ;-)))) I would like to know which configuration
> directive I need to put a new "update RADPOOL" query at each Stop packets
> which allows to free the state of the IP corresponding to the callingID (I
> will create a callingID column in RADPOOL and I suppose that there is one
> session by callingID).
>

<SessionDatabase SQL>
        DBSource ....
        DBUsername ....
        DBAuth ....
        ....
        AddQuery insert into RADONLINE (USERNAME, NASIDENTIFIER, NASPORT, \
        ACCTSESSIONID, TIME_STAMP, FRAMEDADDRESS, PORTTYPE, \
        SERVICETYPE) values ('%n', '%N', %{NAS-Port}, '%{Acct-Session-Id}', \
        %{Timestamp}, '%{Framed-IP-Address}', '%{Port-Type}', '%{Service-Type}')

        CountQuery select NASIDENTIFIER, NASPORT, ACCTSESSIONID from RADONLINE \
        where USERNAME='%n'

        DeleteQuery delete from RADONLINE where USERNAME='%n' and \
        NASIDENTIFIER='%N' and NASPORT=%{NAS-Port}

</SessionDatabase>

You will need to adjust the AddQuery, CountQuery and DeleteQuery above to
use
the CallingID table with the Calling-Station-Id attribute in whatever
fashion
is appropriate for your requirements.

Have a look at section 6.7 in the Radiator 2.16.3 reference manual.

hth

Hugh

--
Radiator: the most portable, flexible and configurable RADIUS server
anywhere. SQL, proxy, DBM, files, LDAP, NIS+, password, NT, Emerald,
Platypus, Freeside, Interbiller, TACACS+, PAM, external, etc, etc.
Available on Unix, Linux, FreeBSD, Windows 95/98/2000, NT, MacOS X.




===
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.

Reply via email to