partly import changes from tenfourfox:

- #627: M1631583 M1631597 M1636771 M1637222 M1649316 M1651520 (2373458b5)
- #627: M1631573 (0abd0fc5d)
This commit is contained in:
roytam1 2020-10-09 21:23:26 +08:00
commit 75e16e5121
10 changed files with 31511 additions and 31 deletions

View file

@ -111,7 +111,7 @@ ChaCha20Poly1305_InitContext(ChaCha20Poly1305Context *ctx,
PORT_SetError(SEC_ERROR_BAD_KEY);
return SECFailure;
}
if (tagLen == 0 || tagLen > 16) {
if (tagLen != 16) {
PORT_SetError(SEC_ERROR_INPUT_LEN);
return SECFailure;
}