18 typedef struct tor_x509_cert_t tor_x509_cert_t;
21 typedef struct CERTCertificateStr tor_x509_cert_impl_t;
22 #elif defined(ENABLE_OPENSSL)
23 typedef struct x509_st tor_x509_cert_impl_t;
26 #ifdef TOR_X509_PRIVATE
28 struct tor_x509_cert_t {
29 tor_x509_cert_impl_t *cert;
34 unsigned pkey_digests_set : 1;
40 void tor_tls_pick_certificate_lifetime(time_t now,
41 unsigned cert_lifetime,
42 time_t *start_time_out,
43 time_t *end_time_out);
46 tor_x509_cert_t *tor_x509_cert_replace_expiration(
47 const tor_x509_cert_t *inp,
48 time_t new_expiration_time,
55 #define tor_x509_cert_free(c) \
56 FREE_AND_NULL(tor_x509_cert_t, tor_x509_cert_free_, (c))
58 size_t certificate_len);
60 const uint8_t **encoded_out,
size_t *size_out);
63 const tor_x509_cert_t *cert);
65 const tor_x509_cert_t *cert);
70 const tor_x509_cert_t *cert,
71 const tor_x509_cert_t *signing_cert,
Headers for crypto_rsa.c.
Macros to implement mocking and selective exposure for the test code.
tor_x509_cert_t * tor_x509_cert_dup(const tor_x509_cert_t *cert)
crypto_pk_t * tor_tls_cert_get_key(tor_x509_cert_t *cert)
const common_digests_t * tor_x509_cert_get_cert_digests(const tor_x509_cert_t *cert)
int tor_tls_cert_is_valid(int severity, const tor_x509_cert_t *cert, const tor_x509_cert_t *signing_cert, time_t now, int check_rsa_1024)
void tor_x509_cert_get_der(const tor_x509_cert_t *cert, const uint8_t **encoded_out, size_t *size_out)
tor_x509_cert_t * tor_x509_cert_decode(const uint8_t *certificate, size_t certificate_len)
const common_digests_t * tor_x509_cert_get_id_digests(const tor_x509_cert_t *cert)
void tor_x509_cert_free_(tor_x509_cert_t *cert)