linux-crypto.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 00/16] crypto: restrict usage of helper ciphers
@ 2015-03-19  6:55 Stephan Mueller
  2015-03-19  6:57 ` [PATCH 01/16] crypto: prevent helper ciphers from being used Stephan Mueller
                   ` (15 more replies)
  0 siblings, 16 replies; 20+ messages in thread
From: Stephan Mueller @ 2015-03-19  6:55 UTC (permalink / raw)
  To: 'Herbert Xu; +Cc: linux-crypto, linux-kernel

Hi,

Based on the discussion in the thread [1], a flag is added to the
kernel crypto API to allow ciphers to be marked as internal.

The patch set is tested in FIPS and non-FIPS mode. In addition,
the enforcement that the helper cipher of __driver-gcm-aes-aesni
cannot be loaded, but the wrapper of rfc4106-gcm-aesni can be used
is tested to demonstrate that the patch works. The testing also shows
that of__driver-gcm-aes-aesni is subject to the testmgr self test an
can therefore be used in FIPS mode.

All cipher implementation whose definition has a cra_priority of 0
are marked as internal ciphers to prevent them from being called by
users.

The testing also includes the invocation of normal crypto operations
from user space via AF_ALG and libkcapi showing that all of them work
unaffected.

[1] http://comments.gmane.org/gmane.linux.kernel.cryptoapi/13705

Stephan Mueller (16):
  crypto: prevent helper ciphers from being used
  crypto: /proc/crypto: identify internal ciphers
  crypto: mark AES-NI helper ciphers
  crypto: mark AES-NI Camellia helper ciphers
  crypto: mark CAST5 helper ciphers
  crypto: mark AVX Camellia helper ciphers
  crypto: mark CAST6 helper ciphers
  crypto: mark ghash clmulni helper ciphers
  crypto: mark Serpent AVX2 helper ciphers
  crypto: mark Serpent AVX helper ciphers
  crypto: mark Serpent SSE2 helper ciphers
  crypto: mark Twofish AVX helper ciphers
  crypto: mark NEON bit sliced AES helper ciphers
  crypto: mark ARMv8 AES helper ciphers
  crypto: mark GHASH ARMv8 vmull.p64 helper ciphers
  crypto: mark 64 bit ARMv8 AES helper ciphers

 arch/arm/crypto/aes-ce-glue.c              | 12 ++++++++----
 arch/arm/crypto/aesbs-glue.c               |  9 ++++++---
 arch/arm/crypto/ghash-ce-glue.c            |  2 +-
 arch/arm64/crypto/aes-glue.c               | 12 ++++++++----
 arch/x86/crypto/aesni-intel_glue.c         | 19 ++++++++++++-------
 arch/x86/crypto/camellia_aesni_avx2_glue.c | 15 ++++++++++-----
 arch/x86/crypto/camellia_aesni_avx_glue.c  | 15 ++++++++++-----
 arch/x86/crypto/cast5_avx_glue.c           |  9 ++++++---
 arch/x86/crypto/cast6_avx_glue.c           | 15 ++++++++++-----
 arch/x86/crypto/ghash-clmulni-intel_glue.c |  3 ++-
 arch/x86/crypto/serpent_avx2_glue.c        | 15 ++++++++++-----
 arch/x86/crypto/serpent_avx_glue.c         | 15 ++++++++++-----
 arch/x86/crypto/serpent_sse2_glue.c        | 15 ++++++++++-----
 arch/x86/crypto/twofish_avx_glue.c         | 15 ++++++++++-----
 crypto/ablkcipher.c                        |  2 +-
 crypto/aead.c                              |  2 +-
 crypto/api.c                               | 21 ++++++++++++++++++++-
 crypto/internal.h                          |  2 ++
 crypto/proc.c                              |  3 +++
 include/linux/crypto.h                     |  6 ++++++
 20 files changed, 146 insertions(+), 61 deletions(-)

-- 
2.1.0

^ permalink raw reply	[flat|nested] 20+ messages in thread

end of thread, other threads:[~2015-03-19  7:29 UTC | newest]

Thread overview: 20+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-03-19  6:55 [PATCH 00/16] crypto: restrict usage of helper ciphers Stephan Mueller
2015-03-19  6:57 ` [PATCH 01/16] crypto: prevent helper ciphers from being used Stephan Mueller
2015-03-19  7:16   ` Herbert Xu
2015-03-19  7:23     ` Stephan Mueller
2015-03-19  7:29       ` Herbert Xu
2015-03-19  6:58 ` [PATCH 02/16] crypto: /proc/crypto: identify internal ciphers Stephan Mueller
2015-03-19  6:59 ` [PATCH 03/16] crypto: mark AES-NI helper ciphers Stephan Mueller
2015-03-19  6:59 ` [PATCH 04/16] crypto: mark AES-NI Camellia " Stephan Mueller
2015-03-19  7:00 ` [PATCH 05/16] crypto: mark CAST5 " Stephan Mueller
2015-03-19  7:00 ` [PATCH 06/16] crypto: mark AVX Camellia " Stephan Mueller
2015-03-19  7:01 ` [PATCH 07/16] crypto: mark CAST6 " Stephan Mueller
2015-03-19  7:02 ` [PATCH 08/16] crypto: mark ghash clmulni " Stephan Mueller
2015-03-19  7:02 ` [PATCH 09/16] crypto: mark Serpent AVX2 " Stephan Mueller
2015-03-19  7:03 ` [PATCH 10/16] crypto: mark Serpent AVX " Stephan Mueller
2015-03-19  7:03 ` [PATCH 11/16] crypto: mark Serpent SSE2 " Stephan Mueller
2015-03-19  7:04 ` [PATCH 12/16] crypto: mark Twofish AVX " Stephan Mueller
2015-03-19  7:05 ` [PATCH 13/16] crypto: mark NEON bit sliced AES " Stephan Mueller
2015-03-19  7:05 ` [PATCH 14/16] crypto: mark ARMv8 " Stephan Mueller
2015-03-19  7:06 ` [PATCH 15/16] crypto: mark GHASH ARMv8 vmull.p64 " Stephan Mueller
2015-03-19  7:06 ` [PATCH 16/16] crypto: mark 64 bit ARMv8 AES " Stephan Mueller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).