regular expression error in 3.0.x not present in 3.0.6

Aaron Hurt ahurt at ena.com
Thu Mar 5 18:58:44 CET 2015


Okay, so this may be an issue with libpcre in Yosemite … I rebuilt the same sources again with:

--with-pcre-lib-dir=/usr/local/opt/pcre/lib/ --with-pcre-include-dir=/usr/local/opt/pcre/include/

to specifically point to the homebrew installed libpcre and I now get the same behavior as in 3.0.6 and the regular expressions are working.

Sorry, and thank you for the assistance.

— Aaron

> On Mar 5, 2015, at 11:40 AM, FreeRadius developers mailing list <freeradius-devel at lists.freeradius.org> wrote:
> 
> When old style domain names come into FR they seem to always contain two backslashes ‘DOMAIN\\username’ which is what I am attempting to match.  In 3.0.6 it appears to work with 3 or 4 backslashes with correct_escapes=true but I cannot seem to get the same behavior out of 3.0.x from today.
> 
> These both work on 3.0.6 but fail with "Pattern study failed: unknown or incorrect option bit(s) set” on "FreeRADIUS Version 3.0.8 (git #c00210c), for host i386-apple-darwin14.1.0, built on Mar  5 2015 at 10:00:20"
> 
> simple_nt_regexp = "^([^\\\\]*)(\\\\(.*))$”
> simple_nt_regexp = "^([^\\\]*)(\\\(.*))$”
> 
> When I try to reduce the slashes down further to 2 I get the following on 3.0.8
> 
> /opt/local/etc/raddb/policy.d/strip-user-domain[9]: Invalid regular expression:
> /opt/local/etc/raddb/policy.d/strip-user-domain[9]: ^([^\]*)(\(.*))$
> /opt/local/etc/raddb/policy.d/strip-user-domain[9]:                 ^ Pattern compilation failed: missing terminating ] for character class
> 
> 
> Again, this is all with ‘correct_escapes=true’ in the radiusd config.
> 
> Thank you again,
> 
> Aaron
> 
>> On Mar 5, 2015, at 11:21 AM, Alan DeKok <aland at deployingradius.com> wrote:
>> 
>> On Mar 5, 2015, at 12:17 PM, Aaron Hurt via Freeradius-Devel <freeradius-devel at lists.freeradius.org> wrote:
>>> The errors in the previous post were with ‘correct_escapes=true’ …
>> 
>> Then you shouldn’t need 4 backslashes in a row.  It looks like your regular expression is wrong.
>> 
>> Use fewer backslashes.
>> 
>> Alan DeKok.
>> 
> 
> -
> List info/subscribe/unsubscribe? See http://www.freeradius.org/list/devel.html

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 496 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: <http://lists.freeradius.org/pipermail/freeradius-devel/attachments/20150305/95bc0c0c/attachment.sig>


More information about the Freeradius-Devel mailing list