/linux/fs/verity/ |
A D | signature.c | 44 const struct fsverity_hash_alg *hash_alg = vi->tree_params.hash_alg; in fsverity_verify_signature() local 57 d = kzalloc(sizeof(*d) + hash_alg->digest_size, GFP_KERNEL); in fsverity_verify_signature() 61 d->digest_algorithm = cpu_to_le16(hash_alg - fsverity_hash_algs); in fsverity_verify_signature() 62 d->digest_size = cpu_to_le16(hash_alg->digest_size); in fsverity_verify_signature() 63 memcpy(d->digest, vi->file_digest, hash_alg->digest_size); in fsverity_verify_signature() 65 err = verify_pkcs7_signature(d, sizeof(*d) + hash_alg->digest_size, in fsverity_verify_signature() 86 hash_alg->name, hash_alg->digest_size, vi->file_digest); in fsverity_verify_signature()
|
A D | measure.c | 28 const struct fsverity_hash_alg *hash_alg; in fsverity_ioctl_measure() local 34 hash_alg = vi->tree_params.hash_alg; in fsverity_ioctl_measure() 44 if (arg.digest_size < hash_alg->digest_size) in fsverity_ioctl_measure() 48 arg.digest_algorithm = hash_alg - fsverity_hash_algs; in fsverity_ioctl_measure() 49 arg.digest_size = hash_alg->digest_size; in fsverity_ioctl_measure() 54 if (copy_to_user(uarg->digest, vi->file_digest, hash_alg->digest_size)) in fsverity_ioctl_measure()
|
A D | open.c | 34 struct fsverity_hash_alg *hash_alg; in fsverity_init_merkle_tree_params() local 42 hash_alg = fsverity_get_hash_alg(inode, hash_algorithm); in fsverity_init_merkle_tree_params() 43 if (IS_ERR(hash_alg)) in fsverity_init_merkle_tree_params() 44 return PTR_ERR(hash_alg); in fsverity_init_merkle_tree_params() 45 params->hash_alg = hash_alg; in fsverity_init_merkle_tree_params() 46 params->digest_size = hash_alg->digest_size; in fsverity_init_merkle_tree_params() 48 params->hashstate = fsverity_prepare_hash_state(hash_alg, salt, in fsverity_init_merkle_tree_params() 73 params->block_size, hash_alg->name); in fsverity_init_merkle_tree_params() 81 hash_alg->name, params->block_size, params->hashes_per_block, in fsverity_init_merkle_tree_params() 174 err = compute_file_digest(vi->tree_params.hash_alg, desc, in fsverity_create_info() [all …]
|
A D | verify.c | 64 vi->tree_params.hash_alg->name, hsize, want_hash, in cmp_hashes() 65 vi->tree_params.hash_alg->name, hsize, real_hash); in cmp_hashes() 136 params->hash_alg->name, in verify_page() 147 params->hash_alg->name, hsize, want_hash); in verify_page() 165 level - 1, params->hash_alg->name, hsize, want_hash); in verify_page() 197 req = fsverity_alloc_hash_request(vi->tree_params.hash_alg, GFP_NOFS); in fsverity_verify_page() 201 fsverity_free_hash_request(vi->tree_params.hash_alg, req); in fsverity_verify_page() 234 req = fsverity_alloc_hash_request(params->hash_alg, GFP_NOFS); in fsverity_verify_bio() 262 fsverity_free_hash_request(params->hash_alg, req); in fsverity_verify_bio()
|
A D | enable.c | 169 req = fsverity_alloc_hash_request(params->hash_alg, GFP_KERNEL); in build_merkle_tree() 194 fsverity_free_hash_request(params->hash_alg, req); in build_merkle_tree() 275 params.hash_alg->name, params.digest_size, desc->root_hash); in enable_verity()
|
A D | fsverity_private.h | 46 struct fsverity_hash_alg *hash_alg; /* the hash algorithm */ member
|
/linux/drivers/crypto/bcm/ |
A D | spu.h | 56 enum hash_alg { enum 128 enum hash_alg alg; 229 u16 spum_hash_pad_len(enum hash_alg hash_alg, enum hash_mode hash_mode, 239 u32 spum_digest_size(u32 alg_digest_size, enum hash_alg alg, 260 enum hash_alg auth_alg,
|
A D | spu.c | 34 u32 hash_alg; in spum_dump_msg_hdr() local 81 hash_alg = (cflags & HASH_ALG) >> HASH_ALG_SHIFT; in spum_dump_msg_hdr() 85 hash_alg, hash_mode, hash_type); in spum_dump_msg_hdr() 106 if (hash_alg && hash_mode) { in spum_dump_msg_hdr() 109 switch (hash_alg) { in spum_dump_msg_hdr() 146 } else if ((hash_alg == HASH_ALG_AES) && in spum_dump_msg_hdr() 170 if (hash_alg && (hash_mode == HASH_MODE_NONE) && in spum_dump_msg_hdr() 174 switch (hash_alg) { in spum_dump_msg_hdr() 424 u16 spum_hash_pad_len(enum hash_alg hash_alg, enum hash_mode hash_mode, in spum_hash_pad_len() argument 441 if ((hash_alg == HASH_ALG_SHA384) || (hash_alg == HASH_ALG_SHA512)) in spum_hash_pad_len() [all …]
|
A D | spu2.h | 180 u16 spu2_hash_pad_len(enum hash_alg hash_alg, enum hash_mode hash_mode, 190 u32 spu2_digest_size(u32 alg_digest_size, enum hash_alg alg, 205 enum hash_alg auth_alg, enum hash_mode auth_mode,
|
A D | cipher.h | 101 enum hash_alg alg; 367 u16 (*spu_hash_pad_len)(enum hash_alg hash_alg, 378 u32 (*spu_digest_size)(u32 digest_size, enum hash_alg alg, 394 u32 hash_pad_len, enum hash_alg auth_alg,
|
A D | spu2.c | 234 spu2_hash_xlate(enum hash_alg hash_alg, enum hash_mode hash_mode, in spu2_hash_xlate() argument 246 switch (hash_alg) { in spu2_hash_xlate() 303 hash_alg, hash_type); in spu2_hash_xlate() 844 u16 spu2_hash_pad_len(enum hash_alg hash_alg, enum hash_mode hash_mode, in spu2_hash_pad_len() argument 922 u32 spu2_digest_size(u32 alg_digest_size, enum hash_alg alg, in spu2_digest_size() 1246 enum hash_alg auth_alg, enum hash_mode auth_mode, in spu2_request_pad()
|
/linux/crypto/ |
A D | essiv.c | 409 struct shash_alg *hash_alg, in essiv_supported_algorithms() argument 421 if (hash_alg->digestsize < alg->cra_cipher.cia_min_keysize || in essiv_supported_algorithms() 422 hash_alg->digestsize > alg->cra_cipher.cia_max_keysize) in essiv_supported_algorithms() 428 if (crypto_shash_alg_needs_key(hash_alg)) in essiv_supported_algorithms() 451 struct shash_alg *hash_alg; in essiv_create() local 534 hash_alg = __crypto_shash_alg(_hash_alg); in essiv_create() 540 block_base->cra_name, hash_alg->base.cra_name); in essiv_create() 546 strlcpy(ictx->shash_driver_name, hash_alg->base.cra_driver_name, in essiv_create() 554 hash_alg->base.cra_name) >= CRYPTO_MAX_ALG_NAME) in essiv_create() 558 hash_alg->base.cra_driver_name) >= CRYPTO_MAX_ALG_NAME) in essiv_create() [all …]
|
A D | adiantum.c | 474 struct shash_alg *hash_alg) in adiantum_supported_algorithms() argument 486 if (strcmp(hash_alg->base.cra_name, "nhpoly1305") != 0) in adiantum_supported_algorithms() 500 struct shash_alg *hash_alg; in adiantum_create() local 537 hash_alg = crypto_spawn_shash_alg(&ictx->hash_spawn); in adiantum_create() 541 hash_alg)) { in adiantum_create() 544 blockcipher_alg->cra_name, hash_alg->base.cra_name); in adiantum_create() 560 hash_alg->base.cra_driver_name) >= CRYPTO_MAX_ALG_NAME) in adiantum_create() 566 hash_alg->base.cra_alignmask; in adiantum_create() 574 2 * hash_alg->base.cra_priority + in adiantum_create()
|
/linux/drivers/char/tpm/ |
A D | tpm2-cmd.c | 144 __be16 hash_alg; member 534 __be16 hash_alg; member 549 u16 hash_alg; in tpm2_get_pcr_allocation() local 591 hash_alg = be16_to_cpu(pcr_selection.hash_alg); in tpm2_get_pcr_allocation() 596 chip->allocated_banks[nr_alloc_banks].alg_id = hash_alg; in tpm2_get_pcr_allocation() 605 sizeof_pcr_selection = sizeof(pcr_selection.hash_alg) + in tpm2_get_pcr_allocation()
|
/linux/security/keys/trusted-keys/ |
A D | trusted_tpm1.c | 26 static const char hash_alg[] = "sha1"; variable 59 pr_info("can't alloc %s\n", hash_alg); in TSS_sha1() 132 pr_info("can't alloc %s\n", hash_alg); in TSS_authhmac() 208 pr_info("can't alloc %s\n", hash_alg); in TSS_checkhmac1() 301 pr_info("can't alloc %s\n", hash_alg); in TSS_checkhmac2() 1000 hashalg = crypto_alloc_shash(hash_alg, 0, 0); in trusted_shash_alloc() 1003 hash_alg); in trusted_shash_alloc()
|
/linux/drivers/crypto/inside-secure/ |
A D | safexcel_cipher.c | 63 u32 hash_alg; member 465 switch (ctx->hash_alg) { in safexcel_aead_setkey() 523 ctx->hash_alg | in safexcel_context_control() 533 ctx->hash_alg | in safexcel_context_control() 541 ctx->hash_alg | in safexcel_context_control() 1727 ctx->hash_alg = CONTEXT_CONTROL_CRYPTO_ALG_SHA1; in safexcel_aead_sha1_cra_init() 1763 ctx->hash_alg = CONTEXT_CONTROL_CRYPTO_ALG_SHA256; in safexcel_aead_sha256_cra_init() 1799 ctx->hash_alg = CONTEXT_CONTROL_CRYPTO_ALG_SHA224; in safexcel_aead_sha224_cra_init() 2624 ctx->hash_alg = CONTEXT_CONTROL_CRYPTO_ALG_GHASH; in safexcel_aead_gcm_cra_init() 3339 ctx->hash_alg = CONTEXT_CONTROL_CRYPTO_ALG_SHA1; in safexcel_aead_sm4cbc_sha1_cra_init() [all …]
|
/linux/fs/nfs/ |
A D | nfs4session.h | 67 u32 hash_alg; member
|
/linux/security/keys/encrypted-keys/ |
A D | encrypted.c | 40 static const char hash_alg[] = "sha256"; variable 981 hash_tfm = crypto_alloc_shash(hash_alg, 0, 0); in init_encrypted() 984 hash_alg, PTR_ERR(hash_tfm)); in init_encrypted()
|
/linux/drivers/crypto/ux500/hash/ |
A D | hash_core.c | 1505 struct hash_algo_template *hash_alg; in hash_cra_init() local 1507 hash_alg = container_of(__crypto_ahash_alg(alg), in hash_cra_init() 1515 ctx->config.algorithm = hash_alg->conf.algorithm; in hash_cra_init() 1516 ctx->config.oper_mode = hash_alg->conf.oper_mode; in hash_cra_init() 1518 ctx->digestsize = hash_alg->hash.halg.digestsize; in hash_cra_init()
|
/linux/drivers/crypto/amcc/ |
A D | crypto4xx_sa.h | 98 u32 hash_alg:4; member
|
A D | crypto4xx_alg.c | 41 sa->sa_command_0.bf.hash_alg = h; in set_dynamic_sa_command_0()
|
A D | crypto4xx_core.c | 494 if (sa->sa_command_0.bf.hash_alg == SA_HASH_ALG_SHA1) { in crypto4xx_copy_digest_to_dst()
|
/linux/include/uapi/linux/ |
A D | openvswitch.h | 743 __u32 hash_alg; /* One of ovs_hash_alg. */ member
|
/linux/net/openvswitch/ |
A D | flow_netlink.c | 3108 switch (act_hash->hash_alg) { in __ovs_nla_copy_actions()
|
/linux/ |
A D | System.map | 57833 ffff800010f6e6e0 d hash_alg 57843 ffff800010f6e7b0 d hash_alg
|