Inquiry Regarding Backslash Handling in Reply-Message
Nick Porter
nick at portercomputing.co.uk
Wed Sep 10 19:35:19 UTC 2025
On 10/09/2025 18:34, Alan DeKok via Freeradius-Users wrote:
> On Sep 3, 2025, at 7:09 AM, 平林 哲<Satoshi.Hirabayashi at soliton.co.jp> wrote:
>> We have encountered an issue in FreeRADIUS version 3.2.8 where the backslash (`\`) character in the `Reply-Message` configured for a user is not correctly reflected in the response.
Some experimentation and digging into the code shows that when your
entries are of the form
radiusAttribute: Reply-Message += 'mess\\age'
the value being assigned to the attribute gets un-escaped twice - which
is why you're seeing four \ being reduced to one.
If you omit the '' around the value then it is only un-escaped once
i.e.
radiusAttribute: Reply-Message += mess\\\\age
will result in two \ in the final value.
As Alan indicated it's a non-trivial fix - the same escaping /
un-escaping routines are used by multiple code paths so there is risk of
changing existing behaviour if they are amended.
Nick
Nick Porter
-------------- next part --------------
A non-text attachment was scrubbed...
Name: OpenPGP_signature.asc
Type: application/pgp-signature
Size: 665 bytes
Desc: OpenPGP digital signature
URL: <http://lists.freeradius.org/pipermail/freeradius-users/attachments/20250910/b1536b5e/attachment.sig>
More information about the Freeradius-Users
mailing list