/linux/include/crypto/internal/ |
H A D | cipher.h | 21 * DOC: Single Block Cipher API 23 * The single block cipher API is used with the ciphers of type 24 * CRYPTO_ALG_TYPE_CIPHER (listed as type "cipher" in /proc/crypto). 26 * Using the single block cipher API calls, operations with the basic cipher 27 * primitive can be implemented. These cipher primitives exclude any block 30 * The purpose of this single block cipher API is to support the implementation 31 * of templates or other concepts that only need to perform the cipher operation 32 * on one block at a time. Templates invoke the underlying cipher primitive 33 * block-wise and process either the input or the output data of these cipher 43 * crypto_alloc_cipher() - allocate single block cipher handle [all …]
|
/linux/arch/x86/crypto/ |
H A D | Kconfig | 13 Block cipher: AES cipher algorithms 14 AEAD cipher: AES with GCM 31 Block cipher: Blowfish cipher algorithm 42 Block cipher: Camellia cipher algorithms 79 Length-preserving ciphers: CAST5 (CAST-128) cipher algorithm 96 Length-preserving ciphers: CAST6 (CAST-256) cipher algorithm 111 Block cipher: Triple DES EDE (FIPS 46-3) cipher algorithm 125 Length-preserving ciphers: Serpent cipher algorithm 140 Length-preserving ciphers: Serpent cipher algorithm 156 Length-preserving ciphers: Serpent cipher algorithm [all …]
|
/linux/include/crypto/ |
H A D | aead.h | 18 * DOC: Authenticated Encryption With Associated Data (AEAD) Cipher API 20 * The AEAD cipher API is used with the ciphers of type CRYPTO_ALG_TYPE_AEAD 25 * with the following cipher string: 27 * authenc(keyed message digest, block cipher) 31 * The example code provided for the symmetric key cipher operation applies 36 * decryption operation. Another deviation from the asynchronous block cipher 40 * code is the key bonus an AEAD cipher has over "standard" block chaining 105 * struct aead_alg - AEAD cipher definition 135 * @base: Definition of a generic crypto cipher algorithm. 168 * crypto_alloc_aead() - allocate AEAD cipher handle [all …]
|
/linux/Documentation/crypto/ |
H A D | userspace-if.rst | 13 consumer and never as a provider of a transformation or cipher 56 A cipher is accessed with the same name as done for the in-kernel API 61 user space application. User space invokes the cipher operation with the 62 send()/write() system call family. The result of the cipher operation is 73 parameter specified below for the different cipher types. 79 particular cipher instance. When invoking send/write or recv/read 83 In-place Cipher operation 87 space interface allows the cipher operation in-place. That means that 90 is of particular interest for symmetric cipher operations where a 101 The message digest type to be used for the cipher operation is selected [all …]
|
H A D | intro.rst | 19 Therefore, a cipher handle variable usually has the name "tfm". Besides 37 Note: The terms "transformation" and cipher algorithm are used 56 to as a "cipher handle". Such a cipher handle is always subject to the 58 a cipher handle: 60 1. Initialization of a cipher handle. 62 2. Execution of all intended cipher operations applicable for the handle 63 where the cipher handle must be furnished to every API call. 65 3. Destruction of a cipher handle. 67 When using the initialization API calls, a cipher handle is created and
|
H A D | devel-algos.rst | 1 Developing Cipher Algorithms 47 Single-Block Symmetric Ciphers [CIPHER] 53 implementations, that being the CIPHER type used for symmetric ciphers. 54 The CIPHER type is used for transformations which operate on exactly one 60 The registration of [CIPHER] algorithm is specific in that struct 61 crypto_alg field .cra_type is empty. The .cra_u.cipher has to be 66 Cipher Definition With struct cipher_alg 69 Struct cipher_alg defines a single block cipher. 103 This section describes the multi-block cipher transformation 111 The registration of multi-block cipher algorithms is one of the most [all …]
|
/linux/crypto/ |
H A D | Kconfig | 247 tristate "Kerberos 5 combined hash+cipher support" 253 Combined hash and cipher support for Kerberos 5 RFC3961 simplified 356 AES cipher algorithms (Rijndael)(FIPS-197, ISO/IEC 18033-3) 374 AES cipher algorithms (Rijndael)(FIPS-197, ISO/IEC 18033-3) 395 Anubis cipher algorithm 397 Anubis is a variable key length cipher which can use keys from 408 ARIA cipher algorithm (RFC5794) 424 Blowfish cipher algorithm, by Bruce Schneier 426 This is a variable key length cipher which can use keys from 32 435 Common parts of the Blowfish cipher algorithm shared by the [all …]
|
H A D | skcipher.c | 3 * Symmetric key cipher operations. 13 #include <crypto/internal/cipher.h> 132 struct skcipher_alg *cipher = crypto_skcipher_alg(tfm); in skcipher_setkey_unaligned() local 144 ret = cipher->setkey(tfm, alignbuffer, keylen); in skcipher_setkey_unaligned() 152 struct skcipher_alg *cipher = crypto_skcipher_alg(tfm); in crypto_skcipher_setkey() local 156 if (cipher->co.base.cra_type != &crypto_skcipher_type) { in crypto_skcipher_setkey() 167 if (keylen < cipher->min_keysize || keylen > cipher->max_keysize) in crypto_skcipher_setkey() 173 err = cipher->setkey(tfm, key, keylen); in crypto_skcipher_setkey() 537 struct crypto_cipher *cipher = skcipher_cipher_simple(tfm); in skcipher_setkey_simple() local 539 crypto_cipher_clear_flags(cipher, CRYPTO_TFM_REQ_MASK); in skcipher_setkey_simple() [all …]
|
/linux/drivers/crypto/cavium/nitrox/ |
H A D | nitrox_skcipher.c | 24 * supported cipher list 41 const struct nitrox_cipher *cipher = flexi_cipher_table; in flexi_cipher_type() local 43 while (cipher->name) { in flexi_cipher_type() 44 if (!strcmp(cipher->name, name)) in flexi_cipher_type() 46 cipher++; in flexi_cipher_type() 48 return cipher->value; in flexi_cipher_type() 83 struct crypto_skcipher *cipher = crypto_skcipher_reqtfm(skreq); in nitrox_cbc_cipher_callback() local 84 int ivsize = crypto_skcipher_ivsize(cipher); in nitrox_cbc_cipher_callback() 165 static inline int nitrox_skcipher_setkey(struct crypto_skcipher *cipher, in nitrox_skcipher_setkey() argument 169 struct crypto_tfm *tfm = crypto_skcipher_tfm(cipher); in nitrox_skcipher_setkey() [all …]
|
/linux/net/sunrpc/auth_gss/ |
H A D | gss_krb5_crypto.c | 66 * pad minimum plaintext length to at least a single cipher block. 88 * @tfm: initialized cipher transform 96 * cipher's ivsize. 393 gss_krb5_cts_crypt(struct crypto_sync_skcipher *cipher, struct xdr_buf *buf, in gss_krb5_cts_crypt() argument 398 SYNC_SKCIPHER_REQUEST_ON_STACK(req, cipher); in gss_krb5_cts_crypt() 427 skcipher_request_set_sync_tfm(req, cipher); in gss_krb5_cts_crypt() 450 memcpy(iv, data, crypto_sync_skcipher_ivsize(cipher)); in gss_krb5_cts_crypt() 460 * @cts_tfm: CBC cipher with CTS 461 * @cbc_tfm: base CBC cipher 468 * To provide confidentiality, encrypt using cipher block chaining [all …]
|
/linux/arch/sparc/crypto/ |
H A D | Kconfig | 12 Block cipher: DES (FIPS 46-2) cipher algorithm 13 Block cipher: Triple DES EDE (FIPS 46-3) cipher algorithm 24 Block ciphers: AES cipher algorithms (FIPS-197) 35 Block ciphers: Camellia cipher algorithms
|
/linux/arch/arm64/crypto/ |
H A D | Makefile | 17 obj-$(CONFIG_CRYPTO_SM4_ARM64_CE) += sm4-ce-cipher.o 18 sm4-ce-cipher-y := sm4-ce-cipher-glue.o sm4-ce-cipher-core.o 38 obj-$(CONFIG_CRYPTO_AES_ARM64_CE) += aes-ce-cipher.o 39 aes-ce-cipher-y := aes-ce-core.o aes-ce-glue.o 54 aes-arm64-y := aes-cipher-core.o aes-cipher-glue.o
|
/linux/drivers/nvme/common/ |
H A D | keyring.c | 200 enum nvme_tcp_tls_cipher cipher; member 204 .cipher = NVME_TCP_TLS_CIPHER_SHA384, }, 207 .cipher = NVME_TCP_TLS_CIPHER_SHA256, }, 210 .cipher = NVME_TCP_TLS_CIPHER_SHA384, }, 213 .cipher = NVME_TCP_TLS_CIPHER_SHA256, }, 216 .cipher = NVME_TCP_TLS_CIPHER_SHA384, }, 219 .cipher = NVME_TCP_TLS_CIPHER_SHA256, }, 222 .cipher = NVME_TCP_TLS_CIPHER_SHA384, }, 225 .cipher = NVME_TCP_TLS_CIPHER_SHA256, }, 241 enum nvme_tcp_tls_cipher cipher = nvme_tls_psk_prio[prio].cipher; in nvme_tls_psk_default() local [all …]
|
/linux/arch/arm/crypto/ |
H A D | Kconfig | 57 Block ciphers: AES cipher algorithms (FIPS-197) 77 Length-preserving ciphers: AES cipher algorithms (FIPS-197) 78 with block cipher modes: 80 - CBC (Cipher Block Chaining) mode (NIST SP800-38A) 104 Length-preserving ciphers: AES cipher algorithms (FIPS-197) 105 with block cipher modes: 107 - CBC (Cipher Block Chaining) mode (NIST SP800-38A) 109 - CTS (Cipher Text Stealing) mode (NIST SP800-38A)
|
/linux/drivers/crypto/cavium/cpt/ |
H A D | cptvf_algs.c | 232 static int cvm_xts_setkey(struct crypto_skcipher *cipher, const u8 *key, in cvm_xts_setkey() argument 235 struct cvm_enc_ctx *ctx = crypto_skcipher_ctx(cipher); in cvm_xts_setkey() 240 err = xts_verify_key(cipher, key, keylen); in cvm_xts_setkey() 288 static int cvm_setkey(struct crypto_skcipher *cipher, const u8 *key, in cvm_setkey() argument 291 struct cvm_enc_ctx *ctx = crypto_skcipher_ctx(cipher); in cvm_setkey() 302 static int cvm_cbc_aes_setkey(struct crypto_skcipher *cipher, const u8 *key, in cvm_cbc_aes_setkey() argument 305 return cvm_setkey(cipher, key, keylen, AES_CBC); in cvm_cbc_aes_setkey() 308 static int cvm_ecb_aes_setkey(struct crypto_skcipher *cipher, const u8 *key, in cvm_ecb_aes_setkey() argument 311 return cvm_setkey(cipher, key, keylen, AES_ECB); in cvm_ecb_aes_setkey() 314 static int cvm_cbc_des3_setkey(struct crypto_skcipher *cipher, const u8 *key, in cvm_cbc_des3_setkey() argument [all …]
|
/linux/Documentation/netlink/specs/ |
H A D | ovpn.yaml | 21 name: cipher-alg 248 name: cipher-alg 250 doc: The cipher to be used when communicating with the peer 251 enum: cipher-alg 266 name: cipher-key 268 doc: The actual key to be used by the cipher 276 obtain the actual cipher IV 291 name: cipher-alg 323 doc: Peer specific cipher configuration 450 doc: Add a cipher key for a specific peer [all …]
|
/linux/net/wireless/ |
H A D | wext-compat.c | 430 if (params->cipher == WLAN_CIPHER_SUITE_AES_CMAC) { in cfg80211_set_encryption() 476 wdev->wext.keys->params[idx].cipher = 0; in cfg80211_set_encryption() 501 else if (params->cipher != WLAN_CIPHER_SUITE_WEP40 && in cfg80211_set_encryption() 502 params->cipher != WLAN_CIPHER_SUITE_WEP104) in cfg80211_set_encryption() 512 if (!addr && (params->cipher == WLAN_CIPHER_SUITE_WEP40 || in cfg80211_set_encryption() 513 params->cipher == WLAN_CIPHER_SUITE_WEP104)) { in cfg80211_set_encryption() 521 if ((params->cipher == WLAN_CIPHER_SUITE_WEP40 || in cfg80211_set_encryption() 522 params->cipher == WLAN_CIPHER_SUITE_WEP104) && in cfg80211_set_encryption() 548 if (params->cipher == WLAN_CIPHER_SUITE_AES_CMAC && in cfg80211_set_encryption() 618 params.cipher = WLAN_CIPHER_SUITE_WEP40; in cfg80211_wext_siwencode() [all …]
|
/linux/Documentation/admin-guide/device-mapper/ |
H A D | dm-crypt.rst | 13 <cipher> <key> <iv_offset> <device path> \ 16 <cipher> 17 Encryption cipher, encryption mode and Initial Vector (IV) generator. 19 The cipher specifications format is:: 21 cipher[:keycount]-chainmode-ivmode[:ivopts] 29 Cipher format also supports direct specification with kernel crypt API 34 The crypto API cipher specifications format is:: 55 You can only use key sizes that are valid for the selected cipher 210 # Create a crypt device using cryptsetup and LUKS header with default cipher
|
/linux/arch/s390/crypto/ |
H A D | Kconfig | 40 Block cipher: AES cipher algorithms (FIPS 197) 41 AEAD cipher: AES with GCM 62 Block ciphers: DES (FIPS 46-2) cipher algorithm 63 Block ciphers: Triple DES EDE (FIPS 46-3) cipher algorithm
|
/linux/tools/testing/crypto/chacha20-s390/ |
H A D | test-cipher.c | 50 /* Perform cipher operations with the chacha lib */ 51 static int test_lib_chacha(u8 *revert, u8 *cipher, u8 *plain) in test_lib_chacha() argument 72 chacha_crypt_arch(&chacha_state, cipher, plain, data_size, 20); in test_lib_chacha() 78 16, 1, cipher, in test_lib_chacha() 87 chacha_crypt_arch(&chacha_state, revert, cipher, data_size, 20); in test_lib_chacha() 100 /* Perform cipher operations with skcipher */ 125 /* Initialize and trigger cipher operations */ 126 static int test_skcipher(char *name, u8 *revert, u8 *cipher, u8 *plain) in test_skcipher() argument 174 sg_init_one(&sk.sgout, cipher, data_size); in test_skcipher() 191 16, 1, cipher, in test_skcipher() [all...] |
/linux/drivers/gpu/drm/nouveau/nvkm/engine/cipher/ |
H A D | g84.c | 24 #include <engine/cipher.h> 80 g84_cipher_intr(struct nvkm_engine *cipher) in g84_cipher_intr() argument 82 struct nvkm_subdev *subdev = &cipher->subdev; in g84_cipher_intr() 92 chan = nvkm_chan_get_inst(cipher, (u64)inst << 12, &flags); in g84_cipher_intr() 108 g84_cipher_init(struct nvkm_engine *cipher) in g84_cipher_init() argument 110 struct nvkm_device *device = cipher->subdev.device; in g84_cipher_init()
|
/linux/net/tls/ |
H A D | tls_main.c | 61 #define CHECK_CIPHER_DESC(cipher,ci) \ argument 62 static_assert(cipher ## _IV_SIZE <= TLS_MAX_IV_SIZE); \ 63 static_assert(cipher ## _SALT_SIZE <= TLS_MAX_SALT_SIZE); \ 64 static_assert(cipher ## _REC_SEQ_SIZE <= TLS_MAX_REC_SEQ_SIZE); \ 65 static_assert(cipher ## _TAG_SIZE == TLS_TAG_SIZE); \ 66 static_assert(sizeof_field(struct ci, iv) == cipher ## _IV_SIZE); \ 67 static_assert(sizeof_field(struct ci, key) == cipher ## _KEY_SIZE); \ 68 static_assert(sizeof_field(struct ci, salt) == cipher ## _SALT_SIZE); \ 69 static_assert(sizeof_field(struct ci, rec_seq) == cipher ## _REC_SEQ_SIZE); 78 #define CIPHER_DESC(cipher,ci,algname,_offloadable) [cipher - TLS_CIPHER_MIN] = { \ argument [all …]
|
/linux/drivers/net/wireless/intel/iwlwifi/mvm/ |
H A D | mld-key.c | 74 switch (keyconf->cipher) { in iwl_mvm_get_sec_flags() 198 if (keyconf->cipher == WLAN_CIPHER_SUITE_WEP40 || in iwl_mvm_mld_send_key() 199 keyconf->cipher == WLAN_CIPHER_SUITE_WEP104) in iwl_mvm_mld_send_key() 208 if (keyconf->cipher == WLAN_CIPHER_SUITE_WEP40 || in iwl_mvm_mld_send_key() 209 keyconf->cipher == WLAN_CIPHER_SUITE_WEP104) in iwl_mvm_mld_send_key() 215 if (keyconf->cipher == WLAN_CIPHER_SUITE_TKIP) { in iwl_mvm_mld_send_key() 232 if (keyconf->cipher == WLAN_CIPHER_SUITE_WEP40 || in iwl_mvm_mld_send_key() 233 keyconf->cipher == WLAN_CIPHER_SUITE_WEP104) { in iwl_mvm_mld_send_key() 335 if (keyconf->cipher == WLAN_CIPHER_SUITE_WEP40 || in _iwl_mvm_sec_key_del() 336 keyconf->cipher == WLAN_CIPHER_SUITE_WEP104) { in _iwl_mvm_sec_key_del()
|
/linux/drivers/net/wireless/ralink/rt2x00/ |
H A D | rt2x00debug.c | 87 * All statistics are stored separately per cipher type. 113 enum cipher cipher = rxdesc->cipher; in rt2x00debug_update_crypto() local 116 if (cipher == CIPHER_TKIP_NO_MIC) in rt2x00debug_update_crypto() 117 cipher = CIPHER_TKIP; in rt2x00debug_update_crypto() 118 if (cipher == CIPHER_NONE || cipher >= CIPHER_MAX) in rt2x00debug_update_crypto() 122 cipher--; in rt2x00debug_update_crypto() 124 intf->crypto_stats[cipher].success += (status == RX_CRYPTO_SUCCESS); in rt2x00debug_update_crypto() 125 intf->crypto_stats[cipher].icv_error += (status == RX_CRYPTO_FAIL_ICV); in rt2x00debug_update_crypto() 126 intf->crypto_stats[cipher].mic_error += (status == RX_CRYPTO_FAIL_MIC); in rt2x00debug_update_crypto() 127 intf->crypto_stats[cipher].key_error += (status == RX_CRYPTO_FAIL_KEY); in rt2x00debug_update_crypto() [all …]
|
/linux/tools/testing/selftests/bpf/progs/ |
H A D | crypto_bench.c | 14 char cipher[128] = {}; variable 34 if (!cipher[0] || !key_len || key_len > 256) { in crypto_setup() 39 __builtin_memcpy(¶ms.algo, cipher, sizeof(cipher)); in crypto_setup()
|