1 /* SPDX-License-Identifier: BSD-2-Clause */ 2 /* 3 * Copyright 2018-2020 NXP 4 * 5 * Definition of the functions shared locally. 6 */ 7 #ifndef __LOCAL_H__ 8 #define __LOCAL_H__ 9 10 #include <drvcrypt_acipher.h> 11 12 /* 13 * Mask Generation function. Use a Hash operation 14 * to generate an output @mask from an input @seed 15 * 16 * @mgf_data [in/out] MGF data 17 */ 18 TEE_Result drvcrypt_rsa_mgf1(struct drvcrypt_rsa_mgf *mgf_data); 19 20 /* 21 * PKCS#1 - Signature of RSA message and encodes the signature. 22 * 23 * @ssa_data [in/out] RSA data to sign / Signature 24 */ 25 TEE_Result drvcrypt_rsassa_sign(struct drvcrypt_rsa_ssa *ssa_data); 26 27 /* 28 * PKCS#1 - Verification the encoded signature of RSA message. 29 * 30 * @ssa_data RSA Encoded signature data 31 */ 32 TEE_Result drvcrypt_rsassa_verify(struct drvcrypt_rsa_ssa *ssa_data); 33 34 #endif /* __LOCAL_H__ */ 35