Forgive a DTLS session trying to send too much at once. (ZD12921)

This commit is contained in:
John Safranek
2021-09-30 14:27:21 -07:00
parent 998c7a9cb9
commit b0de40d10a

View File

@ -19247,9 +19247,13 @@ int ReceiveData(WOLFSSL* ssl, byte* output, int sz, int peek)
if (ssl->options.dtls) {
/* In DTLS mode, we forgive some errors and allow the session
* to continue despite them. */
if (ssl->error == VERIFY_MAC_ERROR || ssl->error == DECRYPT_ERROR)
if (ssl->error == VERIFY_MAC_ERROR ||
ssl->error == DECRYPT_ERROR ||
ssl->error == DTLS_SIZE_ERROR) {
ssl->error = 0;
}
}
#endif /* WOLFSSL_DTLS */
if (ssl->error != 0 && ssl->error != WANT_WRITE