Fixing \\\\ escapes \\\\\\\\\\
I finally sat down and went through the source to fix \\ the \\\\ escaping \\\\\\\\ problem. \\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\ The main issue is backwards compatibility. The good news is that the server continues to work as before, with no changes required to your configuration. The *better* news is that if you edit radiusd.conf, and set: correct_escapes = true it will now require only one backslash, instead of many. e.g. if (User-Name =~ /foo\.bar/) { ... } Will match User-Name = "foo.bar", as expected. This is a minor change which should get rid of severe annoyance in the server. If you *don't* set "correct_escapes", you will need to use the old method of: if (User-Name =~ /foo\\.bar/) { ... } Which is annoying. Please test the v3.0.x branch in git. There *are* regression tests for the new behavior, and they've been carefully checked. Alan DeKok.
Wonderful ! Thanks Alan, we are grateful ! On Tue, Oct 21, 2014 at 7:12 PM, Alan DeKok <aland@deployingradius.com> wrote:
I finally sat down and went through the source to fix \\ the \\\\ escaping \\\\\\\\ problem. \\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\
The main issue is backwards compatibility. The good news is that the server continues to work as before, with no changes required to your configuration.
The *better* news is that if you edit radiusd.conf, and set:
correct_escapes = true
it will now require only one backslash, instead of many. e.g.
if (User-Name =~ /foo\.bar/) { ... }
Will match User-Name = "foo.bar", as expected.
This is a minor change which should get rid of severe annoyance in the server.
If you *don't* set "correct_escapes", you will need to use the old method of:
if (User-Name =~ /foo\\.bar/) { ... }
Which is annoying.
Please test the v3.0.x branch in git. There *are* regression tests for the new behavior, and they've been carefully checked.
Alan DeKok. - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
Yay! :-) Love it! Stefan Paetow Moonshot Industry & Research Liaison Coordinator t: +44 (0)1235 822 125 gpg: 0x3FCE5142 xmpp: stefanp@jabber.dev.ja.net skype: stefan.paetow.janet Janet, the UK's research and education network. Janet(UK) is a trading name of Jisc Collections and Janet Limited, a not-for-profit company which is registered in England under No. 2881024 and whose Registered Office is at Lumen House, Library Avenue, Harwell Oxford, Didcot, Oxfordshire. OX11 0SG. VAT No. 614944238 ________________________________________ From: freeradius-users-bounces+stefan.paetow=ja.net@lists.freeradius.org [freeradius-users-bounces+stefan.paetow=ja.net@lists.freeradius.org] on behalf of Alan DeKok [aland@deployingradius.com] Sent: 21 October 2014 20:12 To: FreeRadius users mailing list Subject: Fixing \\\\ escapes \\\\\\\\\\ I finally sat down and went through the source to fix \\ the \\\\ escaping \\\\\\\\ problem. \\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\ The main issue is backwards compatibility. The good news is that the server continues to work as before, with no changes required to your configuration. The *better* news is that if you edit radiusd.conf, and set: correct_escapes = true it will now require only one backslash, instead of many. e.g. if (User-Name =~ /foo\.bar/) { ... } Will match User-Name = "foo.bar", as expected. This is a minor change which should get rid of severe annoyance in the server. If you *don't* set "correct_escapes", you will need to use the old method of: if (User-Name =~ /foo\\.bar/) { ... } Which is annoying. Please test the v3.0.x branch in git. There *are* regression tests for the new behavior, and they've been carefully checked. Alan DeKok. - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
participants (5)
-
Alan DeKok -
Kev Pearce -
Phil Mayers -
Russell Mike -
Stefan Paetow