ASN1_SIMPLE(X509_CINF, serialNumber, ASN1_INTEGER),
ASN1_SIMPLE(X509_CINF, signature, X509_ALGOR),
ASN1_SIMPLE(X509_CINF, issuer, X509_NAME),
- ASN1_SIMPLE(X509_CINF, validity, X509_VAL),
+ ASN1_EMBED(X509_CINF, validity, X509_VAL),
ASN1_SIMPLE(X509_CINF, subject, X509_NAME),
ASN1_SIMPLE(X509_CINF, key, X509_PUBKEY),
ASN1_IMP_OPT(X509_CINF, issuerUID, ASN1_BIT_STRING, 1),
if (X509_set_issuer_name(ret, X509_NAME_dup(xn)) == 0)
goto err;
- if (X509_gmtime_adj(xi->validity->notBefore, 0) == NULL)
+ if (X509_gmtime_adj(xi->validity.notBefore, 0) == NULL)
goto err;
- if (X509_gmtime_adj(xi->validity->notAfter, (long)60 * 60 * 24 * days) ==
+ if (X509_gmtime_adj(xi->validity.notAfter, (long)60 * 60 * 24 * days) ==
NULL)
goto err;
{
ASN1_TIME *in;
- if ((x == NULL) || (x->cert_info->validity == NULL))
+ if (x == NULL)
return (0);
- in = x->cert_info->validity->notBefore;
+ in = x->cert_info->validity.notBefore;
if (in != tm) {
in = ASN1_STRING_dup(tm);
if (in != NULL) {
- ASN1_TIME_free(x->cert_info->validity->notBefore);
- x->cert_info->validity->notBefore = in;
+ ASN1_TIME_free(x->cert_info->validity.notBefore);
+ x->cert_info->validity.notBefore = in;
}
}
return (in != NULL);
{
ASN1_TIME *in;
- if ((x == NULL) || (x->cert_info->validity == NULL))
+ if (x == NULL)
return (0);
- in = x->cert_info->validity->notAfter;
+ in = x->cert_info->validity.notAfter;
if (in != tm) {
in = ASN1_STRING_dup(tm);
if (in != NULL) {
- ASN1_TIME_free(x->cert_info->validity->notAfter);
- x->cert_info->validity->notAfter = in;
+ ASN1_TIME_free(x->cert_info->validity.notAfter);
+ x->cert_info->validity.notAfter = in;
}
}
return (in != NULL);
ASN1_TIME * X509_get_notBefore(X509 *x)
{
- return x->cert_info->validity->notBefore;
+ return x->cert_info->validity.notBefore;
}
ASN1_TIME *X509_get_notAfter(X509 *x)
{
- return x->cert_info->validity->notAfter;
+ return x->cert_info->validity.notAfter;
}
int X509_get_signature_type(const X509 *x)
ASN1_INTEGER *serialNumber;
X509_ALGOR *signature;
X509_NAME *issuer;
- X509_VAL *validity;
+ X509_VAL validity;
X509_NAME *subject;
X509_PUBKEY *key;
ASN1_BIT_STRING *issuerUID; /* [ 1 ] optional in v2 */