2.0.0 documentation for radiusd.conf
Hugh Messenger
hugh at alaweb.com
Wed Jun 27 02:22:44 CEST 2007
Alan Dekok <aland at deployingradius.com> said:
> Hugh Messenger wrote:
> > Any luck fixing this stuff:
> >
> > DEFAULT Called-Station-Id =~ "^([A-z0-9]+_[0-9]+)$", Pool-Name := `%{0}`
> > Framed-IP-Netmask = 255.255.0.0,
> > Fall-Through = 1
> >
> > ... in either users or hints?
>
> Don't use "users" or "hints". Use the new unlanguage.
[snip]
> authorize {
> ...
> if (Called-Station-Id =~ /^([A-z0-9]+_[0-9]+)$/) {
> update config {
> Pool-Name := "%{0}"
> }
> update reply {
> Framed-IP-Netmask = 255.255.0.0
> }
> }
> ....
> }
>
> Much easier to understand, I think.
And better yet, it works. :0
One small fix though, it needs the "%{}" around Called-Station-Id ...
If ("%{Called-Station-Id}" =~ /^([A-z0-9]+_[0-9]+)$/) {
> Alan DeKok.
I like this new unlang.
-- hugh
More information about the Freeradius-Users
mailing list