How to add new elements in database (fa-2.0.5)

Alan DeKok aland at deployingradius.com
Wed Jul 9 16:24:53 CEST 2008


Lidan Hu wrote:
> In normal way, the radius server will receive the EAP package, and check
> the user name and password. If it's authenticated, and return something,
> such as a 1 to open service, or 0 to reject request.

  What returns that?  1 or 0?  What does that mean?

> My task is, create two elements in database (we use mysql in opensuse).
> One is max bandwidth, other one is current bandwidth (or request bandwidth).
> And we add one data, request bandwidth, in EAP package. And in the
> programme, we gonna do,
> 1, receive EAP, and get request bandwidth.

  What is request bandwidth?

> 2, compare it with max bandwidth, if large, then goto 4.
> 3, return this request bandwidth. then goto 5.
> 4, return some error.
> 5, finish, and loop to 1
> 
> And for the max bandwidth in the database, we need to create it at the
> first time when the program runs.
> 
> Do you have any suggestion for me about which files I should focus on?

  Read "man unlang".  You can write simple policies in the configuration
files.

  Alan DeKok.



More information about the Freeradius-Devel mailing list