When we receive a CHAP81 challenge response, we always expect the last
byte of the packet to contain '\0'. Windows 98 gets this wrong, dropping garbage into the last byte and failing authentication. Now, we notice this and whinge to our log file that we're compensating for the corrupt data.
This commit is contained in:
parent
d3544a6381
commit
8466587a00
@ -744,6 +744,11 @@ chap_Input(struct bundle *bundle, struct link *l, struct mbuf *bp)
|
||||
}
|
||||
*ans = chap->auth.id;
|
||||
bp = mbuf_Read(bp, ans + 1, alen);
|
||||
if (p->link.lcp.want_authtype == 0x81 && ans[alen] != '\0') {
|
||||
log_Printf(LogWARN, "%s: Compensating for corrupt (Win98?) "
|
||||
"CHAP81 RESPONSE\n", l->name);
|
||||
ans[alen] = '\0';
|
||||
}
|
||||
ans[alen+1] = '\0';
|
||||
bp = auth_ReadName(&chap->auth, bp, len);
|
||||
#ifdef HAVE_DES
|
||||
|
Loading…
Reference in New Issue
Block a user