mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-11-11 13:43:47 +01:00
Mock rsa_ed25519_crosscert_check
This commit just mocks the rsa_ed25519_crosscert_check to be used later in the fuzzer.
This commit is contained in:
parent
dc47d936d4
commit
c860282fc0
@ -356,12 +356,12 @@ tor_make_rsa_ed25519_crosscert(const ed25519_public_key_t *ed_key,
|
|||||||
*
|
*
|
||||||
* Return 0 on success, negative on failure.
|
* Return 0 on success, negative on failure.
|
||||||
*/
|
*/
|
||||||
int
|
MOCK_IMPL(int,
|
||||||
rsa_ed25519_crosscert_check(const uint8_t *crosscert,
|
rsa_ed25519_crosscert_check, (const uint8_t *crosscert,
|
||||||
const size_t crosscert_len,
|
const size_t crosscert_len,
|
||||||
const crypto_pk_t *rsa_id_key,
|
const crypto_pk_t *rsa_id_key,
|
||||||
const ed25519_public_key_t *master_key,
|
const ed25519_public_key_t *master_key,
|
||||||
const time_t reject_if_expired_before)
|
const time_t reject_if_expired_before))
|
||||||
{
|
{
|
||||||
rsa_ed_crosscert_t *cc = NULL;
|
rsa_ed_crosscert_t *cc = NULL;
|
||||||
int rv;
|
int rv;
|
||||||
|
@ -75,11 +75,12 @@ ssize_t tor_make_rsa_ed25519_crosscert(const ed25519_public_key_t *ed_key,
|
|||||||
const crypto_pk_t *rsa_key,
|
const crypto_pk_t *rsa_key,
|
||||||
time_t expires,
|
time_t expires,
|
||||||
uint8_t **cert);
|
uint8_t **cert);
|
||||||
int rsa_ed25519_crosscert_check(const uint8_t *crosscert,
|
MOCK_DECL(int,
|
||||||
const size_t crosscert_len,
|
rsa_ed25519_crosscert_check, (const uint8_t *crosscert,
|
||||||
const crypto_pk_t *rsa_id_key,
|
const size_t crosscert_len,
|
||||||
const ed25519_public_key_t *master_key,
|
const crypto_pk_t *rsa_id_key,
|
||||||
const time_t reject_if_expired_before);
|
const ed25519_public_key_t *master_key,
|
||||||
|
const time_t reject_if_expired_before));
|
||||||
|
|
||||||
or_handshake_certs_t *or_handshake_certs_new(void);
|
or_handshake_certs_t *or_handshake_certs_new(void);
|
||||||
void or_handshake_certs_free(or_handshake_certs_t *certs);
|
void or_handshake_certs_free(or_handshake_certs_t *certs);
|
||||||
|
Loading…
Reference in New Issue
Block a user