set absolute lifetimes

Sebastian Wieseler s.wieseler at undbitte.tv
Tue Jun 30 17:24:40 CEST 2009


Hello guys,

I've got a problem with the accounting of freeradius. The counter and sqlcounter are
made for scenarios where people'll get a number of hours and can take them where
ever they want to...

I would like to setup a scenario where people can login for 1/2/3/4/... days.
Let's say somebody is allowed to login for one day...then he shouldn't be able to
login half a day today and half a day tomorrow.
I would like to make "one day" absolute - to end at the end of day1.


Into "radcheck" I would like to write something like
Current-Time <= a value you set while creating the "ticket".
Let's suppose everything to be in Unix Time format...


I tried to write in the radius config in the modules part:

	sqlcounter maxlifetimecouter {
		counter-name = Max-End-Lifetime-Counter
		check-name = Current-Time
		sqlmod-inst = sql
		key = User-Name
		reset = never
		query = "SELECT UNIX_TIMESTAMP();"
	}

But it didn't work out. To have got a cron job
that will delete expired accounts (like [1]) isn't
an option either...

Can you please help me? :-(



[1] http://github.com/italpro/ChilliGrid/blob/2ef3cd1dd342468ed195fef8ba82d2244179305d/cron/reapusers.pl


Kind Regards,

Sebastian Wieseler
- IT -
_________________________________________________________________________
undbitte entertainment GmbH, Medienproduktion                             
Von-Hünefeld-Str. 81, 50829 Köln

Phone:    +49 221 801307-0
Fax:      +49 221 801307-18


Internet: http://www.undbitte.tv
E-Mail:   s.wieseler at undbitte.tv

undbitte entertainment GmbH, Geschäftsführung: Anke Tesdorpf                
Sitz der Gesellschaft: Köln, Handelsregister: HRB 34500, Amtsgericht Köln   

                      




More information about the Freeradius-Users mailing list