correctly reset params.
[gnutls.git] / libextra / openssl_compat.h
blob52484f2b198bcb376ef54193f08e20b79a543e94
1 /*
2 * Copyright (C) 2002, 2003, 2004, 2005, 2008, 2010 Free Software
3 * Foundation, Inc.
5 * Author: Nikos Mavrogiannopoulos
7 * This file is part of GnuTLS-EXTRA.
9 * GnuTLS-extra is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU General Public License as
11 * published by the Free Software Foundation; either version 3 of the
12 * License, or (at your option) any later version.
14 * GnuTLS-extra is distributed in the hope that it will be useful, but
15 * WITHOUT ANY WARRANTY; without even the implied warranty of
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
17 * General Public License for more details.
19 * You should have received a copy of the GNU General Public License
20 * along with GnuTLS-EXTRA; if not, write to the Free Software
21 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
22 * 02110-1301, USA.
26 #ifndef GNUTLS_COMPAT8_H
27 #define GNUTLS_COMPAT8_H
29 /* Extra definitions */
30 #include <gnutls/openssl.h>
32 int gnutls_x509_extract_dn (const gnutls_datum_t *, gnutls_x509_dn *);
33 int gnutls_x509_extract_dn_string (const gnutls_datum_t * idn,
34 char *buf, unsigned int sizeof_buf);
35 int gnutls_x509_extract_certificate_dn (const gnutls_datum_t *,
36 gnutls_x509_dn *);
37 int gnutls_x509_extract_certificate_dn_string (char *buf,
38 unsigned int sizeof_buf,
39 const gnutls_datum_t * cert,
40 int issuer);
41 int gnutls_x509_extract_certificate_issuer_dn (const gnutls_datum_t *,
42 gnutls_x509_dn *);
43 int gnutls_x509_extract_certificate_version (const gnutls_datum_t *);
44 int gnutls_x509_extract_certificate_serial (const gnutls_datum_t * cert,
45 char *result, int *result_size);
46 time_t gnutls_x509_extract_certificate_activation_time (const gnutls_datum_t
47 *);
48 time_t gnutls_x509_extract_certificate_expiration_time (const gnutls_datum_t
49 *);
50 int gnutls_x509_extract_certificate_subject_alt_name (const gnutls_datum_t
51 *, int seq, char *,
52 int *);
53 int gnutls_x509_pkcs7_extract_certificate (const gnutls_datum_t *
54 pkcs7_struct, int indx,
55 char *certificate,
56 int *certificate_size);
57 int gnutls_x509_extract_certificate_pk_algorithm (const gnutls_datum_t *
58 cert, int *bits);
59 int gnutls_x509_extract_certificate_ca_status (const gnutls_datum_t * cert);
60 int gnutls_x509_extract_key_pk_algorithm (const gnutls_datum_t * key);
62 int gnutls_x509_verify_certificate (const gnutls_datum_t * cert_list,
63 int cert_list_length,
64 const gnutls_datum_t * CA_list,
65 int CA_list_length,
66 const gnutls_datum_t * CRL_list,
67 int CRL_list_length);
69 #define gnutls_x509_fingerprint gnutls_fingerprint
70 #define gnutls_x509_certificate_format gnutls_x509_crt_fmt_t
72 #define gnutls_certificate_set_rsa_params gnutls_certificate_set_rsa_export_params
74 #endif