HomeFreeBSD

libradius: Fix attribute length validation in rad_get_attr(3)

Description

libradius: Fix attribute length validation in rad_get_attr(3)

The length of the attribute header needs to be excluded when comparing
the attribute length against the length of the packet. Otherwise,
validation may incorrectly fail when fetching the final attribute in a
message.

Fixes: 8d5c78130 ("libradius: Fix input validation bugs")
Reported by: Peter Eriksson
Tested by: Peter Eriksson
MFC after: now
Sponsored by: The FreeBSD Foundation

Details

Provenance
markjAuthored on May 28 2021, 2:41 PM
Parents
rG5434ebd256a0: tests/libalias: Measure cleanup time separatly
Branches
Unknown
Tags
Unknown