/Linux-v4.19/Documentation/crypto/ |
D | architecture.rst | 8 cipher types: 33 A single block cipher may even be called with multiple templates. 34 However, templates cannot be used without a single cipher. 63 When using the synchronous API operation, the caller invokes a cipher 65 That means, the caller waits until the cipher operation completes. 71 implies that the invocation of a cipher operation will complete almost 72 instantly. That invocation triggers the cipher operation but it does not 73 signal its completion. Before invoking a cipher operation, the caller 75 signal the completion of the cipher operation. Furthermore, the caller 84 A cipher is referenced by the caller with a string. That string has the [all …]
|
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
|
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 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 111 .salg_name = "sha1" /* this is the cipher name */ [all …]
|
D | api.rst | 7 future. To obtain the functionality of an AEAD cipher with internal IV 8 generation, use the IV generator as a regular cipher. For example, 9 rfc4106(gcm(aes)) is the AEAD cipher with external IV generation and
|
/Linux-v4.19/net/sunrpc/auth_gss/ |
D | gss_krb5_seqnum.c | 46 struct crypto_skcipher *cipher; in krb5_make_rc4_seq_num() local 51 cipher = crypto_alloc_skcipher(kctx->gk5e->encrypt_name, 0, in krb5_make_rc4_seq_num() 53 if (IS_ERR(cipher)) in krb5_make_rc4_seq_num() 54 return PTR_ERR(cipher); in krb5_make_rc4_seq_num() 65 code = krb5_rc4_setup_seq_key(kctx, cipher, cksum); in krb5_make_rc4_seq_num() 69 code = krb5_encrypt(cipher, cksum, plain, buf, 8); in krb5_make_rc4_seq_num() 71 crypto_free_skcipher(cipher); in krb5_make_rc4_seq_num() 104 struct crypto_skcipher *cipher; in krb5_get_rc4_seq_num() local 109 cipher = crypto_alloc_skcipher(kctx->gk5e->encrypt_name, 0, in krb5_get_rc4_seq_num() 111 if (IS_ERR(cipher)) in krb5_get_rc4_seq_num() [all …]
|
D | gss_krb5_wrap.c | 242 struct crypto_skcipher *cipher; in gss_wrap_kerberos_v1() local 244 cipher = crypto_alloc_skcipher(kctx->gk5e->encrypt_name, 0, in gss_wrap_kerberos_v1() 246 if (IS_ERR(cipher)) in gss_wrap_kerberos_v1() 249 krb5_rc4_setup_enc_key(kctx, cipher, seq_send); in gss_wrap_kerberos_v1() 251 err = gss_encrypt_xdr_buf(cipher, buf, in gss_wrap_kerberos_v1() 253 crypto_free_skcipher(cipher); in gss_wrap_kerberos_v1() 330 struct crypto_skcipher *cipher; in gss_unwrap_kerberos_v1() local 333 cipher = crypto_alloc_skcipher(kctx->gk5e->encrypt_name, 0, in gss_unwrap_kerberos_v1() 335 if (IS_ERR(cipher)) in gss_unwrap_kerberos_v1() 338 krb5_rc4_setup_enc_key(kctx, cipher, seqnum); in gss_unwrap_kerberos_v1() [all …]
|
D | gss_krb5_keys.c | 150 struct crypto_skcipher *cipher; in krb5_derive_key() local 160 cipher = crypto_alloc_skcipher(gk5e->encrypt_name, 0, in krb5_derive_key() 162 if (IS_ERR(cipher)) in krb5_derive_key() 164 if (crypto_skcipher_setkey(cipher, inkey->data, inkey->len)) in krb5_derive_key() 201 (*(gk5e->encrypt))(cipher, NULL, inblock.data, in krb5_derive_key() 241 crypto_free_skcipher(cipher); in krb5_derive_key()
|
/Linux-v4.19/drivers/crypto/amcc/ |
D | crypto4xx_alg.c | 81 struct crypto_skcipher *cipher = crypto_skcipher_reqtfm(req); in crypto4xx_crypt() local 82 struct crypto4xx_ctx *ctx = crypto_skcipher_ctx(cipher); in crypto4xx_crypt() 116 static int crypto4xx_setkey_aes(struct crypto_skcipher *cipher, in crypto4xx_setkey_aes() argument 122 struct crypto4xx_ctx *ctx = crypto_skcipher_ctx(cipher); in crypto4xx_setkey_aes() 128 crypto_skcipher_set_flags(cipher, in crypto4xx_setkey_aes() 169 int crypto4xx_setkey_aes_cbc(struct crypto_skcipher *cipher, in crypto4xx_setkey_aes_cbc() argument 172 return crypto4xx_setkey_aes(cipher, key, keylen, CRYPTO_MODE_CBC, in crypto4xx_setkey_aes_cbc() 176 int crypto4xx_setkey_aes_cfb(struct crypto_skcipher *cipher, in crypto4xx_setkey_aes_cfb() argument 179 return crypto4xx_setkey_aes(cipher, key, keylen, CRYPTO_MODE_CFB, in crypto4xx_setkey_aes_cfb() 183 int crypto4xx_setkey_aes_ecb(struct crypto_skcipher *cipher, in crypto4xx_setkey_aes_ecb() argument [all …]
|
D | crypto4xx_core.h | 131 struct crypto_skcipher *cipher; member 143 struct skcipher_alg cipher; member 168 int crypto4xx_setkey_aes_cbc(struct crypto_skcipher *cipher, 170 int crypto4xx_setkey_aes_cfb(struct crypto_skcipher *cipher, 172 int crypto4xx_setkey_aes_ctr(struct crypto_skcipher *cipher, 174 int crypto4xx_setkey_aes_ecb(struct crypto_skcipher *cipher, 176 int crypto4xx_setkey_aes_ofb(struct crypto_skcipher *cipher, 178 int crypto4xx_setkey_rfc3686(struct crypto_skcipher *cipher, 239 int crypto4xx_setkey_aes_ccm(struct crypto_aead *cipher, 243 int crypto4xx_setkey_aes_gcm(struct crypto_aead *cipher,
|
/Linux-v4.19/drivers/crypto/cavium/nitrox/ |
D | nitrox_algs.c | 42 const struct nitrox_cipher *cipher = flexi_cipher_table; in flexi_cipher_type() local 44 while (cipher->name) { in flexi_cipher_type() 45 if (!strcmp(cipher->name, name)) in flexi_cipher_type() 47 cipher++; in flexi_cipher_type() 49 return cipher->value; in flexi_cipher_type() 113 static inline int nitrox_skcipher_setkey(struct crypto_skcipher *cipher, in nitrox_skcipher_setkey() argument 117 struct crypto_tfm *tfm = crypto_skcipher_tfm(cipher); in nitrox_skcipher_setkey() 143 static int nitrox_aes_setkey(struct crypto_skcipher *cipher, const u8 *key, in nitrox_aes_setkey() argument 150 crypto_skcipher_set_flags(cipher, CRYPTO_TFM_RES_BAD_KEY_LEN); in nitrox_aes_setkey() 153 return nitrox_skcipher_setkey(cipher, aes_keylen, key, keylen); in nitrox_aes_setkey() [all …]
|
/Linux-v4.19/crypto/ |
D | cipher.c | 83 struct cipher_alg *cipher = &tfm->__crt_alg->cra_cipher; in cipher_encrypt_unaligned() local 86 cipher_crypt_unaligned(cipher->cia_encrypt, tfm, dst, src); in cipher_encrypt_unaligned() 90 cipher->cia_encrypt(tfm, dst, src); in cipher_encrypt_unaligned() 97 struct cipher_alg *cipher = &tfm->__crt_alg->cra_cipher; in cipher_decrypt_unaligned() local 100 cipher_crypt_unaligned(cipher->cia_decrypt, tfm, dst, src); in cipher_decrypt_unaligned() 104 cipher->cia_decrypt(tfm, dst, src); in cipher_decrypt_unaligned() 110 struct cipher_alg *cipher = &tfm->__crt_alg->cra_cipher; in crypto_init_cipher_ops() local 114 cipher_encrypt_unaligned : cipher->cia_encrypt; in crypto_init_cipher_ops() 116 cipher_decrypt_unaligned : cipher->cia_decrypt; in crypto_init_cipher_ops()
|
D | Kconfig | 177 cipher mode. Only select this option by hand if you expect to load 288 Support for the AEAD wrapper using the ChaCha20 stream cipher combined 422 This block cipher algorithm is required for IPSec. 430 This block cipher algorithm is required for TPM2 Cryptography. 439 This block cipher algorithm is required for IPSec. 458 This is the simplest block cipher algorithm. It simply encrypts 468 narrow block cipher mode for dm-crypt. Use it with cipher 471 rest is used to tie each cipher block to its logical position. 479 This block cipher algorithm is required for RxRPC. 487 XTS: IEEE1619/D16 narrow block cipher use with aes-xts-plain, [all …]
|
D | testmgr.c | 131 struct cipher_test_suite cipher; member 1748 const struct cipher_test_suite *suite = &desc->suite.cipher; in alg_test_cipher() 1770 const struct cipher_test_suite *suite = &desc->suite.cipher; in alg_test_skcipher() 2606 .cipher = __VECS(aes_cbc_tv_template) 2612 .cipher = __VECS(anubis_cbc_tv_template) 2618 .cipher = __VECS(bf_cbc_tv_template) 2624 .cipher = __VECS(camellia_cbc_tv_template) 2630 .cipher = __VECS(cast5_cbc_tv_template) 2636 .cipher = __VECS(cast6_cbc_tv_template) 2642 .cipher = __VECS(des_cbc_tv_template) [all …]
|
D | ctr.c | 162 struct crypto_cipher *cipher; in crypto_ctr_init_tfm() local 164 cipher = crypto_spawn_cipher(spawn); in crypto_ctr_init_tfm() 165 if (IS_ERR(cipher)) in crypto_ctr_init_tfm() 166 return PTR_ERR(cipher); in crypto_ctr_init_tfm() 168 ctx->child = cipher; in crypto_ctr_init_tfm() 319 struct crypto_skcipher *cipher; in crypto_rfc3686_init_tfm() local 323 cipher = crypto_spawn_skcipher(spawn); in crypto_rfc3686_init_tfm() 324 if (IS_ERR(cipher)) in crypto_rfc3686_init_tfm() 325 return PTR_ERR(cipher); in crypto_rfc3686_init_tfm() 327 ctx->child = cipher; in crypto_rfc3686_init_tfm() [all …]
|
D | cbc.c | 86 struct crypto_cipher *cipher; in crypto_cbc_init_tfm() local 88 cipher = crypto_spawn_cipher(spawn); in crypto_cbc_init_tfm() 89 if (IS_ERR(cipher)) in crypto_cbc_init_tfm() 90 return PTR_ERR(cipher); in crypto_cbc_init_tfm() 92 ctx->child = cipher; in crypto_cbc_init_tfm()
|
D | ecb.c | 102 struct crypto_cipher *cipher; in crypto_ecb_init_tfm() local 104 cipher = crypto_spawn_cipher(spawn); in crypto_ecb_init_tfm() 105 if (IS_ERR(cipher)) in crypto_ecb_init_tfm() 106 return PTR_ERR(cipher); in crypto_ecb_init_tfm() 108 ctx->child = cipher; in crypto_ecb_init_tfm()
|
/Linux-v4.19/drivers/crypto/bcm/ |
D | cipher.c | 165 if ((ctx->cipher.mode == CIPHER_MODE_XTS) && in spu_ablkcipher_rx_sg_create() 179 if (ctx->cipher.alg == CIPHER_ALG_RC4) in spu_ablkcipher_rx_sg_create() 234 if ((ctx->cipher.mode == CIPHER_MODE_XTS) && in spu_ablkcipher_tx_sg_create() 340 cipher_parms.alg = ctx->cipher.alg; in handle_ablkcipher_req() 341 cipher_parms.mode = ctx->cipher.mode; in handle_ablkcipher_req() 366 if ((ctx->cipher.mode == CIPHER_MODE_CBC) && in handle_ablkcipher_req() 382 if ((ctx->cipher.mode == CIPHER_MODE_CBC) && in handle_ablkcipher_req() 391 } else if (ctx->cipher.mode == CIPHER_MODE_CTR) { in handle_ablkcipher_req() 405 if (ctx->cipher.alg == CIPHER_ALG_RC4) { in handle_ablkcipher_req() 478 if ((ctx->cipher.mode == CIPHER_MODE_XTS) && in handle_ablkcipher_req() [all …]
|
/Linux-v4.19/drivers/crypto/cavium/cpt/ |
D | cptvf_algs.c | 235 static int cvm_xts_setkey(struct crypto_ablkcipher *cipher, const u8 *key, in cvm_xts_setkey() argument 238 struct crypto_tfm *tfm = crypto_ablkcipher_tfm(cipher); in cvm_xts_setkey() 292 static int cvm_setkey(struct crypto_ablkcipher *cipher, const u8 *key, in cvm_setkey() argument 295 struct crypto_tfm *tfm = crypto_ablkcipher_tfm(cipher); in cvm_setkey() 303 crypto_ablkcipher_set_flags(cipher, in cvm_setkey() 309 static int cvm_cbc_aes_setkey(struct crypto_ablkcipher *cipher, const u8 *key, in cvm_cbc_aes_setkey() argument 312 return cvm_setkey(cipher, key, keylen, AES_CBC); in cvm_cbc_aes_setkey() 315 static int cvm_ecb_aes_setkey(struct crypto_ablkcipher *cipher, const u8 *key, in cvm_ecb_aes_setkey() argument 318 return cvm_setkey(cipher, key, keylen, AES_ECB); in cvm_ecb_aes_setkey() 321 static int cvm_cfb_aes_setkey(struct crypto_ablkcipher *cipher, const u8 *key, in cvm_cfb_aes_setkey() argument [all …]
|
/Linux-v4.19/net/wireless/ |
D | wext-compat.c | 428 if (params->cipher == WLAN_CIPHER_SUITE_AES_CMAC) { in __cfg80211_set_encryption() 472 wdev->wext.keys->params[idx].cipher = 0; in __cfg80211_set_encryption() 495 else if (params->cipher != WLAN_CIPHER_SUITE_WEP40 && in __cfg80211_set_encryption() 496 params->cipher != WLAN_CIPHER_SUITE_WEP104) in __cfg80211_set_encryption() 506 if (!addr && (params->cipher == WLAN_CIPHER_SUITE_WEP40 || in __cfg80211_set_encryption() 507 params->cipher == WLAN_CIPHER_SUITE_WEP104)) { in __cfg80211_set_encryption() 515 if ((params->cipher == WLAN_CIPHER_SUITE_WEP40 || in __cfg80211_set_encryption() 516 params->cipher == WLAN_CIPHER_SUITE_WEP104) && in __cfg80211_set_encryption() 539 if (params->cipher == WLAN_CIPHER_SUITE_AES_CMAC && in __cfg80211_set_encryption() 615 params.cipher = WLAN_CIPHER_SUITE_WEP40; in cfg80211_wext_siwencode() [all …]
|
/Linux-v4.19/drivers/gpu/drm/nouveau/nvkm/engine/cipher/ |
D | g84.c | 80 g84_cipher_intr(struct nvkm_engine *cipher) in g84_cipher_intr() argument 82 struct nvkm_subdev *subdev = &cipher->subdev; in g84_cipher_intr() 109 g84_cipher_init(struct nvkm_engine *cipher) in g84_cipher_init() argument 111 struct nvkm_device *device = cipher->subdev.device; in g84_cipher_init()
|
/Linux-v4.19/drivers/net/wireless/ralink/rt2x00/ |
D | rt2x00crypto.c | 30 enum cipher rt2x00crypto_key_to_cipher(struct ieee80211_key_conf *key) in rt2x00crypto_key_to_cipher() 32 switch (key->cipher) { in rt2x00crypto_key_to_cipher() 58 txdesc->cipher = rt2x00crypto_key_to_cipher(hw_key); in rt2x00crypto_create_tx_descriptor() 95 if (key->cipher == WLAN_CIPHER_SUITE_TKIP) in rt2x00crypto_tx_overhead() 170 switch (rxdesc->cipher) { in rt2x00crypto_rx_insert_iv()
|
/Linux-v4.19/arch/x86/crypto/ |
D | fpu.c | 89 struct crypto_skcipher *cipher; in crypto_fpu_init_tfm() local 92 cipher = crypto_spawn_skcipher(spawn); in crypto_fpu_init_tfm() 93 if (IS_ERR(cipher)) in crypto_fpu_init_tfm() 94 return PTR_ERR(cipher); in crypto_fpu_init_tfm() 96 ctx->child = cipher; in crypto_fpu_init_tfm()
|
/Linux-v4.19/arch/arm64/crypto/ |
D | Kconfig | 51 tristate "SM4 symmetric cipher (ARMv8.2 Crypto Extensions)" 75 tristate "AES core cipher using scalar instructions" 79 tristate "AES core cipher using ARMv8 Crypto Extensions" 109 tristate "NEON accelerated ChaCha20 symmetric cipher" 123 tristate "NEON accelerated Speck cipher algorithms"
|
/Linux-v4.19/drivers/crypto/rockchip/ |
D | rk3288_crypto_ablkcipher.c | 33 static int rk_aes_setkey(struct crypto_ablkcipher *cipher, in rk_aes_setkey() argument 36 struct crypto_tfm *tfm = crypto_ablkcipher_tfm(cipher); in rk_aes_setkey() 41 crypto_ablkcipher_set_flags(cipher, CRYPTO_TFM_RES_BAD_KEY_LEN); in rk_aes_setkey() 49 static int rk_tdes_setkey(struct crypto_ablkcipher *cipher, in rk_tdes_setkey() argument 52 struct crypto_tfm *tfm = crypto_ablkcipher_tfm(cipher); in rk_tdes_setkey() 57 crypto_ablkcipher_set_flags(cipher, CRYPTO_TFM_RES_BAD_KEY_LEN); in rk_tdes_setkey() 199 struct crypto_ablkcipher *cipher = crypto_ablkcipher_reqtfm(req); in rk_ablk_hw_init() local 200 struct crypto_tfm *tfm = crypto_ablkcipher_tfm(cipher); in rk_ablk_hw_init() 201 struct rk_cipher_ctx *ctx = crypto_ablkcipher_ctx(cipher); in rk_ablk_hw_init() 205 ivsize = crypto_ablkcipher_ivsize(cipher); in rk_ablk_hw_init()
|
/Linux-v4.19/drivers/net/wireless/mediatek/mt7601u/ |
D | mac.c | 524 switch (key->cipher) { in mt76_mac_get_key_info() 541 enum mt76_cipher_type cipher; in mt76_mac_wcid_set_key() local 546 cipher = mt76_mac_get_key_info(key, key_data); in mt76_mac_wcid_set_key() 547 if (cipher == MT_CIPHER_NONE && key) in mt76_mac_wcid_set_key() 557 if (cipher >= MT_CIPHER_TKIP) { in mt76_mac_wcid_set_key() 569 val |= FIELD_PREP(MT_WCID_ATTR_PKEY_MODE, cipher & 7) | in mt76_mac_wcid_set_key() 570 FIELD_PREP(MT_WCID_ATTR_PKEY_MODE_EXT, cipher >> 3); in mt76_mac_wcid_set_key() 582 enum mt76_cipher_type cipher; in mt76_mac_shared_key_setup() local 586 cipher = mt76_mac_get_key_info(key, key_data); in mt76_mac_shared_key_setup() 587 if (cipher == MT_CIPHER_NONE && key) in mt76_mac_shared_key_setup() [all …]
|