account activate datetime

Iliya Peregoudov iperegudov at cboss.ru
Mon Sep 17 08:35:12 CEST 2012


There is rlm_logintime module. It uses Login-Time control attribute. 
Login-Time attribute format is:

<login-times> ::= <login-time> | <login-times>,<login-time>
<login-time> ::= <days> | <days><time>
<days> ::= <day> | <days><day>
<day> ::= <day-of-week> | <day-of-week>-<day-of-week> | Wk | Al | Any
<day-of-week>> ::= Su | Mo | Tu | We | Th | Fr | Sa
<time> ::= <hh><mm> | <hh><mm>-<hh><mm>
<hh> ::= 00 .. 24
<mm> ::= 00 .. 59

For example, allow logins from Monday till Friday, from 9:00 till 20:00:

Login-Time := "Mo-Fr0900-2000"

You can set Login-Time control attribute using rlm_files or rlm_sql (or 
whatever backend module). For example, using rlm_files:

# raddb/files
joe Cleartext-Password := "ToPsEcReT", Login-Time := "Mo-Fr0900-2000"

rlm_logintime module should be called from authorize section.

SkyDiablo wrote:
> hiho,
> 
> i search a solution to set a "activate datetime" for a account? in the 
> end, i want a possebility to set a timespan where the account is active?
> 
> from -> datetime
> to -> dateime
> 
> any tips for me ?
> 
> greez & thx,
>   sky...
> -
> List info/subscribe/unsubscribe? See 
> http://www.freeradius.org/list/users.html



More information about the Freeradius-Users mailing list