Commit f82419ac authored by Stephan Mueller's avatar Stephan Mueller Committed by Herbert Xu
Browse files

crypto: serpent_avx2 - mark Serpent AVX2 helper ciphers



Flag all Serpent AVX2 helper ciphers as internal ciphers to prevent
them from being called by normal users.
Signed-off-by: default avatarStephan Mueller <smueller@chronox.de>
Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
parent e69b8a46
...@@ -309,7 +309,8 @@ static struct crypto_alg srp_algs[10] = { { ...@@ -309,7 +309,8 @@ static struct crypto_alg srp_algs[10] = { {
.cra_name = "__ecb-serpent-avx2", .cra_name = "__ecb-serpent-avx2",
.cra_driver_name = "__driver-ecb-serpent-avx2", .cra_driver_name = "__driver-ecb-serpent-avx2",
.cra_priority = 0, .cra_priority = 0,
.cra_flags = CRYPTO_ALG_TYPE_BLKCIPHER, .cra_flags = CRYPTO_ALG_TYPE_BLKCIPHER |
CRYPTO_ALG_INTERNAL,
.cra_blocksize = SERPENT_BLOCK_SIZE, .cra_blocksize = SERPENT_BLOCK_SIZE,
.cra_ctxsize = sizeof(struct serpent_ctx), .cra_ctxsize = sizeof(struct serpent_ctx),
.cra_alignmask = 0, .cra_alignmask = 0,
...@@ -329,7 +330,8 @@ static struct crypto_alg srp_algs[10] = { { ...@@ -329,7 +330,8 @@ static struct crypto_alg srp_algs[10] = { {
.cra_name = "__cbc-serpent-avx2", .cra_name = "__cbc-serpent-avx2",
.cra_driver_name = "__driver-cbc-serpent-avx2", .cra_driver_name = "__driver-cbc-serpent-avx2",
.cra_priority = 0, .cra_priority = 0,
.cra_flags = CRYPTO_ALG_TYPE_BLKCIPHER, .cra_flags = CRYPTO_ALG_TYPE_BLKCIPHER |
CRYPTO_ALG_INTERNAL,
.cra_blocksize = SERPENT_BLOCK_SIZE, .cra_blocksize = SERPENT_BLOCK_SIZE,
.cra_ctxsize = sizeof(struct serpent_ctx), .cra_ctxsize = sizeof(struct serpent_ctx),
.cra_alignmask = 0, .cra_alignmask = 0,
...@@ -349,7 +351,8 @@ static struct crypto_alg srp_algs[10] = { { ...@@ -349,7 +351,8 @@ static struct crypto_alg srp_algs[10] = { {
.cra_name = "__ctr-serpent-avx2", .cra_name = "__ctr-serpent-avx2",
.cra_driver_name = "__driver-ctr-serpent-avx2", .cra_driver_name = "__driver-ctr-serpent-avx2",
.cra_priority = 0, .cra_priority = 0,
.cra_flags = CRYPTO_ALG_TYPE_BLKCIPHER, .cra_flags = CRYPTO_ALG_TYPE_BLKCIPHER |
CRYPTO_ALG_INTERNAL,
.cra_blocksize = 1, .cra_blocksize = 1,
.cra_ctxsize = sizeof(struct serpent_ctx), .cra_ctxsize = sizeof(struct serpent_ctx),
.cra_alignmask = 0, .cra_alignmask = 0,
...@@ -370,7 +373,8 @@ static struct crypto_alg srp_algs[10] = { { ...@@ -370,7 +373,8 @@ static struct crypto_alg srp_algs[10] = { {
.cra_name = "__lrw-serpent-avx2", .cra_name = "__lrw-serpent-avx2",
.cra_driver_name = "__driver-lrw-serpent-avx2", .cra_driver_name = "__driver-lrw-serpent-avx2",
.cra_priority = 0, .cra_priority = 0,
.cra_flags = CRYPTO_ALG_TYPE_BLKCIPHER, .cra_flags = CRYPTO_ALG_TYPE_BLKCIPHER |
CRYPTO_ALG_INTERNAL,
.cra_blocksize = SERPENT_BLOCK_SIZE, .cra_blocksize = SERPENT_BLOCK_SIZE,
.cra_ctxsize = sizeof(struct serpent_lrw_ctx), .cra_ctxsize = sizeof(struct serpent_lrw_ctx),
.cra_alignmask = 0, .cra_alignmask = 0,
...@@ -394,7 +398,8 @@ static struct crypto_alg srp_algs[10] = { { ...@@ -394,7 +398,8 @@ static struct crypto_alg srp_algs[10] = { {
.cra_name = "__xts-serpent-avx2", .cra_name = "__xts-serpent-avx2",
.cra_driver_name = "__driver-xts-serpent-avx2", .cra_driver_name = "__driver-xts-serpent-avx2",
.cra_priority = 0, .cra_priority = 0,
.cra_flags = CRYPTO_ALG_TYPE_BLKCIPHER, .cra_flags = CRYPTO_ALG_TYPE_BLKCIPHER |
CRYPTO_ALG_INTERNAL,
.cra_blocksize = SERPENT_BLOCK_SIZE, .cra_blocksize = SERPENT_BLOCK_SIZE,
.cra_ctxsize = sizeof(struct serpent_xts_ctx), .cra_ctxsize = sizeof(struct serpent_xts_ctx),
.cra_alignmask = 0, .cra_alignmask = 0,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment