summaryrefslogtreecommitdiff
path: root/src/security/vboot/mrc_cache_hash_tpm.h
blob: cf443f291bdeb98f9df97e03ea8e919097466f14 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
/* SPDX-License-Identifier: GPL-2.0-only */

#ifndef _MRC_CACHE_HASH_TPM_H_
#define _MRC_CACHE_HASH_TPM_H_

#include <types.h>

/*
 * Updates mrc cache hash if it differs.
 */
void mrc_cache_update_hash(uint32_t index, const uint8_t *data, size_t size);

/*
 * Verifies mrc cache hash which is stored somewhere.
 * return 1 verification was successful and 0 for error.
 */
int mrc_cache_verify_hash(uint32_t index, const uint8_t *data, size_t size);

#endif /* _MRC_CACHE_HASH_TPM_H_ */