summaryrefslogtreecommitdiff
path: root/lib/x509/common.h
diff options
context:
space:
mode:
Diffstat (limited to 'lib/x509/common.h')
-rw-r--r--lib/x509/common.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/lib/x509/common.h b/lib/x509/common.h
index 498ccc4e97..483bd1de6c 100644
--- a/lib/x509/common.h
+++ b/lib/x509/common.h
@@ -114,6 +114,18 @@
#define ASN1_NULL "\x05\x00"
#define ASN1_NULL_SIZE 2
+struct oid_to_string {
+ const char *oid;
+ unsigned oid_size;
+ const char *name_desc;
+ unsigned name_desc_size;
+ const char *asn_desc; /* description in the pkix file if complex type */
+ unsigned int etype; /* the libtasn1 ASN1_ETYPE or INVALID
+ * if cannot be simply parsed */
+};
+
+const struct oid_to_string *_gnutls_oid_get_entry(const struct oid_to_string *ots, const char *oid);
+
int _gnutls_x509_set_time(ASN1_TYPE c2, const char *where, time_t tim,
int force_general);
int
@@ -264,6 +276,8 @@ int _gnutls_x509_decode_ext(const gnutls_datum_t *der, gnutls_x509_ext_st *out);
int _gnutls_x509_raw_crt_to_raw_pubkey(const gnutls_datum_t * cert,
gnutls_datum_t * rpubkey);
+int _gnutls_x509_get_version(ASN1_TYPE root, const char *name);
+
int x509_crt_to_raw_pubkey(gnutls_x509_crt_t crt,
gnutls_datum_t * rpubkey);