[prev in list] [next in list] [prev in thread] [next in thread] 

List:       freeradius-users
Subject:    Re: Updating/overwriting attribute with rlm_python
From:       Alan DeKok <aland () deployingradius ! com>
Date:       2023-10-26 22:29:05
Message-ID: E59984EC-FA02-41CD-86D7-548DEFE52B0E () deployingradius ! com
[Download RAW message or body]

On Oct 26, 2023, at 4:52 PM, Norman Elton <normelton@gmail.com> wrote:
> 
> I'm using rlm_python, returning a tuple to update attributes in the reply.
> I've noticed that if the request already has a value for that attribute, it
> is not overwritten. That is, my operation becomes a no-op.
> 
> I suppose this matches the behavior of the "=" operator. Is there a way to
> behave like the ":=" operator, overwriting the existing value? Or should I
> strip the value prior to invoking my python module?

  You can pass a 3-tuple:  (name, operator, value)

  The operator works just like in the "files" module.

  Alan DeKok.

-
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic