Hi, I have a pb using the freeradius 1.0.0 with experimental modules. I set up the sqlcounter like the example which is given in doc/ When i try to connect for the first time it returns a correct session-timeout. But once I surf a little time and try to reconnect it returns the same session-timeou which is the total time allowed to the user. I think radisu_xlat does something wrong so I give you my log (radiusd -X) and hope for an answer
rad_recv: Access-Request packet from host xxx.xxx.xxx.xxx:3258, id=4, length=47 User-Name = "test001" User-Password = "test001" Processing the authorize section of radiusd.conf modcall: entering group authorize for request 0 modcall[authorize]: module "preprocess" returns ok for request 0 modcall[authorize]: module "chap" returns noop for request 0 modcall[authorize]: module "mschap" returns noop for request 0 rlm_realm: No '@' in User-Name = "test001", looking up realm NULL rlm_realm: No such realm "NULL" modcall[authorize]: module "suffix" returns noop for request 0 modcall: entering group redundant for request 0 radius_xlat: 'test001' rlm_sql (sql1): sql_set_user escaped user --> 'test001' radius_xlat: 'SELECT id,UserName,Attribute,Value,op FROM radcheck WHERE Username = 'test001' ORDER BY id' rlm_sql (sql1): Reserving sql socket id: 3 radius_xlat: 'SELECT radgroupcheck.id,radgroupcheck.GroupName,radgroupcheck.Attribute,radgrou pcheck.Value,radgroupcheck.op FROM radgroupcheck,usergroup WHERE usergroup.Username = 'test001' AND usergroup.GroupName = radgroupcheck.GroupName ORDER BY radgroupcheck.id' radius_xlat: 'SELECT id,UserName,Attribute,Value,op FROM radreply WHERE Username = 'test001' ORDER BY id' radius_xlat: 'SELECT radgroupreply.id,radgroupreply.GroupName,radgroupreply.Attribute,radgrou preply.Value,radgroupreply.op FROM radgroupreply,usergroup WHERE usergroup.Username = 'test001' AND usergroup.GroupName = radgroupreply.GroupName ORDER BY radgroupreply.id' rlm_sql (sql1): Released sql socket id: 3 modcall[authorize]: module "sql1" returns ok for request 0 modcall: group redundant returns ok for request 0 rlm_sqlcounter: Entering module authorize code sqlcounter_expand: 'SELECT SUM(AcctSessionTime) FROM radacct WHERE UserName='%{User-Name}'' radius_xlat: 'SELECT SUM(AcctSessionTime) FROM radacct WHERE UserName='test001'' sqlcounter_expand: '%{sql:SELECT SUM(AcctSessionTime) FROM radacct WHERE UserName='test001'}' radius_xlat: '' rlm_sqlcounter: (Check item - counter) is greater than zero rlm_sqlcounter: Authorized user test001, check_item=54000, counter=0 rlm_sqlcounter: Sent Reply-Item for user test001, Type=Session-Timeout, value=54000 modcall[authorize]: module "noresetcounter" returns ok for request 0 rlm_sqlcounter: Entering module authorize code rlm_sqlcounter: Could not find Check item value pair modcall[authorize]: module "dailycounter" returns noop for request 0 rlm_sqlcounter: Entering module authorize code rlm_sqlcounter: Could not find Check item value pair modcall[authorize]: module "monthlycounter" returns noop for request 0 modcall: group authorize returns ok for request 0 auth: type Local auth: user supplied User-Password matches local User-Password Processing the session section of radiusd.conf modcall: entering group session for request 0 modcall: entering group redundant for request 0 modcall[session]: module "sql1" returns noop for request 0 modcall: group redundant returns noop for request 0 modcall: group session returns noop for request 0 Processing the post-auth section of radiusd.conf modcall: entering group post-auth for request 0 modcall: entering group redundant for request 0 rlm_sql (sql1): Processing sql_postauth radius_xlat: 'test001' rlm_sql (sql1): sql_set_user escaped user --> 'test001' radius_xlat: 'INSERT into radpostauth (id, user, pass, reply, date) values ('', 'test001', 'test001', 'Access-Accept', NOW())' rlm_sql (sql1) in sql_postauth: query is INSERT into radpostauth (id, user, pass, reply, date) values ('', 'test001', 'test001', 'Access-Accept', NOW()) rlm_sql (sql1): Reserving sql socket id: 2 rlm_sql (sql1): Released sql socket id: 2 modcall[post-auth]: module "sql1" returns ok for request 0 modcall: group redundant returns ok for request 0 modcall: group post-auth returns ok for request 0 Sending Access-Accept of id 4 to xxx.xxx.xxx.xxx:3258 Session-Timeout = 54000 Finished request 0 Going to the next request --- Walking the entire request list --- Waking up in 3 seconds... --- Walking the entire request list --- Cleaning up request 0 ID 4 with timestamp 41441b47 Nothing to do. Sleeping until we see a request. Thx -----Message d'origine----- De : [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] De la part de Kostas Kalevras Envoyé : vendredi 10 septembre 2004 15:39 À : [EMAIL PROTECTED] Objet : Re: rlm_ippool and NAS-Port missing in access-request On Fri, 10 Sep 2004, Paul Hampson wrote: > On Thu, Sep 09, 2004 at 05:09:48PM +0200, [EMAIL PROTECTED] wrote: > > Well, this exactly what I'd like to do: to build a one and to get it > > working... But I need some help from developers. So who wants > > cooperate ? Any help/hints are welcome > > http://bugs.freeradius.org/show_bug.cgi?id=42 > > I was thinking about this recently, and maybe a better solution would > be a new module, unless you can find a way to make the new module > process the old gdbm library? Why write a new module exactly? The key stucture has enough space for storing an md5 result if that is what you are concerned about. > > People also want a SQL-backended rlm_ippool module, ala rlm_sqlcounter > I suspect. Why is an sql version necessary? The rlm_sqlcounter module has no value in the 95% of cases. It's usefull only in cases with really complicated sql queries. The same goes for the ippool module. > > This might be a good time to introduce rlm_sqlippool, with > configurable keys and no legacy hangovers. If you're after a more > generic ippool algorithm, I posted one here a couple of years ago, but > Kostas managed to fix the livelock (I think) in rlm_ippool so it > wasn't needed. ^_^ > > -- > Paul "TBBle" Hampson, on an alternate email client. > > - > List info/subscribe/unsubscribe? See > http://www.freeradius.org/list/users.html > -- Kostas Kalevras Network Operations Center [EMAIL PROTECTED] National Technical University of Athens, Greece Work Phone: +30 210 7721861 'Go back to the shadow' Gandalf - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html