aboutsummaryrefslogtreecommitdiffstats
path: root/crypto/algboss.c
diff options
context:
space:
mode:
authorHerbert Xu <herbert@gondor.apana.org.au>2008-08-17 03:01:56 -0400
committerHerbert Xu <herbert@gondor.apana.org.au>2008-08-29 01:49:58 -0400
commit1aa4ecd95d8d67d21731a00646326a71295dafa3 (patch)
treea79aaa58791408642dc2a817795b7b7008cff5f9 /crypto/algboss.c
parent73d3864a4823abda19ebc4387b6ddcbf416e3a77 (diff)
crypto: cryptomgr - Test ciphers using ECB
As it is we only test ciphers when combined with a mode. That means users that do not invoke a mode of operations may get an untested cipher. This patch tests all ciphers using the ECB mode so that simple cipher users such as ansi-cprng are also protected. Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'crypto/algboss.c')
-rw-r--r--crypto/algboss.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/crypto/algboss.c b/crypto/algboss.c
index ed9f663c82c6..4601e4267c88 100644
--- a/crypto/algboss.c
+++ b/crypto/algboss.c
@@ -210,10 +210,7 @@ static int cryptomgr_test(void *data)
210 CRYPTO_ALG_TYPE_BLKCIPHER_MASK) && !(type & CRYPTO_ALG_GENIV)) 210 CRYPTO_ALG_TYPE_BLKCIPHER_MASK) && !(type & CRYPTO_ALG_GENIV))
211 goto skiptest; 211 goto skiptest;
212 212
213 if ((type & CRYPTO_ALG_TYPE_MASK) == CRYPTO_ALG_TYPE_CIPHER) 213 err = alg_test(param->driver, param->alg, type, CRYPTO_ALG_TESTED);
214 goto skiptest;
215
216 err = alg_test(param->driver, param->alg, 0, CRYPTO_ALG_TESTED);
217 214
218skiptest: 215skiptest:
219 crypto_alg_tested(param->driver, err); 216 crypto_alg_tested(param->driver, err);