summaryrefslogtreecommitdiff
path: root/plat/st/common/include/stm32mp_auth.h
blob: 3075d18ac7dc5803f693b8a961e4880b6cec1100 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
/*
 * Copyright (c) 2019, ARM Limited and Contributors. All rights reserved.
 *
 * SPDX-License-Identifier: BSD-3-Clause
 */

#ifndef STM32MP_AUTH_H
#define STM32MP_AUTH_H

struct stm32mp_auth_ops {
	uint32_t (*check_key)(uint8_t *pubkey_in, uint8_t *pubkey_out);
	uint32_t (*verify_signature)(uint8_t *hash_in, uint8_t *pubkey_in,
				     uint8_t *signature, uint32_t ecc_algo);
};

void stm32mp_init_auth(struct stm32mp_auth_ops *init_ptr);
int stm32mp_auth_image(boot_api_image_header_t *header, uintptr_t buffer);

#endif /* STM32MP_AUTH_H */