mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-01-27 06:35:22 +00:00
Restored check on salt length to the original
Following code review by Manuel Pégourié-Gonnard Signed-off-by: Cédric Meuter <cedric.meuter@worldline.com>
This commit is contained in:
parent
d2dc1f1a83
commit
2ee085002b
@ -1856,7 +1856,7 @@ static int rsa_rsassa_pss_sign( mbedtls_rsa_context *ctx,
|
||||
else
|
||||
slen = olen - hlen - 2;
|
||||
}
|
||||
else if ( ( (size_t) saltlen ) > olen - hlen - 2 )
|
||||
else if ( (saltlen < 0) || ((size_t) saltlen > olen - hlen - 2) )
|
||||
{
|
||||
return( MBEDTLS_ERR_RSA_BAD_INPUT_DATA );
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user