Bind radius client requests to a database

Ti Ti tt91em at gmail.com
Fri Sep 22 16:30:20 CEST 2017


>
> > Hello, I've the following freeradius configuration that I use to bind
> radius
> > clients to a specific db.
>
>   I'm not sure what that means.
>

 I mean that the requests and accounting of radius client that uses the
password "pwd1" have to go the the sql1, the requests of client with
password "pwd2" on sql2 and so on.



> > The problem is that I use a virtual radius
> > associated to every db and I would avoid this. Is that possible to have a
> > single radius instance listening and forward the request to db using
> radius
> > client password (eventually contained in the nas table)?
>
>   The SQL queries are customizable.  You can write "if / then / else"
> statements in Unlang to select the database you're using, based on what
> client is coming in.
>
>   Just write the rules:
>
>         if (Packet-Src-IP-Address == client1) {
>                 sql1
>         }
>         else if (Packet-Src-IP-Address == client2) {
>                 sql2
>         }
>
>   It's that simple.
>
>   Alan DeKok.
>

In my case the clients can have dynamic IP, so I have to use tens of if
statement to evaluate the client password? Are there different methods to
achieve the result of binding the users?


More information about the Freeradius-Users mailing list