unlang idiom for removing superfluous attributes?
Brian Julin
BJulin at clarku.edu
Sat Jan 21 02:22:34 UTC 2023
I was pondering rewriting my rlm_attr_filter sets as unlang policy.
If there is an elegant way in unlang to remove all attributes from a list except the ones you want, I'm having trouble finding it.
In unlang you seem to need to know the name of an attribute to do anything to it.
If there was a temporary list, one could maybe (not sure if !* ANY works on lists):
update {
&tmp: !* ANY
&tmp: += &reply:
&reply: !* ANY
}
update reply {
# add the ones you want back in from &tmp:, perhaps with alterations
}
... but so far I only have found the Tmp-* attributes, no temporary list.
Maybe this is just one of the cases where we still need rlm_attr_filter?
Or maybe someone with more unlang-foo than me knows a magic incantation?
More information about the Freeradius-Users
mailing list