Set an ASN.1 GeneralizedTime to t plus a day/second offset.

Synopsis

Declared in <openssl/asn1.h>

ASN1_GENERALIZEDTIME*
ASN1_GENERALIZEDTIME_adj(
    ASN1_GENERALIZEDTIME* s,
    time_t t,
    int offset_day,
    long offset_sec);

Return Value

Pointer to the result (same as s when non‐NULL), or NULL on error.

Parameters

Name

Description

s

Destination time to reuse, or NULL to allocate a new one.

t

Base calendar time (seconds since the Epoch).

offset_day

Days to add to t (may be negative).

offset_sec

Seconds to add after offset_day (may be negative).

Created with MrDocs