Index: openssl/crypto/asn1/x_x509.c |
=================================================================== |
--- openssl/crypto/asn1/x_x509.c (revision 105093) |
+++ openssl/crypto/asn1/x_x509.c (working copy) |
@@ -63,7 +63,7 @@ |
#include <openssl/x509.h> |
#include <openssl/x509v3.h> |
-ASN1_SEQUENCE(X509_CINF) = { |
+ASN1_SEQUENCE_enc(X509_CINF, enc, 0) = { |
ASN1_EXP_OPT(X509_CINF, version, ASN1_INTEGER, 0), |
ASN1_SIMPLE(X509_CINF, serialNumber, ASN1_INTEGER), |
ASN1_SIMPLE(X509_CINF, signature, X509_ALGOR), |
@@ -74,14 +74,15 @@ |
ASN1_IMP_OPT(X509_CINF, issuerUID, ASN1_BIT_STRING, 1), |
ASN1_IMP_OPT(X509_CINF, subjectUID, ASN1_BIT_STRING, 2), |
ASN1_EXP_SEQUENCE_OF_OPT(X509_CINF, extensions, X509_EXTENSION, 3) |
-} ASN1_SEQUENCE_END(X509_CINF) |
+} ASN1_SEQUENCE_END_enc(X509_CINF, X509_CINF) |
IMPLEMENT_ASN1_FUNCTIONS(X509_CINF) |
/* X509 top level structure needs a bit of customisation */ |
extern void policy_cache_free(X509_POLICY_CACHE *cache); |
-static int x509_cb(int operation, ASN1_VALUE **pval, const ASN1_ITEM *it) |
+static int x509_cb(int operation, ASN1_VALUE **pval, const ASN1_ITEM *it, |
+ void *exarg) |
{ |
X509 *ret = (X509 *)*pval; |
@@ -99,6 +100,7 @@ |
ret->rfc3779_asid = NULL; |
#endif |
ret->aux = NULL; |
+ ret->crldp = NULL; |
CRYPTO_new_ex_data(CRYPTO_EX_INDEX_X509, ret, &ret->ex_data); |
break; |
@@ -112,7 +114,10 @@ |
X509_CERT_AUX_free(ret->aux); |
ASN1_OCTET_STRING_free(ret->skid); |
AUTHORITY_KEYID_free(ret->akid); |
+ CRL_DIST_POINTS_free(ret->crldp); |
policy_cache_free(ret->policy_cache); |
+ GENERAL_NAMES_free(ret->altname); |
+ NAME_CONSTRAINTS_free(ret->nc); |
#ifndef OPENSSL_NO_RFC3779 |
sk_IPAddressFamily_pop_free(ret->rfc3779_addr, IPAddressFamily_free); |
ASIdentifiers_free(ret->rfc3779_asid); |
@@ -136,19 +141,6 @@ |
IMPLEMENT_ASN1_FUNCTIONS(X509) |
IMPLEMENT_ASN1_DUP_FUNCTION(X509) |
-static ASN1_METHOD meth= |
- { |
- (I2D_OF(void)) i2d_X509, |
- (D2I_OF(void)) d2i_X509, |
- (void *(*)(void))X509_new, |
- (void (*)(void *)) X509_free |
- }; |
- |
-ASN1_METHOD *X509_asn1_meth(void) |
- { |
- return(&meth); |
- } |
- |
int X509_get_ex_new_index(long argl, void *argp, CRYPTO_EX_new *new_func, |
CRYPTO_EX_dup *dup_func, CRYPTO_EX_free *free_func) |
{ |