Page MenuHomeFreeBSD

ppp: Permit CHAP challenges up to 255 bytes
ClosedPublic

Authored by jhb on May 20 2026, 7:31 PM.
Tags
None
Referenced Files
F175017413: D57138.diff
Wed, Oct 7, 4:13 PM
F174978252: D57138.id179281.diff
Wed, Oct 7, 8:15 AM
Unknown Object (File)
Sun, Oct 4, 10:58 PM
Unknown Object (File)
Sun, Oct 4, 2:52 PM
Unknown Object (File)
Sun, Oct 4, 10:42 AM
Unknown Object (File)
Sat, Oct 3, 3:23 PM
Unknown Object (File)
Sat, Oct 3, 3:01 PM
Unknown Object (File)
Fri, Oct 2, 2:45 PM
Subscribers

Details

Summary

RFC 1994 does not place any limit on the length of the value field in
challenge messages except that the length is a single octet which
bounds the maximum length to 255.

NB: I'm not sure why the local[] and peer[] arrays contain room for an
authentication name (AUTHLEN) in addition to a challenge value/response,
but I've just left that in place.

PR: 271955
Reported by: Robert Morris <rtm@lcs.mit.edu>

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

jhb requested review of this revision.May 20 2026, 7:31 PM
usr.sbin/ppp/chap.c
241

The cast is required so that the single char is promoted to an unsigned int instead of a signed int when passed as the length.

des added a subscriber: des.

It's safe to drop the extra AUTHLEN from challenge.local and challenge.peer

This revision is now accepted and ready to land.Jun 5 2026, 3:40 PM
This revision now requires review to proceed.Jun 5 2026, 3:53 PM
This revision is now accepted and ready to land.Jun 5 2026, 4:40 PM
This revision was automatically updated to reflect the committed changes.