Re: Inquiry Regarding Backslash Handling in Reply-Message
Nick Porter <[email protected]> Wed, 10 Sep 2025 20:35:19 +0100
| Newsgroups | gmane.comp.freeradius.user |
|---|---|
| Message-ID | <[email protected]> |
On 10/09/2025 18:34, Alan DeKok via Freeradius-Users wrote: > On Sep 3, 2025, at 7:09 AM, 平林 哲<[email protected]> 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 - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
OpenPGP_signature.asc
(application/pgp-signature, 665 B)
-----BEGIN PGP SIGNATURE----- wsD5BAABCAAjFiEEjw48vgR9BnUn1hS1ena+CY2NqIEFAmjB0vcFAwAAAAAACgkQena+CY2NqIGo hgwAlE/q8xpftBuITrwvPrLz2tmJfwX4KdZULEMH5tGhkgNCKuvf3hv1t/n6EyXepWRCujZ29v1N XHl08Wzk0fLLwu1R+Y22qqyhHyNG8CQAscAoxXFErywrP28tYspUIGMgs5EouG4K67fVbb88La+o 3mcplBjrsl/9P6JKjfCBgAZFmVrKC8DLrgVqWF5fvBfUf5I1lQH0GKhwhxnLxBpC//c2WJoIOAar 3aMfjWw2TauVcmVAVE2Qh0mboK+SYMgWF0h9UkWzFN+e8De03MUBrLRD9P0OFOeCslpQFmgKYFTh IlC19QEKMqeDOYzio2U8WlKWUuzuLIZMGf/r67CzZlk0F2vZRbSNR6bQw3C4SlSfXiYCBTzIHhgS AMBiM0BXkV9lE8oulBqPcvwyZaR6XGVxwpeb8WRMZ9JgoodUk/KkFy4PPiwj7oyIXJH2auDXQuRj pjgLutAS92psYPDWlNiQBr4tOLqcG5ayCNXBMu4Lzo32zlbnvlGnNExCKL62 =ckKF -----END PGP SIGNATURE-----