### Enumeration

# Gio TlsCertificateFlags

since: 2.28

#### Declaration

    flags Gio.TlsCertificateFlags

#### Description

A set of flags describing TLS certification validation. This can be used to describe why a particular certificate was rejected (for example, in `GTlsConnection::accept-certificate`).

GLib guarantees that if certificate verification fails, at least one flag will be set, but it does not guarantee that all possible flags will be set. Accordingly, you may not safely decide to ignore any particular type of error. For example, it would be incorrect to mask `G_TLS_CERTIFICATE_EXPIRED` if you want to allow expired certificates, because this could potentially be the only error flag set even if other problems exist with the certificate.

Available since: 2.28

#### Members

`G_TLS_CERTIFICATE_NO_FLAGS`

  No flags set. Since: 2.74

  - Value: `0`
  - Nickname: `no-flags`
  - Available since: 2.28
`G_TLS_CERTIFICATE_UNKNOWN_CA`

  The signing certificate authority is not known.

  - Value: `1`
  - Nickname: `unknown-ca`
  - Available since: 2.28
`G_TLS_CERTIFICATE_BAD_IDENTITY`

  The certificate does not match the expected identity of the site that it was retrieved from.

  - Value: `2`
  - Nickname: `bad-identity`
  - Available since: 2.28
`G_TLS_CERTIFICATE_NOT_ACTIVATED`

  The certificate’s activation time is still in the future.

  - Value: `4`
  - Nickname: `not-activated`
  - Available since: 2.28
`G_TLS_CERTIFICATE_EXPIRED`

  The certificate has expired.

  - Value: `8`
  - Nickname: `expired`
  - Available since: 2.28
`G_TLS_CERTIFICATE_REVOKED`

  The certificate has been revoked according to the `GTlsConnection`‘s certificate revocation list.

  - Value: `16`
  - Nickname: `revoked`
  - Available since: 2.28
`G_TLS_CERTIFICATE_INSECURE`

  The certificate’s algorithm is considered insecure.

  - Value: `32`
  - Nickname: `insecure`
  - Available since: 2.28
`G_TLS_CERTIFICATE_GENERIC_ERROR`

  Some other error occurred validating the certificate.

  - Value: `64`
  - Nickname: `generic-error`
  - Available since: 2.28
`G_TLS_CERTIFICATE_VALIDATE_ALL`

  The combination of all of the above flags.

  - Value: `127`
  - Nickname: `validate-all`
  - Available since: 2.28