O'Reilly logo

FreeRADIUS Beginner's Guide by Dirk van der Walt

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Time for action – limiting a user's usage

The following sections will demonstrate how to limit Internet usage.

Activating a daily counter

The counter module has the following counter defined by default:

counter daily {
    filename = ${db_dir}/db.daily
    key = User-Name
    count-attribute = Acct-Session-Time
    reset = daily
    counter-name = Daily-Session-Time
    check-name = Max-Daily-Session
    reply-name = Session-Timeout
    allowed-servicetype = Framed-User
    cache-size = 5000
}

Modify the counter as follows:

  1. Edit the sites-enabled/default file in the FreeRADIUS configuration directory. Uncomment daily in both the authorize and accounting sections. Also, uncomment daily in the instantiate section of the radius.conf file to ensure proper instantiation of the counter.
  2. The ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required