new table and query

Dom Latter freeradius-users at latter.org
Thu Aug 31 14:17:50 CEST 2017


On 31/08/17 13:07, Johansson, Daniel (GIS) wrote:
 > Hi and thanks for your answers.
 >
 > I do this now and it works fine.

Hi,

You've not stated what your goal with "authorizedmacs" is but for
what it's worth we implemented a per-user MAC address limit by
storing their authorised MAC addresses in the radcheck table like
so:

Calling-Station-Id    =~    0C-74-C2-46-56-A5|60-C5-47-00-88-9A|.*

and we have a post-authentication script which will add new MACs to
radcheck if they have not reached the limit, and email the user
(and reject the authentication) if they have.  (Originally we were
going to remove the wildcard once they had got to their limit, which is
why it has been done like this.  If I were starting again I probably
would have kept them in the "userinfo" table where we keep email address
and so on).

On the other hand if you are just storing MAC Addresses then you might
want to consider storing them as 32 bit integers rather than as strings.


More information about the Freeradius-Users mailing list