diff options
author | 2015-09-04 09:57:24 +0200 | |
---|---|---|
committer | 2015-10-14 14:31:59 +0200 | |
commit | 1330a1258dc20caa5961b07aa62482793d6f2ecf (patch) | |
tree | dddc2a4438dc63b69ab1aad5d411032b4a206f5a /drivers/s390/crypto/zcrypt_api.c | |
parent | s390/numa: write kernel message when emu_size has been increased (diff) | |
download | linux-1330a1258dc20caa5961b07aa62482793d6f2ecf.tar.gz linux-1330a1258dc20caa5961b07aa62482793d6f2ecf.tar.bz2 linux-1330a1258dc20caa5961b07aa62482793d6f2ecf.zip |
s390/zcrypt: enable odd RSA modulus sizes in CRT format
In the past only even modulus sizes were allowed for RSA keys in
CRT format. This restriction was based on limited RSA key generation
on older crypto adapters that provides only even modulus sizes. This
restriction is not valid any more.
Revoke restrictions that crypto requests can be serviced with odd
RSA modulus length in CRT format.
Signed-off-by: Ingo Tuchscherer <ingo.tuchscherer@linux.vnet.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Diffstat (limited to 'drivers/s390/crypto/zcrypt_api.c')
-rw-r--r-- | drivers/s390/crypto/zcrypt_api.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/s390/crypto/zcrypt_api.c b/drivers/s390/crypto/zcrypt_api.c index 4eb45546a3aa..a9603ebbc1f8 100644 --- a/drivers/s390/crypto/zcrypt_api.c +++ b/drivers/s390/crypto/zcrypt_api.c @@ -472,8 +472,7 @@ static long zcrypt_rsa_crt(struct ica_rsa_modexpo_crt *crt) unsigned long long z1, z2, z3; int rc, copied; - if (crt->outputdatalength < crt->inputdatalength || - (crt->inputdatalength & 1)) + if (crt->outputdatalength < crt->inputdatalength) return -EINVAL; /* * As long as outputdatalength is big enough, we can set the |