30 #include <apr_pools.h> 31 #include <apr_tables.h> 41 #define SVN_X509_OID_COMMON_NAME "\x55\x04\x03" 42 #define SVN_X509_OID_COUNTRY "\x55\x04\x06" 43 #define SVN_X509_OID_LOCALITY "\x55\x04\x07" 44 #define SVN_X509_OID_STATE "\x55\x04\x08" 45 #define SVN_X509_OID_ORGANIZATION "\x55\x04\x0A" 46 #define SVN_X509_OID_ORG_UNIT "\x55\x04\x0B" 47 #define SVN_X509_OID_EMAIL "\x2A\x86\x48\x86\xF7\x0D\x01\x09\x01" 83 apr_pool_t *result_pool,
84 apr_pool_t *scratch_pool);
93 apr_pool_t *result_pool,
94 apr_pool_t *scratch_pool);
101 const unsigned char *
119 apr_pool_t *result_pool,
120 apr_pool_t *scratch_pool);
128 apr_pool_t *result_pool);
136 const apr_array_header_t *
145 apr_pool_t *result_pool);
153 const apr_array_header_t *
184 const apr_array_header_t *
196 apr_pool_t *scratch_pool, apr_pool_t *result_pool);
struct svn_x509_name_attr_t svn_x509_name_attr_t
Representation of an atttribute in an X.509 name (e.g.
Subversion checksum routines.
apr_time_t svn_x509_certinfo_get_valid_from(const svn_x509_certinfo_t *certinfo)
Returns the start of the certificate validity period from certinfo.
svn_x509_certinfo_t * svn_x509_certinfo_dup(const svn_x509_certinfo_t *certinfo, apr_pool_t *result_pool, apr_pool_t *scratch_pool)
Returns a deep copy of certinfo, allocated in result_pool.
svn_x509_name_attr_t * svn_x509_name_attr_dup(const svn_x509_name_attr_t *attr, apr_pool_t *result_pool, apr_pool_t *scratch_pool)
Returns a deep copy of the attr, allocated in result_pool.
struct svn_x509_certinfo_t svn_x509_certinfo_t
Representation of parsed certificate info.
const svn_checksum_t * svn_x509_certinfo_get_digest(const svn_x509_certinfo_t *certinfo)
Returns the digest (fingerprint) from certinfo.
const apr_array_header_t * svn_x509_certinfo_get_issuer_attrs(const svn_x509_certinfo_t *certinfo)
Returns a list of the attributes for the issuer in the certinfo.
A generic checksum representation.
const apr_array_header_t * svn_x509_certinfo_get_hostnames(const svn_x509_certinfo_t *certinfo)
Returns an array of (const char*) host names from certinfo.
Common exception handling for Subversion.
svn_error_t * svn_x509_parse_cert(svn_x509_certinfo_t **certinfo, const char *buf, apr_size_t buflen, apr_pool_t *result_pool, apr_pool_t *scratch_pool)
Parse x509 der certificate data from buf with length buflen and return certificate information in *ce...
apr_time_t svn_x509_certinfo_get_valid_to(const svn_x509_certinfo_t *certinfo)
Returns the end of the certificate validity period from certinfo.
const char * svn_x509_certinfo_get_issuer(const svn_x509_certinfo_t *certinfo, apr_pool_t *result_pool)
Returns the cerficiate issuer DN from certinfo.
const char * svn_x509_certinfo_get_subject(const svn_x509_certinfo_t *certinfo, apr_pool_t *result_pool)
Returns the subject DN from certinfo.
const char * svn_x509_name_attr_get_value(const svn_x509_name_attr_t *attr)
Returns the value of attr as a UTF-8 C string.
const unsigned char * svn_x509_name_attr_get_oid(const svn_x509_name_attr_t *attr, apr_size_t *len)
Returns the OID of attr as encoded in the certificate.
const apr_array_header_t * svn_x509_certinfo_get_subject_attrs(const svn_x509_certinfo_t *certinfo)
Returns a list of the attributes for the subject in the certinfo.
const char * svn_x509_oid_to_string(const unsigned char *oid, apr_size_t oid_len, apr_pool_t *scratch_pool, apr_pool_t *result_pool)
Given an oid return a null-terminated C string representation.