Commit 604f6eff authored by Matt Caswell's avatar Matt Caswell Committed by Dr. Stephen Henson
Browse files

Convert X509_REVOKED* functions to use const getters

parent dd8e5a57
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -13,7 +13,7 @@
#include <openssl/buffer.h>
#include <openssl/asn1.h>

int i2a_ASN1_INTEGER(BIO *bp, ASN1_INTEGER *a)
int i2a_ASN1_INTEGER(BIO *bp, const ASN1_INTEGER *a)
{
    int i, n = 0;
    static const char *h = "0123456789ABCDEF";
+3 −3
Original line number Diff line number Diff line
@@ -139,7 +139,7 @@ int X509_CRL_get_signature_nid(const X509_CRL *crl)
    return OBJ_obj2nid(crl->sig_alg.algorithm);
}

ASN1_TIME *X509_REVOKED_get0_revocationDate(X509_REVOKED *x)
const ASN1_TIME *X509_REVOKED_get0_revocationDate(const X509_REVOKED *x)
{
    return x->revocationDate;
}
@@ -161,7 +161,7 @@ int X509_REVOKED_set_revocationDate(X509_REVOKED *x, ASN1_TIME *tm)
    return (in != NULL);
}

ASN1_INTEGER *X509_REVOKED_get0_serialNumber(X509_REVOKED *x)
const ASN1_INTEGER *X509_REVOKED_get0_serialNumber(const X509_REVOKED *x)
{
    return &x->serialNumber;
}
@@ -178,7 +178,7 @@ int X509_REVOKED_set_serialNumber(X509_REVOKED *x, ASN1_INTEGER *serial)
    return 1;
}

STACK_OF(X509_EXTENSION) *X509_REVOKED_get0_extensions(const X509_REVOKED *r)
const STACK_OF(X509_EXTENSION) *X509_REVOKED_get0_extensions(const X509_REVOKED *r)
{
    return r->extensions;
}
+1 −1
Original line number Diff line number Diff line
@@ -34,7 +34,7 @@ X509_REVOKED_add1_ext_i2d - X509 extension decode and encode functions

 const STACK_OF(X509_EXTENSION) *X509_get0_extensions(const X509 *x);
 const STACK_OF(X509_EXTENSION) *X509_CRL_get0_extensions(const X509_CRL *crl);
 STACK_OF(X509_EXTENSION) *X509_REVOKED_get0_extensions(const X509_REVOKED *r);
 const STACK_OF(X509_EXTENSION) *X509_REVOKED_get0_extensions(const X509_REVOKED *r);

=head1 DESCRIPTION

+2 −2
Original line number Diff line number Diff line
@@ -18,8 +18,8 @@ functions

 STACK_OF(X509_REVOKED) *X509_CRL_get_REVOKED(X509_CRL *crl);

 ASN1_INTEGER *X509_REVOKED_get0_serialNumber(X509_REVOKED *r);
 ASN1_TIME *X509_REVOKED_get0_revocationDate(X509_REVOKED *r);
 const ASN1_INTEGER *X509_REVOKED_get0_serialNumber(const X509_REVOKED *r);
 const ASN1_TIME *X509_REVOKED_get0_revocationDate(const X509_REVOKED *r);

 int X509_REVOKED_set_serialNumber(X509_REVOKED *r, ASN1_INTEGER *serial);
 int X509_REVOKED_set_revocationDate(X509_REVOKED *r, ASN1_TIME *tm);
+1 −1
Original line number Diff line number Diff line
@@ -629,7 +629,7 @@ ASN1_GENERALIZEDTIME *ASN1_TIME_to_generalizedtime(ASN1_TIME *t, ASN1_GENERALIZE
                                                   **out);
int ASN1_TIME_set_string(ASN1_TIME *s, const char *str);

int i2a_ASN1_INTEGER(BIO *bp, ASN1_INTEGER *a);
int i2a_ASN1_INTEGER(BIO *bp, const ASN1_INTEGER *a);
int a2i_ASN1_INTEGER(BIO *bp, ASN1_INTEGER *bs, char *buf, int size);
int i2a_ASN1_ENUMERATED(BIO *bp, ASN1_ENUMERATED *a);
int a2i_ASN1_ENUMERATED(BIO *bp, ASN1_ENUMERATED *bs, char *buf, int size);
Loading