/net/tipc/ |
D | crypto.c | 206 struct tipc_aead __rcu *aead[KEY_MAX + 1]; member 240 struct tipc_aead *aead; member 247 struct tipc_aead *aead; member 251 static struct tipc_aead *tipc_aead_get(struct tipc_aead __rcu *aead); 252 static inline void tipc_aead_put(struct tipc_aead *aead); 254 static int tipc_aead_users(struct tipc_aead __rcu *aead); 255 static void tipc_aead_users_inc(struct tipc_aead __rcu *aead, int lim); 256 static void tipc_aead_users_dec(struct tipc_aead __rcu *aead, int lim); 257 static void tipc_aead_users_set(struct tipc_aead __rcu *aead, int val); 258 static struct crypto_aead *tipc_aead_tfm_next(struct tipc_aead *aead); [all …]
|
/net/ipv4/ |
D | esp4.c | 46 static void *esp_alloc_tmp(struct crypto_aead *aead, int nfrags, int extralen) in esp_alloc_tmp() argument 52 len += crypto_aead_ivsize(aead); in esp_alloc_tmp() 55 len += crypto_aead_alignmask(aead) & in esp_alloc_tmp() 60 len += sizeof(struct aead_request) + crypto_aead_reqsize(aead); in esp_alloc_tmp() 73 static inline u8 *esp_tmp_iv(struct crypto_aead *aead, void *tmp, int extralen) in esp_tmp_iv() argument 75 return crypto_aead_ivsize(aead) ? in esp_tmp_iv() 77 crypto_aead_alignmask(aead) + 1) : tmp + extralen; in esp_tmp_iv() 80 static inline struct aead_request *esp_tmp_req(struct crypto_aead *aead, u8 *iv) in esp_tmp_req() argument 84 req = (void *)PTR_ALIGN(iv + crypto_aead_ivsize(aead), in esp_tmp_req() 86 aead_request_set_tfm(req, aead); in esp_tmp_req() [all …]
|
D | esp4_offload.c | 194 struct crypto_aead *aead; in esp4_gso_segment() local 207 aead = x->data; in esp4_gso_segment() 213 if (!pskb_may_pull(skb, sizeof(*esph) + crypto_aead_ivsize(aead))) in esp4_gso_segment() 216 __skb_pull(skb, sizeof(*esph) + crypto_aead_ivsize(aead)); in esp4_gso_segment() 236 struct crypto_aead *aead = x->data; in esp_input_tail() local 239 if (!pskb_may_pull(skb, sizeof(struct ip_esp_hdr) + crypto_aead_ivsize(aead))) in esp_input_tail() 255 struct crypto_aead *aead; in esp_xmit() local 278 aead = x->data; in esp_xmit() 279 alen = crypto_aead_authsize(aead); in esp_xmit() 284 blksize = ALIGN(crypto_aead_blocksize(aead), 4); in esp_xmit()
|
/net/ipv6/ |
D | esp6.c | 63 static void *esp_alloc_tmp(struct crypto_aead *aead, int nfrags, int seqihlen) in esp_alloc_tmp() argument 69 len += crypto_aead_ivsize(aead); in esp_alloc_tmp() 72 len += crypto_aead_alignmask(aead) & in esp_alloc_tmp() 77 len += sizeof(struct aead_request) + crypto_aead_reqsize(aead); in esp_alloc_tmp() 90 static inline u8 *esp_tmp_iv(struct crypto_aead *aead, void *tmp, int seqhilen) in esp_tmp_iv() argument 92 return crypto_aead_ivsize(aead) ? in esp_tmp_iv() 94 crypto_aead_alignmask(aead) + 1) : tmp + seqhilen; in esp_tmp_iv() 97 static inline struct aead_request *esp_tmp_req(struct crypto_aead *aead, u8 *iv) in esp_tmp_req() argument 101 req = (void *)PTR_ALIGN(iv + crypto_aead_ivsize(aead), in esp_tmp_req() 103 aead_request_set_tfm(req, aead); in esp_tmp_req() [all …]
|
D | esp6_offload.c | 233 struct crypto_aead *aead; in esp6_gso_segment() local 246 aead = x->data; in esp6_gso_segment() 252 if (!pskb_may_pull(skb, sizeof(*esph) + crypto_aead_ivsize(aead))) in esp6_gso_segment() 255 __skb_pull(skb, sizeof(*esph) + crypto_aead_ivsize(aead)); in esp6_gso_segment() 273 struct crypto_aead *aead = x->data; in esp6_input_tail() local 276 if (!pskb_may_pull(skb, sizeof(struct ip_esp_hdr) + crypto_aead_ivsize(aead))) in esp6_input_tail() 292 struct crypto_aead *aead; in esp6_xmit() local 313 aead = x->data; in esp6_xmit() 314 alen = crypto_aead_authsize(aead); in esp6_xmit() 319 blksize = ALIGN(crypto_aead_blocksize(aead), 4); in esp6_xmit()
|
/net/xfrm/ |
D | xfrm_algo.c | 31 .aead = { 50 .aead = { 69 .aead = { 88 .aead = { 107 .aead = { 126 .aead = { 145 .aead = { 164 .aead = { 734 const struct xfrm_aead_name *aead = data; in xfrm_aead_name_match() local 735 const char *name = aead->name; in xfrm_aead_name_match() [all …]
|
D | xfrm_user.c | 424 x->aead = p; in attach_aead() 425 x->geniv = algo->uinfo.aead.geniv; in attach_aead() 899 static int copy_to_user_aead(struct xfrm_algo_aead *aead, struct sk_buff *skb) in copy_to_user_aead() argument 901 struct nlattr *nla = nla_reserve(skb, XFRMA_ALG_AEAD, aead_len(aead)); in copy_to_user_aead() 909 strscpy_pad(ap->alg_name, aead->alg_name, sizeof(ap->alg_name)); in copy_to_user_aead() 910 ap->alg_key_len = aead->alg_key_len; in copy_to_user_aead() 911 ap->alg_icv_len = aead->alg_icv_len; in copy_to_user_aead() 913 if (redact_secret && aead->alg_key_len) in copy_to_user_aead() 914 memset(ap->alg_key, 0, (aead->alg_key_len + 7) / 8); in copy_to_user_aead() 916 memcpy(ap->alg_key, aead->alg_key, in copy_to_user_aead() [all …]
|
D | xfrm_state.c | 504 kfree(x->aead); in ___xfrm_state_destroy() 1530 if (orig->aead) { in xfrm_state_clone() 1531 x->aead = xfrm_algo_aead_clone(orig->aead); in xfrm_state_clone() 1533 if (!x->aead) in xfrm_state_clone() 2588 struct crypto_aead *aead; in xfrm_state_mtu() local 2595 aead = x->data; in xfrm_state_mtu() 2596 blksize = ALIGN(crypto_aead_blocksize(aead), 4); in xfrm_state_mtu() 2613 return ((mtu - x->props.header_len - crypto_aead_authsize(aead) - in xfrm_state_mtu()
|
/net/tls/ |
D | tls_device_fallback.c | 49 struct crypto_aead *aead, char *aad, in tls_enc_record() argument 121 struct crypto_aead *aead) in tls_init_aead_request() argument 123 aead_request_set_tfm(aead_req, aead); in tls_init_aead_request() 127 static struct aead_request *tls_alloc_aead_request(struct crypto_aead *aead, in tls_alloc_aead_request() argument 131 crypto_aead_reqsize(aead); in tls_alloc_aead_request() 136 tls_init_aead_request(aead_req, aead); in tls_alloc_aead_request() 141 struct crypto_aead *aead, struct scatterlist *sg_in, in tls_enc_records() argument 152 rc = tls_enc_record(aead_req, aead, aad, iv, in tls_enc_records()
|
D | tls_sw.c | 2316 struct crypto_aead **aead; in tls_set_sw_offload() local 2360 aead = &sw_ctx_tx->aead_send; in tls_set_sw_offload() 2370 aead = &sw_ctx_rx->aead_recv; in tls_set_sw_offload() 2484 if (!*aead) { in tls_set_sw_offload() 2485 *aead = crypto_alloc_aead(cipher_name, 0, 0); in tls_set_sw_offload() 2486 if (IS_ERR(*aead)) { in tls_set_sw_offload() 2487 rc = PTR_ERR(*aead); in tls_set_sw_offload() 2488 *aead = NULL; in tls_set_sw_offload() 2495 rc = crypto_aead_setkey(*aead, key, keysize); in tls_set_sw_offload() 2500 rc = crypto_aead_setauthsize(*aead, prot->tag_size); in tls_set_sw_offload() [all …]
|