mirror of
https://github.com/openssl/openssl.git
synced 2024-12-16 21:43:42 +08:00
Constify X509_get0_signature()
Reviewed-by: Richard Levitte <levitte@openssl.org>
This commit is contained in:
parent
8900f3e398
commit
8adc1cb851
@ -604,7 +604,8 @@ int x509_main(int argc, char **argv)
|
||||
}
|
||||
|
||||
if (badsig) {
|
||||
ASN1_BIT_STRING *signature;
|
||||
const ASN1_BIT_STRING *signature;
|
||||
|
||||
X509_get0_signature(&signature, NULL, x);
|
||||
corrupt_signature(signature);
|
||||
}
|
||||
|
@ -191,8 +191,8 @@ int X509_print_ex(BIO *bp, X509 *x, unsigned long nmflags,
|
||||
X509_get0_extensions(x), cflag, 8);
|
||||
|
||||
if (!(cflag & X509_FLAG_NO_SIGDUMP)) {
|
||||
X509_ALGOR *sig_alg;
|
||||
ASN1_BIT_STRING *sig;
|
||||
const X509_ALGOR *sig_alg;
|
||||
const ASN1_BIT_STRING *sig;
|
||||
X509_get0_signature(&sig, &sig_alg, x);
|
||||
if (X509_signature_print(bp, sig_alg, sig) <= 0)
|
||||
goto err;
|
||||
|
@ -209,7 +209,8 @@ int i2d_re_X509_tbs(X509 *x, unsigned char **pp)
|
||||
return i2d_X509_CINF(&x->cert_info, pp);
|
||||
}
|
||||
|
||||
void X509_get0_signature(ASN1_BIT_STRING **psig, X509_ALGOR **palg, X509 *x)
|
||||
void X509_get0_signature(const ASN1_BIT_STRING **psig,
|
||||
const X509_ALGOR **palg, const X509 *x)
|
||||
{
|
||||
if (psig)
|
||||
*psig = &x->signature;
|
||||
|
@ -10,7 +10,8 @@ X509_CRL_get_signature_nid - signature information
|
||||
|
||||
#include <openssl/x509.h>
|
||||
|
||||
void X509_get0_signature(ASN1_BIT_STRING **psig, X509_ALGOR **palg,
|
||||
void X509_get0_signature(const ASN1_BIT_STRING **psig,
|
||||
const X509_ALGOR **palg,
|
||||
const X509 *x);
|
||||
int X509_get_signature_nid(const X509 *x);
|
||||
const X509_ALGOR *X509_get0_tbs_sigalg(const X509 *x);
|
||||
|
@ -548,7 +548,8 @@ X509 *d2i_X509_AUX(X509 **a, const unsigned char **pp, long length);
|
||||
|
||||
int i2d_re_X509_tbs(X509 *x, unsigned char **pp);
|
||||
|
||||
void X509_get0_signature(ASN1_BIT_STRING **psig, X509_ALGOR **palg, X509 *x);
|
||||
void X509_get0_signature(const ASN1_BIT_STRING **psig,
|
||||
const X509_ALGOR **palg, const X509 *x);
|
||||
int X509_get_signature_nid(const X509 *x);
|
||||
|
||||
int X509_trusted(const X509 *x);
|
||||
|
Loading…
Reference in New Issue
Block a user