---
name: "libressl-X509_CINF_new"
section: "3"
platform: "linux"
package: "libressl"
version: "4.4.0-1"
release: "Arch Linux 2026-11-01"
platforms: ["linux"]
url: "https://new.carta.tech/libressl-X509_CINF_new"
---

# libressl-X509\_CINF\_new(3)

X.509 certificate information objects

## NAME

**X509\_CINF\_new**, **X509\_CINF\_free**, **X509\_VAL\_new**, **X509\_VAL\_free**, **X509\_CERT\_AUX\_new**, **X509\_CERT\_AUX\_free** – X.509 certificate information objects

## SYNOPSIS

Crypto Library (libcrypto, -lcrypto)

**#include \<openssl/x509.h\>**

*X509\_CINF* *\**\

**X509\_CINF\_new**(*void*);

*void*\

**X509\_CINF\_free**(*X509\_CINF \*inf*);

*X509\_VAL* *\**\

**X509\_VAL\_new**(*void*);

*void*\

**X509\_VAL\_free**(*X509\_VAL \*val*);

*X509\_CERT\_AUX* *\**\

**X509\_CERT\_AUX\_new**(*void*);

*void*\

**X509\_CERT\_AUX\_free**(*X509\_CERT\_AUX \*aux*);

## DESCRIPTION

**X509\_CINF\_new**() allocates and initializes an empty *X509\_CINF* object, representing an ASN.1 *TBSCertificate* structure defined in RFC 5280 section 4.1. It is used inside the *X509* object and holds the main information contained in the X.509 certificate including subject, public key, issuer, serial number, validity period, and extensions. **X509\_CINF\_free**() frees *inf*.

**X509\_VAL\_new**() allocates and initializes an empty *X509\_VAL* object, representing an ASN.1 *Validity* structure defined in RFC 5280 section 4.1. It is used inside the *X509\_CINF* object and holds the validity period of the certificate. **X509\_VAL\_free**() frees *val*.

**X509\_CERT\_AUX\_new**() allocates and initializes an empty *X509\_CERT\_AUX* structure. It can be used inside an *X509* object to hold optional non-standard auxiliary data appended to a certificate, for example friendly alias names and trust data. **X509\_CERT\_AUX\_free**() frees *aux*.

## RETURN VALUES

**X509\_CINF\_new**(), **X509\_VAL\_new**(), and **X509\_CERT\_AUX\_new**() return the new *X509\_CINF*, *X509\_VAL*, or *X509\_CERT\_AUX* object, respectively, or NULL if an error occurs.

## SEE ALSO

d2i\_X509\_CINF(3), X509\_add1\_trust\_object(3), X509\_CERT\_AUX\_print(3), X509\_keyid\_set1(3), X509\_new(3)

## STANDARDS

RFC 5280: Internet X.509 Public Key Infrastructure Certificate and Certificate Revocation List (CRL) Profile

## HISTORY

**X509\_CINF\_new**(), **X509\_CINF\_free**(), **X509\_VAL\_new**(), and **X509\_VAL\_free**() appeared in SSLeay 0.4 or earlier and have been available since OpenBSD 2.4.

**X509\_CERT\_AUX\_new**() and **X509\_CERT\_AUX\_free**() first appeared in OpenSSL 0.9.5 and have been available since OpenBSD 2.7.
