Home
last modified time | relevance | path

Searched refs:enc (Results 1 – 14 of 14) sorted by relevance

/crypto/
Dauthenc.c24 struct crypto_skcipher_spawn enc; member
30 struct crypto_skcipher *enc; member
89 struct crypto_skcipher *enc = ctx->enc; in crypto_authenc_setkey() local
103 crypto_skcipher_clear_flags(enc, CRYPTO_TFM_REQ_MASK); in crypto_authenc_setkey()
104 crypto_skcipher_set_flags(enc, crypto_aead_get_flags(authenc) & in crypto_authenc_setkey()
106 err = crypto_skcipher_setkey(enc, keys.enckey, keys.enckeylen); in crypto_authenc_setkey()
199 struct crypto_skcipher *enc = ctx->enc; in crypto_authenc_encrypt() local
217 skcipher_request_set_tfm(skreq, enc); in crypto_authenc_encrypt()
255 skcipher_request_set_tfm(skreq, ctx->enc); in crypto_authenc_decrypt_tail()
313 struct crypto_skcipher *enc; in crypto_authenc_init_tfm() local
[all …]
Dauthencesn.c27 struct crypto_skcipher_spawn enc; member
33 struct crypto_skcipher *enc; member
63 struct crypto_skcipher *enc = ctx->enc; in crypto_authenc_esn_setkey() local
77 crypto_skcipher_clear_flags(enc, CRYPTO_TFM_REQ_MASK); in crypto_authenc_esn_setkey()
78 crypto_skcipher_set_flags(enc, crypto_aead_get_flags(authenc_esn) & in crypto_authenc_esn_setkey()
80 err = crypto_skcipher_setkey(enc, keys.enckey, keys.enckeylen); in crypto_authenc_esn_setkey()
188 struct crypto_skcipher *enc = ctx->enc; in crypto_authenc_esn_encrypt() local
207 skcipher_request_set_tfm(skreq, enc); in crypto_authenc_esn_encrypt()
253 skcipher_request_set_tfm(skreq, ctx->enc); in crypto_authenc_esn_decrypt_tail()
328 struct crypto_skcipher *enc; in crypto_authenc_esn_init_tfm() local
[all …]
Dtcrypt.c157 static int do_mult_aead_op(struct test_mb_aead_data *data, int enc, in do_mult_aead_op() argument
164 if (enc == ENCRYPT) in do_mult_aead_op()
183 static int test_mb_aead_jiffies(struct test_mb_aead_data *data, int enc, in test_mb_aead_jiffies() argument
197 ret = do_mult_aead_op(data, enc, num_mb, rc); in test_mb_aead_jiffies()
210 static int test_mb_aead_cycles(struct test_mb_aead_data *data, int enc, in test_mb_aead_cycles() argument
224 ret = do_mult_aead_op(data, enc, num_mb, rc); in test_mb_aead_cycles()
234 ret = do_mult_aead_op(data, enc, num_mb, rc); in test_mb_aead_cycles()
251 static void test_mb_aead_speed(const char *algo, int enc, int secs, in test_mb_aead_speed() argument
276 if (enc == ENCRYPT) in test_mb_aead_speed()
390 bs + (enc ? 0 : authsize), in test_mb_aead_speed()
[all …]
Dxts.c83 bool enc) in xts_xor_tweak() argument
111 if (!enc) { in xts_xor_tweak()
117 if (enc && second_pass) in xts_xor_tweak()
133 static int xts_xor_tweak_pre(struct skcipher_request *req, bool enc) in xts_xor_tweak_pre() argument
135 return xts_xor_tweak(req, false, enc); in xts_xor_tweak_pre()
138 static int xts_xor_tweak_post(struct skcipher_request *req, bool enc) in xts_xor_tweak_post() argument
140 return xts_xor_tweak(req, true, enc); in xts_xor_tweak_post()
Dcipher.c60 u8 *dst, const u8 *src, bool enc) in cipher_crypt_one() argument
65 enc ? cia->cia_encrypt : cia->cia_decrypt; in cipher_crypt_one()
Dadiantum.c93 bool enc; /* true if encrypting, false if decrypting */ member
292 if (!rctx->enc) in adiantum_finish()
322 static int adiantum_crypt(struct skcipher_request *req, bool enc) in adiantum_crypt() argument
335 rctx->enc = enc; in adiantum_crypt()
352 if (enc) in adiantum_crypt()
Dalgif_aead.c58 return ctx->used >= ctx->aead_assoclen + (ctx->enc ? 0 : as); in aead_sufficient_data()
141 if (ctx->enc) in _aead_recvmsg()
215 if (ctx->enc) { in _aead_recvmsg()
296 err = ctx->enc ? crypto_aead_encrypt(&areq->cra_u.aead_req) : in _aead_recvmsg()
310 err = crypto_wait_req(ctx->enc ? in _aead_recvmsg()
Dtestmgr.c1920 static int test_aead_vec_cfg(int enc, const struct aead_testvec *vec, in test_aead_vec_cfg() argument
1932 const char *op = enc ? "encryption" : "decryption"; in test_aead_vec_cfg()
1988 input[1].iov_base = enc ? (void *)vec->ptext : (void *)vec->ctext; in test_aead_vec_cfg()
1989 input[1].iov_len = enc ? vec->plen : vec->clen; in test_aead_vec_cfg()
1991 vec->alen + (enc ? vec->plen : in test_aead_vec_cfg()
1993 vec->alen + (enc ? vec->clen : in test_aead_vec_cfg()
2006 enc ? vec->plen : vec->clen, iv); in test_aead_vec_cfg()
2010 err = enc ? crypto_aead_encrypt(req) : crypto_aead_decrypt(req); in test_aead_vec_cfg()
2016 if (req->cryptlen != (enc ? vec->plen : vec->clen) || in test_aead_vec_cfg()
2027 if (req->cryptlen != (enc ? vec->plen : vec->clen)) in test_aead_vec_cfg()
[all …]
Dessiv.c141 static int essiv_skcipher_crypt(struct skcipher_request *req, bool enc) in essiv_skcipher_crypt() argument
155 return enc ? crypto_skcipher_encrypt(subreq) : in essiv_skcipher_crypt()
183 static int essiv_aead_crypt(struct aead_request *req, bool enc) in essiv_aead_crypt() argument
200 if (req->src == req->dst || !enc) { in essiv_aead_crypt()
252 err = enc ? crypto_aead_encrypt(subreq) : in essiv_aead_crypt()
Dgcm.c82 static int crypto_rfc4543_copy_src_to_dst(struct aead_request *req, bool enc);
928 static int crypto_rfc4543_crypt(struct aead_request *req, bool enc) in crypto_rfc4543_crypt() argument
940 err = crypto_rfc4543_copy_src_to_dst(req, enc); in crypto_rfc4543_crypt()
952 enc ? 0 : authsize, iv); in crypto_rfc4543_crypt()
956 return enc ? crypto_aead_encrypt(subreq) : crypto_aead_decrypt(subreq); in crypto_rfc4543_crypt()
959 static int crypto_rfc4543_copy_src_to_dst(struct aead_request *req, bool enc) in crypto_rfc4543_copy_src_to_dst() argument
965 (enc ? 0 : authsize); in crypto_rfc4543_copy_src_to_dst()
Daf_alg.c839 bool enc = false; in af_alg_sendmsg() local
851 enc = true; in af_alg_sendmsg()
854 enc = false; in af_alg_sendmsg()
878 ctx->enc = enc; in af_alg_sendmsg()
Dalgif_skcipher.c121 err = ctx->enc ? in _skcipher_recvmsg()
136 err = crypto_wait_req(ctx->enc ? in _skcipher_recvmsg()
Dhctr2.c266 static int hctr2_crypt(struct skcipher_request *req, bool enc) in hctr2_crypt() argument
301 if (enc) in hctr2_crypt()
/crypto/asymmetric_keys/
Dsignature.c81 const void *data, void *enc) in encrypt_blob() argument
84 return asymmetric_key_eds_op(params, data, enc); in encrypt_blob()
102 const void *enc, void *data) in decrypt_blob() argument
105 return asymmetric_key_eds_op(params, enc, data); in decrypt_blob()
123 const void *data, void *enc) in create_signature() argument
126 return asymmetric_key_eds_op(params, data, enc); in create_signature()