Merge pull request #1608 from dgarske/maxcerfix

Resolves issue with reassembling large certificates
This commit is contained in:
toddouska 2018-06-08 08:25:14 -07:00 committed by GitHub
commit bea0e6142a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -8276,7 +8276,7 @@ int ProcessPeerCerts(WOLFSSL* ssl, byte* input, word32* inOutIdx,
}
c24to32(input + args->idx, &listSz);
args->idx += OPAQUE24_LEN;
if (listSz > MAX_RECORD_SIZE) {
if (listSz > MAX_CERTIFICATE_SZ) {
ERROR_OUT(BUFFER_ERROR, exit_ppc);
}
if ((args->idx - args->begin) + listSz != totalSz) {