Home
last modified time | relevance | path

Searched refs:cipher (Results 1 – 25 of 281) sorted by relevance

12345678910>>...12

/linux-6.6.21/Documentation/crypto/
Darchitecture.rst8 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 …]
Dintro.rst19 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
Duserspace-if.rst13 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 …]
/linux-6.6.21/drivers/crypto/amcc/
Dcrypto4xx_alg.c73 struct crypto_skcipher *cipher = crypto_skcipher_reqtfm(req); in crypto4xx_crypt() local
74 struct crypto4xx_ctx *ctx = crypto_skcipher_ctx(cipher); in crypto4xx_crypt()
121 static int crypto4xx_setkey_aes(struct crypto_skcipher *cipher, in crypto4xx_setkey_aes() argument
127 struct crypto4xx_ctx *ctx = crypto_skcipher_ctx(cipher); in crypto4xx_setkey_aes()
177 int crypto4xx_setkey_aes_cbc(struct crypto_skcipher *cipher, in crypto4xx_setkey_aes_cbc() argument
180 return crypto4xx_setkey_aes(cipher, key, keylen, CRYPTO_MODE_CBC, in crypto4xx_setkey_aes_cbc()
184 int crypto4xx_setkey_aes_cfb(struct crypto_skcipher *cipher, in crypto4xx_setkey_aes_cfb() argument
187 return crypto4xx_setkey_aes(cipher, key, keylen, CRYPTO_MODE_CFB, in crypto4xx_setkey_aes_cfb()
191 int crypto4xx_setkey_aes_ecb(struct crypto_skcipher *cipher, in crypto4xx_setkey_aes_ecb() argument
194 return crypto4xx_setkey_aes(cipher, key, keylen, CRYPTO_MODE_ECB, in crypto4xx_setkey_aes_ecb()
[all …]
Dcrypto4xx_core.h125 struct crypto_sync_skcipher *cipher; member
137 struct skcipher_alg cipher; member
163 int crypto4xx_setkey_aes_cbc(struct crypto_skcipher *cipher,
165 int crypto4xx_setkey_aes_cfb(struct crypto_skcipher *cipher,
167 int crypto4xx_setkey_aes_ctr(struct crypto_skcipher *cipher,
169 int crypto4xx_setkey_aes_ecb(struct crypto_skcipher *cipher,
171 int crypto4xx_setkey_aes_ofb(struct crypto_skcipher *cipher,
173 int crypto4xx_setkey_rfc3686(struct crypto_skcipher *cipher,
236 int crypto4xx_setkey_aes_ccm(struct crypto_aead *cipher,
240 int crypto4xx_setkey_aes_gcm(struct crypto_aead *cipher,
/linux-6.6.21/crypto/
Dcbc.c25 struct crypto_cipher *cipher; in crypto_cbc_encrypt_segment() local
29 cipher = skcipher_cipher_simple(skcipher); in crypto_cbc_encrypt_segment()
30 tfm = crypto_cipher_tfm(cipher); in crypto_cbc_encrypt_segment()
31 fn = crypto_cipher_alg(cipher)->cia_encrypt; in crypto_cbc_encrypt_segment()
52 struct crypto_cipher *cipher; in crypto_cbc_encrypt_inplace() local
56 cipher = skcipher_cipher_simple(skcipher); in crypto_cbc_encrypt_inplace()
57 tfm = crypto_cipher_tfm(cipher); in crypto_cbc_encrypt_inplace()
58 fn = crypto_cipher_alg(cipher)->cia_encrypt; in crypto_cbc_encrypt_inplace()
100 struct crypto_cipher *cipher; in crypto_cbc_decrypt_segment() local
104 cipher = skcipher_cipher_simple(skcipher); in crypto_cbc_decrypt_segment()
[all …]
Decb.c17 struct crypto_cipher *cipher, in crypto_ecb_crypt() argument
20 const unsigned int bsize = crypto_cipher_blocksize(cipher); in crypto_ecb_crypt()
32 fn(crypto_cipher_tfm(cipher), dst, src); in crypto_ecb_crypt()
47 struct crypto_cipher *cipher = skcipher_cipher_simple(tfm); in crypto_ecb_encrypt() local
49 return crypto_ecb_crypt(req, cipher, in crypto_ecb_encrypt()
50 crypto_cipher_alg(cipher)->cia_encrypt); in crypto_ecb_encrypt()
56 struct crypto_cipher *cipher = skcipher_cipher_simple(tfm); in crypto_ecb_decrypt() local
58 return crypto_ecb_crypt(req, cipher, in crypto_ecb_decrypt()
59 crypto_cipher_alg(cipher)->cia_decrypt); in crypto_ecb_decrypt()
Dctr.c102 struct crypto_cipher *cipher = skcipher_cipher_simple(tfm); in crypto_ctr_crypt() local
103 const unsigned int bsize = crypto_cipher_blocksize(cipher); in crypto_ctr_crypt()
112 nbytes = crypto_ctr_crypt_inplace(&walk, cipher); in crypto_ctr_crypt()
114 nbytes = crypto_ctr_crypt_segment(&walk, cipher); in crypto_ctr_crypt()
120 crypto_ctr_crypt_final(&walk, cipher); in crypto_ctr_crypt()
223 struct crypto_skcipher *cipher; in crypto_rfc3686_init_tfm() local
227 cipher = crypto_spawn_skcipher(spawn); in crypto_rfc3686_init_tfm()
228 if (IS_ERR(cipher)) in crypto_rfc3686_init_tfm()
229 return PTR_ERR(cipher); in crypto_rfc3686_init_tfm()
231 ctx->child = cipher; in crypto_rfc3686_init_tfm()
[all …]
Dcmac.c206 struct crypto_cipher *cipher; in cmac_init_tfm() local
209 cipher = crypto_spawn_cipher(spawn); in cmac_init_tfm()
210 if (IS_ERR(cipher)) in cmac_init_tfm()
211 return PTR_ERR(cipher); in cmac_init_tfm()
213 ctx->child = cipher; in cmac_init_tfm()
222 struct crypto_cipher *cipher; in cmac_clone_tfm() local
224 cipher = crypto_clone_cipher(octx->child); in cmac_clone_tfm()
225 if (IS_ERR(cipher)) in cmac_clone_tfm()
226 return PTR_ERR(cipher); in cmac_clone_tfm()
228 ctx->child = cipher; in cmac_clone_tfm()
/linux-6.6.21/drivers/crypto/cavium/nitrox/
Dnitrox_skcipher.c41 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()
197 static int nitrox_aes_setkey(struct crypto_skcipher *cipher, const u8 *key, in nitrox_aes_setkey() argument
[all …]
/linux-6.6.21/arch/arm64/crypto/
DKconfig135 Block ciphers: AES cipher algorithms (FIPS-197)
138 AEAD cipher: AES with CBC, ESSIV, and SHA-256
149 Block ciphers: AES cipher algorithms (FIPS-197)
160 Length-preserving ciphers: AES cipher algorithms (FIPS-197)
161 with block cipher modes:
177 Length-preserving ciphers: AES cipher algorithms (FIPS-197)
178 with block cipher modes:
196 stream cipher algorithms
208 Length-preserving ciphers: AES cipher algorithms (FIPS-197)
209 with block cipher modes:
[all …]
DMakefile26 obj-$(CONFIG_CRYPTO_SM4_ARM64_CE) += sm4-ce-cipher.o
27 sm4-ce-cipher-y := sm4-ce-cipher-glue.o sm4-ce-cipher-core.o
50 obj-$(CONFIG_CRYPTO_AES_ARM64_CE) += aes-ce-cipher.o
51 aes-ce-cipher-y := aes-ce-core.o aes-ce-glue.o
79 aes-arm64-y := aes-cipher-core.o aes-cipher-glue.o
/linux-6.6.21/arch/x86/crypto/
DKconfig25 Block cipher: AES cipher algorithms
26 AEAD cipher: AES with GCM
39 Block cipher: Blowfish cipher algorithm
50 Block cipher: Camellia cipher algorithms
89 Length-preserving ciphers: CAST5 (CAST-128) cipher algorithm
107 Length-preserving ciphers: CAST6 (CAST-256) cipher algorithm
122 Block cipher: Triple DES EDE (FIPS 46-3) cipher algorithm
137 Length-preserving ciphers: Serpent cipher algorithm
153 Length-preserving ciphers: Serpent cipher algorithm
170 Length-preserving ciphers: Serpent cipher algorithm
[all …]
/linux-6.6.21/drivers/crypto/cavium/cpt/
Dcptvf_algs.c232 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_cfb_aes_setkey(struct crypto_skcipher *cipher, const u8 *key, in cvm_cfb_aes_setkey() argument
[all …]
/linux-6.6.21/net/sunrpc/auth_gss/
Dgss_krb5_crypto.c592 gss_krb5_cts_crypt(struct crypto_sync_skcipher *cipher, struct xdr_buf *buf, in gss_krb5_cts_crypt() argument
597 SYNC_SKCIPHER_REQUEST_ON_STACK(req, cipher); in gss_krb5_cts_crypt()
626 skcipher_request_set_sync_tfm(req, cipher); in gss_krb5_cts_crypt()
649 memcpy(iv, data, crypto_sync_skcipher_ivsize(cipher)); in gss_krb5_cts_crypt()
787 struct crypto_sync_skcipher *cipher, *aux_cipher; in gss_krb5_aes_encrypt() local
793 cipher = kctx->initiator_enc; in gss_krb5_aes_encrypt()
797 cipher = kctx->acceptor_enc; in gss_krb5_aes_encrypt()
801 conflen = crypto_sync_skcipher_blocksize(cipher); in gss_krb5_aes_encrypt()
843 err = krb5_cbc_cts_encrypt(cipher, aux_cipher, in gss_krb5_aes_encrypt()
860 struct crypto_sync_skcipher *cipher, *aux_cipher; in gss_krb5_aes_decrypt() local
[all …]
/linux-6.6.21/drivers/gpu/drm/nouveau/nvkm/engine/cipher/
Dg84.c80 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-6.6.21/drivers/crypto/bcm/
Dcipher.c154 if ((ctx->cipher.mode == CIPHER_MODE_XTS) && in spu_skcipher_rx_sg_create()
219 if ((ctx->cipher.mode == CIPHER_MODE_XTS) && in spu_skcipher_tx_sg_create()
324 cipher_parms.alg = ctx->cipher.alg; in handle_skcipher_req()
325 cipher_parms.mode = ctx->cipher.mode; in handle_skcipher_req()
350 if ((ctx->cipher.mode == CIPHER_MODE_CBC) && in handle_skcipher_req()
366 if ((ctx->cipher.mode == CIPHER_MODE_CBC) && in handle_skcipher_req()
375 } else if (ctx->cipher.mode == CIPHER_MODE_CTR) { in handle_skcipher_req()
435 if ((ctx->cipher.mode == CIPHER_MODE_XTS) && in handle_skcipher_req()
449 if ((ctx->cipher.mode == CIPHER_MODE_XTS) && in handle_skcipher_req()
485 if ((ctx->cipher.mode == CIPHER_MODE_XTS) && in handle_skcipher_resp()
[all …]
/linux-6.6.21/arch/sparc/crypto/
DKconfig12 Block cipher: DES (FIPS 46-2) cipher algorithm
13 Block cipher: Triple DES EDE (FIPS 46-3) cipher algorithm
74 Block ciphers: AES cipher algorithms (FIPS-197)
85 Block ciphers: Camellia cipher algorithms
/linux-6.6.21/tools/testing/crypto/chacha20-s390/
Dtest-cipher.c51 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()
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()
197 sg_init_one(&sk.sginp, cipher, data_size); in test_skcipher()
/linux-6.6.21/net/wireless/
Dwext-compat.c451 if (params->cipher == WLAN_CIPHER_SUITE_AES_CMAC) { in __cfg80211_set_encryption()
497 wdev->wext.keys->params[idx].cipher = 0; in __cfg80211_set_encryption()
522 else if (params->cipher != WLAN_CIPHER_SUITE_WEP40 && in __cfg80211_set_encryption()
523 params->cipher != WLAN_CIPHER_SUITE_WEP104) in __cfg80211_set_encryption()
533 if (!addr && (params->cipher == WLAN_CIPHER_SUITE_WEP40 || in __cfg80211_set_encryption()
534 params->cipher == WLAN_CIPHER_SUITE_WEP104)) { in __cfg80211_set_encryption()
542 if ((params->cipher == WLAN_CIPHER_SUITE_WEP40 || in __cfg80211_set_encryption()
543 params->cipher == WLAN_CIPHER_SUITE_WEP104) && in __cfg80211_set_encryption()
569 if (params->cipher == WLAN_CIPHER_SUITE_AES_CMAC && in __cfg80211_set_encryption()
658 params.cipher = WLAN_CIPHER_SUITE_WEP40; in cfg80211_wext_siwencode()
[all …]
/linux-6.6.21/drivers/net/wireless/intel/iwlwifi/mvm/
Dmld-key.c72 switch (keyconf->cipher) { in iwl_mvm_get_sec_flags()
191 if (keyconf->cipher == WLAN_CIPHER_SUITE_WEP40 || in iwl_mvm_mld_send_key()
192 keyconf->cipher == WLAN_CIPHER_SUITE_WEP104) in iwl_mvm_mld_send_key()
201 if (keyconf->cipher == WLAN_CIPHER_SUITE_WEP40 || in iwl_mvm_mld_send_key()
202 keyconf->cipher == WLAN_CIPHER_SUITE_WEP104) in iwl_mvm_mld_send_key()
208 if (keyconf->cipher == WLAN_CIPHER_SUITE_TKIP) { in iwl_mvm_mld_send_key()
225 if (keyconf->cipher == WLAN_CIPHER_SUITE_WEP40 || in iwl_mvm_mld_send_key()
226 keyconf->cipher == WLAN_CIPHER_SUITE_WEP104) { in iwl_mvm_mld_send_key()
328 if (keyconf->cipher == WLAN_CIPHER_SUITE_WEP40 || in _iwl_mvm_sec_key_del()
329 keyconf->cipher == WLAN_CIPHER_SUITE_WEP104) { in _iwl_mvm_sec_key_del()
Dftm-responder.c19 u8 cipher; member
257 if (hltk_data->cipher > IWL_LOCATION_CIPHER_GCMP_256) { in iwl_mvm_ftm_responder_dyn_cfg_v3()
259 hltk_data->cipher); in iwl_mvm_ftm_responder_dyn_cfg_v3()
263 cmd.cipher = hltk_data->cipher; in iwl_mvm_ftm_responder_dyn_cfg_v3()
317 u8 *addr, u32 cipher, u8 *tk, u32 tk_len, in iwl_mvm_ftm_respoder_add_pasn_sta() argument
345 hltk_data.cipher = iwl_mvm_cipher_to_location_cipher(cipher); in iwl_mvm_ftm_respoder_add_pasn_sta()
346 if (hltk_data.cipher == IWL_LOCATION_CIPHER_INVALID) { in iwl_mvm_ftm_respoder_add_pasn_sta()
347 IWL_ERR(mvm, "invalid cipher: %u\n", cipher); in iwl_mvm_ftm_respoder_add_pasn_sta()
360 cipher, tk, tk_len); in iwl_mvm_ftm_respoder_add_pasn_sta()
/linux-6.6.21/arch/s390/crypto/
DKconfig89 Block cipher: AES cipher algorithms (FIPS 197)
90 AEAD cipher: AES with GCM
112 Block ciphers: DES (FIPS 46-2) cipher algorithm
113 Block ciphers: Triple DES EDE (FIPS 46-3) cipher algorithm
129 Length-preserving cipher: ChaCha20 stream cipher (RFC 7539)
/linux-6.6.21/drivers/crypto/intel/keembay/
Docs-aes.h68 const u8 *key, const enum ocs_cipher cipher);
72 enum ocs_cipher cipher,
97 enum ocs_cipher cipher,
109 enum ocs_cipher cipher,
Docs-aes.c478 enum ocs_cipher cipher) in ocs_aes_set_key() argument
485 if (cipher == OCS_AES && !(key_size == 32 || key_size == 16)) { in ocs_aes_set_key()
492 if (cipher == OCS_SM4 && key_size != 16) { in ocs_aes_set_key()
525 enum ocs_cipher cipher, in set_ocs_aes_command() argument
554 val = (cipher << 14) | (mode << 8) | (instruction << 6) | in set_ocs_aes_command()
561 enum ocs_cipher cipher, in ocs_aes_init() argument
571 set_ocs_aes_command(aes_dev, cipher, mode, instruction); in ocs_aes_init()
604 enum ocs_cipher cipher, enum ocs_mode mode, in ocs_aes_validate_inputs() argument
609 if (!(cipher == OCS_AES || cipher == OCS_SM4)) in ocs_aes_validate_inputs()
798 enum ocs_cipher cipher, in ocs_aes_op() argument
[all …]

12345678910>>...12