How to set REST Module Attribute encoding to UTF-8?
Alan DeKok
aland at deployingradius.com
Tue Jun 25 22:58:55 UTC 2024
On Jun 25, 2024, at 1:50 PM, 남혁준 <sawd1598 at gmail.com> wrote:
>> In other words, the difference is whether I wrote the data or not.
>>
>> If I wrote data, only the properties I wrote are sent.
OK.
> With this part,
>
> (9) rest: Encoding attribute "Module-Failure-Message"
>
> This part is key.
>
> Korean is displayed correctly in the log.
The "Encoded attribute" data is just printed to a string. See https://github.com/FreeRADIUS/freeradius-server/blob/v3.2.x/src/modules/rlm_rest/rest.c#L800
Perhaps the locale for the system is not Korean?
> However, the REST module is called after going through the Encoding
> attribute, and then a broken string arrives at my REST server.
>
> I am guessing that this part is converted to ISO-8859-1 encoding.
FreeRADIUS doesn't convert strings to ISO-8859. It just prints the data to create JSON.
So something on your local system is deciding that UTF-8 text is wrong, and is converting it to ISO-8859.
There's no automatic conversion in the REST module, so it can't be that.
Alan DeKok.
More information about the Freeradius-Users
mailing list