diff options
author | Dr. Stephen Henson <steve@openssl.org> | 2006-10-03 04:47:59 +0200 |
---|---|---|
committer | Dr. Stephen Henson <steve@openssl.org> | 2006-10-03 04:47:59 +0200 |
commit | f4c630abb3552d5c8eabe23eadc5488017325449 (patch) | |
tree | 3efb533a4c89a6fa3746ae6992d7e10dd9c7af28 /crypto/x509/x509.h | |
parent | Initialise ctx to NULL to avoid uninitialized free, noticed by (diff) | |
download | openssl-f4c630abb3552d5c8eabe23eadc5488017325449.tar.xz openssl-f4c630abb3552d5c8eabe23eadc5488017325449.zip |
Place standard CRL behaviour in default X509_CRL_METHOD new functions to
create, free and set default CRL method.
Diffstat (limited to 'crypto/x509/x509.h')
-rw-r--r-- | crypto/x509/x509.h | 19 |
1 files changed, 18 insertions, 1 deletions
diff --git a/crypto/x509/x509.h b/crypto/x509/x509.h index f28086c175..51c5a0abce 100644 --- a/crypto/x509/x509.h +++ b/crypto/x509/x509.h @@ -460,7 +460,8 @@ struct X509_crl_st #ifndef OPENSSL_NO_SHA unsigned char sha1_hash[SHA_DIGEST_LENGTH]; #endif - X509_CRL_METHOD *meth; + const X509_CRL_METHOD *meth; + void *meth_data; } /* X509_CRL */; DECLARE_STACK_OF(X509_CRL) @@ -748,6 +749,22 @@ extern "C" { #define X509_CRL_get_issuer(x) ((x)->crl->issuer) #define X509_CRL_get_REVOKED(x) ((x)->crl->revoked) +void X509_CRL_set_default_method(const X509_CRL_METHOD *meth); +X509_CRL_METHOD *X509_CRL_METHOD_new( + int (*crl_init)(X509_CRL *crl), + int (*crl_free)(X509_CRL *crl), + int (*crl_lookup)(X509_CRL *crl, X509_REVOKED **ret, ASN1_INTEGER *ser), + int (*crl_verify)(X509_CRL *crl, EVP_PKEY *pk)); +void X509_CRL_METHOD_free(X509_CRL_METHOD *m); + +void X509_CRL_set_meth_data(X509_CRL *crl, void *dat); +void *X509_CRL_get_meth_data(X509_CRL *crl); + +IMPLEMENT_STACK_OF(X509_REVOKED) +IMPLEMENT_ASN1_SET_OF(X509_REVOKED) +IMPLEMENT_STACK_OF(X509_CRL) +IMPLEMENT_ASN1_SET_OF(X509_CRL) + /* This one is only used so that a binary form can output, as in * i2d_X509_NAME(X509_get_X509_PUBKEY(x),&buf) */ #define X509_get_X509_PUBKEY(x) ((x)->cert_info->key) |