Home
last modified time | relevance | path

Searched refs:tb (Results 1 – 25 of 33) sorted by relevance

12

/crypto/asymmetric_keys/
Dasym_tpm.c30 static int tpm_loadkey2(struct tpm_buf *tb, in tpm_loadkey2() argument
46 ret = oiap(tb, &authhandle, enonce); in tpm_loadkey2()
67 tpm_buf_reset(tb, TPM_TAG_RQU_AUTH1_COMMAND, TPM_ORD_LOADKEY2); in tpm_loadkey2()
68 tpm_buf_append_u32(tb, keyhandle); in tpm_loadkey2()
69 tpm_buf_append(tb, keyblob, keybloblen); in tpm_loadkey2()
70 tpm_buf_append_u32(tb, authhandle); in tpm_loadkey2()
71 tpm_buf_append(tb, nonceodd, TPM_NONCE_SIZE); in tpm_loadkey2()
72 tpm_buf_append_u8(tb, cont); in tpm_loadkey2()
73 tpm_buf_append(tb, authdata, SHA1_DIGEST_SIZE); in tpm_loadkey2()
75 ret = trusted_tpm_send(tb->data, MAX_BUF_SIZE); in tpm_loadkey2()
[all …]
/crypto/
Dalgboss.c24 struct rtattr *tb[CRYPTO_MAX_ATTRS + 2]; member
61 err = tmpl->create(tmpl, param->tb); in cryptomgr_probe()
128 param->tb[i + 1] = &param->attrs[i].attr; in cryptomgr_schedule_probe()
144 param->tb[i + 1] = NULL; in cryptomgr_schedule_probe()
150 param->tb[0] = &param->type.attr; in cryptomgr_schedule_probe()
Dhctr2.c406 struct rtattr **tb, in hctr2_create_common() argument
420 err = crypto_check_attr_type(tb, CRYPTO_ALG_TYPE_SKCIPHER, &mask); in hctr2_create_common()
518 static int hctr2_create_base(struct crypto_template *tmpl, struct rtattr **tb) in hctr2_create_base() argument
523 xctr_name = crypto_attr_alg_name(tb[1]); in hctr2_create_base()
527 polyval_name = crypto_attr_alg_name(tb[2]); in hctr2_create_base()
531 return hctr2_create_common(tmpl, tb, xctr_name, polyval_name); in hctr2_create_base()
534 static int hctr2_create(struct crypto_template *tmpl, struct rtattr **tb) in hctr2_create() argument
539 blockcipher_name = crypto_attr_alg_name(tb[1]); in hctr2_create()
547 return hctr2_create_common(tmpl, tb, xctr_name, "polyval"); in hctr2_create()
Dccm.c447 struct rtattr **tb, in crypto_ccm_create_common() argument
458 err = crypto_check_attr_type(tb, CRYPTO_ALG_TYPE_AEAD, &mask); in crypto_ccm_create_common()
531 static int crypto_ccm_create(struct crypto_template *tmpl, struct rtattr **tb) in crypto_ccm_create() argument
537 cipher_name = crypto_attr_alg_name(tb[1]); in crypto_ccm_create()
549 return crypto_ccm_create_common(tmpl, tb, ctr_name, mac_name); in crypto_ccm_create()
553 struct rtattr **tb) in crypto_ccm_base_create() argument
558 ctr_name = crypto_attr_alg_name(tb[1]); in crypto_ccm_base_create()
562 mac_name = crypto_attr_alg_name(tb[2]); in crypto_ccm_base_create()
566 return crypto_ccm_create_common(tmpl, tb, ctr_name, mac_name); in crypto_ccm_base_create()
707 struct rtattr **tb) in crypto_rfc4309_create() argument
[all …]
Dgcm.c577 struct rtattr **tb, in crypto_gcm_create_common() argument
588 err = crypto_check_attr_type(tb, CRYPTO_ALG_TYPE_AEAD, &mask); in crypto_gcm_create_common()
658 static int crypto_gcm_create(struct crypto_template *tmpl, struct rtattr **tb) in crypto_gcm_create() argument
663 cipher_name = crypto_attr_alg_name(tb[1]); in crypto_gcm_create()
671 return crypto_gcm_create_common(tmpl, tb, ctr_name, "ghash"); in crypto_gcm_create()
675 struct rtattr **tb) in crypto_gcm_base_create() argument
680 ctr_name = crypto_attr_alg_name(tb[1]); in crypto_gcm_base_create()
684 ghash_name = crypto_attr_alg_name(tb[2]); in crypto_gcm_base_create()
688 return crypto_gcm_create_common(tmpl, tb, ctr_name, ghash_name); in crypto_gcm_base_create()
828 struct rtattr **tb) in crypto_rfc4106_create() argument
[all …]
Dgeniv.c42 struct rtattr **tb) in aead_geniv_alloc() argument
52 err = crypto_check_attr_type(tb, CRYPTO_ALG_TYPE_AEAD, &mask); in aead_geniv_alloc()
63 crypto_attr_alg_name(tb[1]), 0, mask); in aead_geniv_alloc()
Dpcrypt.c236 static int pcrypt_create_aead(struct crypto_template *tmpl, struct rtattr **tb, in pcrypt_create_aead() argument
261 crypto_attr_alg_name(tb[1]), 0, mask); in pcrypt_create_aead()
295 static int pcrypt_create(struct crypto_template *tmpl, struct rtattr **tb) in pcrypt_create() argument
299 algt = crypto_get_attr_type(tb); in pcrypt_create()
305 return pcrypt_create_aead(tmpl, tb, algt); in pcrypt_create()
Dctr.c127 static int crypto_ctr_create(struct crypto_template *tmpl, struct rtattr **tb) in crypto_ctr_create() argument
133 inst = skcipher_alloc_instance_simple(tmpl, tb); in crypto_ctr_create()
258 struct rtattr **tb) in crypto_rfc3686_create() argument
266 err = crypto_check_attr_type(tb, CRYPTO_ALG_TYPE_SKCIPHER, &mask); in crypto_rfc3686_create()
277 crypto_attr_alg_name(tb[1]), 0, mask); in crypto_rfc3686_create()
Decb.c62 static int crypto_ecb_create(struct crypto_template *tmpl, struct rtattr **tb) in crypto_ecb_create() argument
67 inst = skcipher_alloc_instance_simple(tmpl, tb); in crypto_ecb_create()
Dofb.c53 static int crypto_ofb_create(struct crypto_template *tmpl, struct rtattr **tb) in crypto_ofb_create() argument
59 inst = skcipher_alloc_instance_simple(tmpl, tb); in crypto_ofb_create()
Dchacha20poly1305.c555 static int chachapoly_create(struct crypto_template *tmpl, struct rtattr **tb, in chachapoly_create() argument
568 err = crypto_check_attr_type(tb, CRYPTO_ALG_TYPE_AEAD, &mask); in chachapoly_create()
579 crypto_attr_alg_name(tb[1]), 0, mask); in chachapoly_create()
585 crypto_attr_alg_name(tb[2]), 0, mask); in chachapoly_create()
637 static int rfc7539_create(struct crypto_template *tmpl, struct rtattr **tb) in rfc7539_create() argument
639 return chachapoly_create(tmpl, tb, "rfc7539", 12); in rfc7539_create()
642 static int rfc7539esp_create(struct crypto_template *tmpl, struct rtattr **tb) in rfc7539esp_create() argument
644 return chachapoly_create(tmpl, tb, "rfc7539esp", 8); in rfc7539esp_create()
Dcryptd.c370 struct rtattr **tb, in cryptd_create_skcipher() argument
391 crypto_attr_alg_name(tb[1]), type, mask); in cryptd_create_skcipher()
636 static int cryptd_create_hash(struct crypto_template *tmpl, struct rtattr **tb, in cryptd_create_hash() argument
657 crypto_attr_alg_name(tb[1]), type, mask); in cryptd_create_hash()
823 struct rtattr **tb, in cryptd_create_aead() argument
844 crypto_attr_alg_name(tb[1]), type, mask); in cryptd_create_aead()
879 static int cryptd_create(struct crypto_template *tmpl, struct rtattr **tb) in cryptd_create() argument
883 algt = crypto_get_attr_type(tb); in cryptd_create()
889 return cryptd_create_skcipher(tmpl, tb, algt, &queue); in cryptd_create()
891 return cryptd_create_hash(tmpl, tb, algt, &queue); in cryptd_create()
[all …]
Dhmac.c165 static int hmac_create(struct crypto_template *tmpl, struct rtattr **tb) in hmac_create() argument
176 err = crypto_check_attr_type(tb, CRYPTO_ALG_TYPE_SHASH, &mask); in hmac_create()
186 crypto_attr_alg_name(tb[1]), 0, mask); in hmac_create()
Dxcbc.c189 static int xcbc_create(struct crypto_template *tmpl, struct rtattr **tb) in xcbc_create() argument
198 err = crypto_check_attr_type(tb, CRYPTO_ALG_TYPE_SHASH, &mask); in xcbc_create()
208 crypto_attr_alg_name(tb[1]), 0, mask); in xcbc_create()
Dadiantum.c492 static int adiantum_create(struct crypto_template *tmpl, struct rtattr **tb) in adiantum_create() argument
503 err = crypto_check_attr_type(tb, CRYPTO_ALG_TYPE_SKCIPHER, &mask); in adiantum_create()
515 crypto_attr_alg_name(tb[1]), 0, mask); in adiantum_create()
523 crypto_attr_alg_name(tb[2]), 0, mask); in adiantum_create()
529 nhpoly1305_name = crypto_attr_alg_name(tb[3]); in adiantum_create()
Dcmac.c223 static int cmac_create(struct crypto_template *tmpl, struct rtattr **tb) in cmac_create() argument
232 err = crypto_check_attr_type(tb, CRYPTO_ALG_TYPE_SHASH, &mask); in cmac_create()
242 crypto_attr_alg_name(tb[1]), 0, mask); in cmac_create()
Dkeywrap.c264 static int crypto_kw_create(struct crypto_template *tmpl, struct rtattr **tb) in crypto_kw_create() argument
270 inst = skcipher_alloc_instance_simple(tmpl, tb); in crypto_kw_create()
Dechainiv.c113 struct rtattr **tb) in echainiv_aead_create() argument
118 inst = aead_geniv_alloc(tmpl, tb); in echainiv_aead_create()
Dseqiv.c136 static int seqiv_aead_create(struct crypto_template *tmpl, struct rtattr **tb) in seqiv_aead_create() argument
141 inst = aead_geniv_alloc(tmpl, tb); in seqiv_aead_create()
Dxctr.c131 static int crypto_xctr_create(struct crypto_template *tmpl, struct rtattr **tb) in crypto_xctr_create() argument
137 inst = skcipher_alloc_instance_simple(tmpl, tb); in crypto_xctr_create()
Dlrw.c299 static int lrw_create(struct crypto_template *tmpl, struct rtattr **tb) in lrw_create() argument
309 err = crypto_check_attr_type(tb, CRYPTO_ALG_TYPE_SKCIPHER, &mask); in lrw_create()
313 cipher_name = crypto_attr_alg_name(tb[1]); in lrw_create()
Dpcbc.c154 static int crypto_pcbc_create(struct crypto_template *tmpl, struct rtattr **tb) in crypto_pcbc_create() argument
159 inst = skcipher_alloc_instance_simple(tmpl, tb); in crypto_pcbc_create()
Dauthencesn.c391 struct rtattr **tb) in crypto_authenc_esn_create() argument
401 err = crypto_check_attr_type(tb, CRYPTO_ALG_TYPE_AEAD, &mask); in crypto_authenc_esn_create()
411 crypto_attr_alg_name(tb[1]), 0, mask); in crypto_authenc_esn_create()
418 crypto_attr_alg_name(tb[2]), 0, mask); in crypto_authenc_esn_create()
Dauthenc.c373 struct rtattr **tb) in crypto_authenc_create() argument
383 err = crypto_check_attr_type(tb, CRYPTO_ALG_TYPE_AEAD, &mask); in crypto_authenc_create()
393 crypto_attr_alg_name(tb[1]), 0, mask); in crypto_authenc_create()
400 crypto_attr_alg_name(tb[2]), 0, mask); in crypto_authenc_create()
Dcts.c324 static int crypto_cts_create(struct crypto_template *tmpl, struct rtattr **tb) in crypto_cts_create() argument
332 err = crypto_check_attr_type(tb, CRYPTO_ALG_TYPE_SKCIPHER, &mask); in crypto_cts_create()
343 crypto_attr_alg_name(tb[1]), 0, mask); in crypto_cts_create()

12