[PATCH 0/2] crypto: rsassa-pkcs1: fix undersized key handling

Jérémy Jean posted 2 patches 1 month ago
crypto/rsassa-pkcs1.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
[PATCH 0/2] crypto: rsassa-pkcs1: fix undersized key handling
Posted by Jérémy Jean 1 month ago
PKCS#1 v1.5 requires an encoded message of at least 11 bytes. The
signing and verification functions do not reject smaller RSA modulus
sizes reported by the child implementation.

This series include two patches due to integer underflows:
* one in the signing function that can write OOB,
* one in the verification function that can read 1 byte OOB.

Jérémy Jean (2):
  crypto: rsassa-pkcs1: reject undersized keys when signing
  crypto: rsassa-pkcs1: reject undersized keys when verifying

 crypto/rsassa-pkcs1.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

-- 
2.47.3

Re: [PATCH 0/2] crypto: rsassa-pkcs1: fix undersized key handling
Posted by Herbert Xu 2 weeks, 2 days ago
On Wed, Aug 26, 2026 at 10:37:42AM +0000, Jérémy Jean wrote:
> PKCS#1 v1.5 requires an encoded message of at least 11 bytes. The
> signing and verification functions do not reject smaller RSA modulus
> sizes reported by the child implementation.
> 
> This series include two patches due to integer underflows:
> * one in the signing function that can write OOB,
> * one in the verification function that can read 1 byte OOB.
> 
> Jérémy Jean (2):
>   crypto: rsassa-pkcs1: reject undersized keys when signing
>   crypto: rsassa-pkcs1: reject undersized keys when verifying
> 
>  crypto/rsassa-pkcs1.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> -- 
> 2.47.3

All applied.  Thanks.
-- 
Email: Herbert Xu <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt