Problem with setting substring match variables (%{1} etc.)

Enrik Berkhan enrik#freeradius at
Thu Aug 9 15:39:44 CEST 2007

Alan DeKok wrote:
> Enrik Berkhan wrote:
>> This seems to work, variables are unset if they have an old value and no
>> new value (no match at all or empty) or they are set/updated if they
>> have a new value (match implied).
>   Hmm... on a regex match, all previous match information should be
> deleted.  This prevents old matches from polluting the variables for the
> current match.

The current change does this.

>> I've only tested it using unlang:
>   Isn't that just incredibly easy to use? :)

Yes :)

>   Just a patch for the existing code would be useful.  Maybe after that,
> factor out the regex code into one place.

I've attached the patch that I used for testing.


-------------- next part --------------
A non-text attachment was scrubbed...
Name: regex-substring.patch
Type: text/x-patch
Size: 2990 bytes
Desc: not available
URL: <>

More information about the Freeradius-Devel mailing list