Incorrect reply rlm_python with tagged attributes
Alan DeKok
aland at deployingradius.com
Fri Feb 23 18:44:36 CET 2018
On Feb 23, 2018, at 12:41 PM, Юрий Иванов <format_hub at outlook.com> wrote:
>
> Thank you very much for your help Alan, I did what you advised me.
Mostly...
> But still there is some problem. I've simplified my code to demonstrate the issue:
> Python function is:
> def authorize(p):
> reply = (('Framed-IP-Address', '10.0.0.1'),
> ('ERX-Service-Activate:1', 'foo-local'),
> ('ERX-Service-Activate:2', 'svc-localnet(10000)'),
> ('ERX-Service-Activate:3', 'foo-string'),
> ('ERX-Service-Activate:4', 'foo-globalnet(10000)'),)
I also said:
>> You want to add a third entry to each tuple, which is the operator. Use "+=". Otherwise attributes of the same name may over-write each other.
Read that again, and do that.
> Looks good but result has only one, first, ERX-Service-Activate attribute. Other attributes are omitted.
Yes.. that's what I said would happen. I also told you how to fix it.
Alan DeKok.
More information about the Freeradius-Users
mailing list