Another "package" - set expiry at first use
Ivan Kalik
tnt at kalik.net
Fri May 8 15:05:40 CEST 2009
> Upon successful authentication, check it is firstuse. If yes, set expiry
> to say 6 months from now.
>
Use unlang in post-auth: check that there is no session for that user in
radacct; if none, put adddate(now(),INTERVAL 6 MONTH) into Tmp-String-0;
if you want to keep it in unlang (don't want to write a perl script) you
need to convert that from mysql time (yyyy-MM-dd HH:mm:ss) to Month dd
yyyy HH:mm:ss using mysql time functions (+ concat()) and store it in
Tmp-String-1; then insert Tmp-String-1 as Expiration value for that user
in radcheck.
Ivan Kalik
Kalik Informatika ISP
More information about the Freeradius-Users
mailing list