Home
last modified time | relevance | path

Searched refs:hash_ctx (Results 1 – 7 of 7) sorted by relevance

/external/fsverity-utils/
Dhash_algs.h13 struct hash_ctx *(*create_ctx)(const struct fsverity_hash_alg *alg);
18 struct hash_ctx { struct
20 void (*init)(struct hash_ctx *ctx); argument
21 void (*update)(struct hash_ctx *ctx, const void *data, size_t size); argument
22 void (*final)(struct hash_ctx *ctx, u8 *out); argument
23 void (*free)(struct hash_ctx *ctx); argument
37 static inline struct hash_ctx *hash_create(const struct fsverity_hash_alg *alg) in hash_create()
42 static inline void hash_init(struct hash_ctx *ctx) in hash_init()
47 static inline void hash_update(struct hash_ctx *ctx, in hash_update()
53 static inline void hash_final(struct hash_ctx *ctx, u8 *digest) in hash_final()
[all …]
Dhash_algs.c17 static void free_hash_ctx(struct hash_ctx *ctx) in free_hash_ctx()
25 struct hash_ctx base; /* must be first */
30 static void openssl_digest_init(struct hash_ctx *_ctx) in openssl_digest_init()
39 static void openssl_digest_update(struct hash_ctx *_ctx, in openssl_digest_update()
49 static void openssl_digest_final(struct hash_ctx *_ctx, u8 *digest) in openssl_digest_final()
58 static void openssl_digest_ctx_free(struct hash_ctx *_ctx) in openssl_digest_ctx_free()
71 static struct hash_ctx *
97 static struct hash_ctx *create_sha256_ctx(const struct fsverity_hash_alg *alg) in create_sha256_ctx()
102 static struct hash_ctx *create_sha512_ctx(const struct fsverity_hash_alg *alg) in create_sha512_ctx()
117 struct hash_ctx base; /* must be first */
[all …]
Dcmd_setup.c114 struct hash_ctx *hash, in build_merkle_tree()
238 struct hash_ctx *hash) in append_fsverity_descriptor()
342 struct hash_ctx *hash = NULL; in fsveritysetup()
/external/u-boot/lib/
Dtpm-v1.c468 sha1_context hash_ctx; in create_request_auth() local
477 sha1_starts(&hash_ctx); in create_request_auth()
478 sha1_update(&hash_ctx, request + command_code_offset, 4); in create_request_auth()
480 sha1_update(&hash_ctx, in create_request_auth()
484 sha1_finish(&hash_ctx, hmac_data); in create_request_auth()
486 sha1_starts(&hash_ctx); in create_request_auth()
487 sha1_update(&hash_ctx, auth_session->nonce_odd, DIGEST_LENGTH); in create_request_auth()
488 sha1_update(&hash_ctx, hmac_data, sizeof(hmac_data)); in create_request_auth()
489 sha1_finish(&hash_ctx, auth_session->nonce_odd); in create_request_auth()
532 sha1_context hash_ctx; in verify_response_auth() local
[all …]
/external/u-boot/drivers/crypto/fsl/
Dfsl_hash.c82 static int caam_hash_update(void *hash_ctx, const void *buf, in caam_hash_update() argument
88 struct sha_ctx *ctx = hash_ctx; in caam_hash_update()
128 static int caam_hash_finish(void *hash_ctx, void *dest_buf, in caam_hash_finish() argument
132 struct sha_ctx *ctx = hash_ctx; in caam_hash_finish()
/external/boringssl/src/crypto/hrss/
Dhrss.c2056 SHA256_CTX hash_ctx; in HRSS_encap() local
2057 SHA256_Init(&hash_ctx); in HRSS_encap()
2058 SHA256_Update(&hash_ctx, kSharedKey, sizeof(kSharedKey)); in HRSS_encap()
2059 SHA256_Update(&hash_ctx, m_bytes, sizeof(m_bytes)); in HRSS_encap()
2060 SHA256_Update(&hash_ctx, r_bytes, sizeof(r_bytes)); in HRSS_encap()
2061 SHA256_Update(&hash_ctx, out_ciphertext, POLY_BYTES); in HRSS_encap()
2062 SHA256_Final(out_shared_key, &hash_ctx); in HRSS_encap()
2083 SHA256_CTX hash_ctx; in HRSS_decap() local
2084 SHA256_Init(&hash_ctx); in HRSS_decap()
2085 SHA256_Update(&hash_ctx, masked_key, sizeof(masked_key)); in HRSS_decap()
[all …]
/external/boringssl/src/third_party/fiat/
Dcurve25519.c1907 SHA512_CTX hash_ctx; in ED25519_sign() local
1908 SHA512_Init(&hash_ctx); in ED25519_sign()
1909 SHA512_Update(&hash_ctx, az + 32, 32); in ED25519_sign()
1910 SHA512_Update(&hash_ctx, message, message_len); in ED25519_sign()
1912 SHA512_Final(nonce, &hash_ctx); in ED25519_sign()
1919 SHA512_Init(&hash_ctx); in ED25519_sign()
1920 SHA512_Update(&hash_ctx, out_sig, 32); in ED25519_sign()
1921 SHA512_Update(&hash_ctx, private_key + 32, 32); in ED25519_sign()
1922 SHA512_Update(&hash_ctx, message, message_len); in ED25519_sign()
1924 SHA512_Final(hram, &hash_ctx); in ED25519_sign()
[all …]