1
0
mirror of https://git.FreeBSD.org/src.git synced 2025-01-17 15:27:36 +00:00

merge fix from vendor for removing buffer overrun

This commit is contained in:
Assar Westerlund 2000-12-10 21:00:35 +00:00
parent fcbc584c3b
commit 7a7ff9f80d
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/vendor-crypto/kerberosIV/dist/; revision=69833

View File

@ -121,6 +121,9 @@ kdc_reply_cipher(KTEXT reply, KTEXT cip)
p += krb_get_int(p, &exp_date, 4, little_endian);
p++; /* master key version number */
p += krb_get_int(p, &clen, 2, little_endian);
if (reply->length - (p - reply->dat) < clen)
return INTK_PROT;
cip->length = clen;
memcpy(cip->dat, p, clen);
p += clen;