Hello to Alan and the rest of the list. I wanted to report this to the
bug tracker but it appears to be down right now so I am sending it to
the list.
I had a situation where I needed to remove all of the attributes from a
reply except for Service-Type to one specific client. Unlang seemed to
be perfect for this. It should be as simple as the following.
if (Client-IP-Address == "192.168.10.20") {
update reply {
Framed-Protocol == ''
Framed-IP-Address == 0.0.0.0
Framed-IP-Netmask == 0.0.0.0
Idle-Timeout == 999
Session-Timeout == 999
Port-Limit == 999
Cisco-AVPair == ''
Service-Type := Authenticate-Only
}
}
However, when I try to do this, radiusd segfaults when attempting to run
this block. I tried several tests and I could sometimes get up to two
lines with "==" operators in an update block to work. However, adding
more than two or three would cause a segfault. I was finally able to use
the following workaround under 2.1.4. This workaround did not work under
2.1.3.
if (Client-IP-Address == "192.168.10.20") {
update reply {
Framed-Protocol == ''
}
update reply {
Framed-IP-Address == 0.0.0.0
}
update reply {
Framed-IP-Netmask == 0.0.0.0
}
update reply {
Idle-Timeout == 999
}
update reply {
Session-Timeout == 999
}
update reply {
Port-Limit == 999
}
update reply {
Cisco-AVPair == ''
}
update reply {
Service-Type := Authenticate-Only
}
}
My system is CentOS 5.2 32-bit.
Hope this helps.
Thanks,
Jim L.
-
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html