Auth by NAS-Identifier using unlang

Joseph Perrin joseph at lifeonthestreet.org
Mon Aug 5 23:37:01 CEST 2013


The following appears to now work, but I don't understand some things:

files

if (control:Local-Group != "%{NAS-Identifier}" ) {

Why does control:Local-Group not need to be enclosed in "%{ }", but
NAS-Identifier does?
And why does %{ } content need to be within quotes, when the documentation
doesn't say anything about them needing to be in quotes?

It's clear I must have a call to "files" prior to this in order to populate
the "control" list, right?



On Mon, Aug 5, 2013 at 5:03 PM, Arran Cudbard-Bell <
a.cudbardb at freeradius.org> wrote:

> >
> > Diagnostic says:
> >   ++? if (control:Local-Group != NAS-Identifier ) -> FALSE
>
> Assuming you're not looking for a literal value 'NAS-Identifier', you want
> "%{NAS-Identifier}".
>
> If this is a new deployment you should use current HEAD revision in
> Master.  Then you can use the debug_attr expansion to look at list state.
>
> update request {
>         Tmp-String-0 := "%{debug_attr:control:}"
> }
>
> Also could you please stop posting snippets of debug output and paste the
> whole thing...
>
> Arran Cudbard-Bell <a.cudbardb at freeradius.org>
> FreeRADIUS Development Team
>
> -
> List info/subscribe/unsubscribe? See
> http://www.freeradius.org/list/users.html
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freeradius.org/pipermail/freeradius-users/attachments/20130805/63355121/attachment.html>


More information about the Freeradius-Users mailing list