On Fri, 28 Dec 2001, Ker Ruben Ramos wrote:
> as what it is... mysql queries do values are using '=' .. not greater(>) or
> less(<) than.. right?
>
You can also use the check-name config directive. This directive defines an
attribute containing the maximum allowed limit (monthly,weekly etc). That way
you can add this attribute in the users file (to match all users) or in the user
entries in sql (after applying the patch).
radiusd.conf:
counter {
filename = ${raddbdir}/db.counter
key = User-Name
count-attribute = Acct-Session-Time
reset = "daily"
counter-name = Daily-Session-Time
check-name = Max-Daily-Session
^^^^^^^^^^^^
authorize{
[...]
files
counter
}
users file:
DEFAULT Auth-Type := SQL, Max-Daily-Session = 36000
Just make sure that the counter initialization directives are before rlm_files
(users file) module. That way rlm_counter can add the Max-Daily-Session to the
freeradius schema and have rlm_files know about it.
--
kkalev
-
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html