From 59c0baef740002b9074249cf317d093059fec951 Mon Sep 17 00:00:00 2001 From: iBNu Maksum Date: Tue, 7 May 2024 08:54:02 +0700 Subject: [PATCH] Updated FreeRadius (markdown) --- FreeRadius.md | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/FreeRadius.md b/FreeRadius.md index 0367ddc..a145753 100644 --- a/FreeRadius.md +++ b/FreeRadius.md @@ -81,6 +81,10 @@ For all categories, remove the “file” directive and add the “sql” one. T authorize { ..... sql + expiration + quotalimit + accessperiod + uptimelimit .... } @@ -157,6 +161,15 @@ sqlcounter quotalimit { $INCLUDE ${modconfdir}/sql/counter/${dialect}/${.:instance}.conf } + +sqlcounter uptimelimit { + counter_name = 'Max-All-Session-Time' + check_name = 'Max-All-Session' + sql_module_instance = sql + key = 'User-Name' + reset = never + query = "SELECT SUM(AcctSessionTime) FROM radacct WHERE UserName='%{${key}}'" +} ``` `mods-config/sql/counter/mysql/accessperiod.conf`