reply attributes not always sent (radius_paircreate() problem seen in rlm_ippool)
Arran Cudbard-Bell
a.cudbardb at freeradius.org
Tue Jan 21 23:48:54 CET 2014
On 20 Jan 2014, at 17:24, Arran Cudbard-Bell <a.cudbardb at freeradius.org> wrote:
>
> On 20 Jan 2014, at 15:32, Alan DeKok <aland at deployingradius.com> wrote:
>
>> John Dennis wrote:
>>> While you're at it could you also fix the warning messages in
>>> rad_encode() (radius.c around line 1850) so they're emitted. Maybe they
>>> should be DEBUG statements instead of fr_strerror_printf() or maybe fix
>>> fr_strerror_printf(), either way it should show up when running in debug
>>> -X mode.
>>
>> It's not always an error to miss encoding attributes. The call to
>> rad_encode() succeeds, so there's no reason for the radiusd binary to
>> print out an error. The issue is that rad_encode() calls rad_vp2attr().
>
> and rad_vp2attr() passes back error codes from the other attribute encoders, and those encoders log errors using fr_strerror_printf(). rad_encode() doesn't call fr_strerror_printf() itself on rad_vp2attr() error, so it seems some place in the code isn't checking the return value of rad_encode().
>
>> So maybe rad_encode() should print the error string, via a DEBUG
>> statement.
>
> It's a library function. It shouldn't even have the DEBUG() macro available.
OK. Fixed the fr_strerror_printf() issue.
See https://github.com/FreeRADIUS/freeradius-server/commit/d253c7306dc5170972dc7d5c81123f798ed1fdd5
Arran Cudbard-Bell <a.cudbardb at freeradius.org>
FreeRADIUS Development Team
FD31 3077 42EC 7FCD 32FE 5EE2 56CF 27F9 30A8 CAA2
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 881 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: <http://lists.freeradius.org/pipermail/freeradius-devel/attachments/20140121/384c6e52/attachment.pgp>
More information about the Freeradius-Devel
mailing list