21#ifndef PROTOCORE_RSA_H
22#define PROTOCORE_RSA_H
26#if PROTOCORE_ENABLE_RSA
34#define PROTOCORE_RSA_SIG_BYTES 256
43 PROTOCORE_RSA_HASH_SHA256 = 0,
44 PROTOCORE_RSA_HASH_SHA512 = 1,
45 PROTOCORE_RSA_HASH_PSS_SHA256 = 2
49#define PROTOCORE_PKCS1_DIGESTINFO_LEN 19
52#define PROTOCORE_PKCS1_SHA512_DIGESTINFO_LEN 19
55extern const uint8_t protocore_pkcs1_sha256_digestinfo[PROTOCORE_PKCS1_DIGESTINFO_LEN];
58extern const uint8_t protocore_pkcs1_sha512_digestinfo[PROTOCORE_PKCS1_SHA512_DIGESTINFO_LEN];
73 protocore_rsa_hash hash;
83 protocore_rsa_hash hash;
125 RsaVerifyArgs verify_args;
126 RsaSignArgs sign_args;
136 void (*
const verify)(uint8_t *work);
137 void (*
const sign)(uint8_t *work);
142void protocore_rsa_verify(uint8_t *work);
143void protocore_rsa_sign(uint8_t *work);
149static const RsaNs Rsa __attribute__((unused)) = {
150 .verify = protocore_rsa_verify,
151 .sign = protocore_rsa_sign,
PROTO_ENUM_PACKED
Application protocol spoken on a listener port or connection slot.
#define PROTOCORE_BEGIN_DECLS
Give a header's declarations C linkage, so their symbol names carry no parameter types.
_Bool proto_bool
The truth value.
#define PROTOCORE_END_DECLS