On 9 Oct 2013, at 07:05, "Hachmer, Tobias" <tobias.hach...@stadt-frankfurt.de> wrote:
> Hello list, > > I want to delete one reply attribute from the reply list if the > access-request is originating not from a special NAS-IP-Address. > > Currently I have solved this by adding this unlang code in authorize section: > > if(!NAS-IP-Address == x.x.x.x) { > update reply { > Aruba-Admin-Role := "" > } > } > > The man page of unlang says: > !* Delete all occurances of the named attribute, no matter what the value. > > I think this is the better way than just to clear the attribute value. But > how can I use this, what’s the correct syntax? > > I have tested the following without success: > > Aruba-Admin-Role !* "" > Aruba-Admin-Role !* > !* Aruba-Admin-Role > update reply { Aruba-Admin-Role !* ANY } Will delete all. update reply { Aruba-Admin-Role -= "%{reply:Aruba-Admin-Role}" } Will delete the first instance. -Arran Arran Cudbard-Bell <a.cudba...@freeradius.org> FreeRADIUS Development Team - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html