Companion

object Companion

Properties

Link copied to clipboard
open val type: <Error class: unknown class><TlsCertificate>

Functions

Link copied to clipboard
fun listNewFromFile(file: String): <Error class: unknown class><<Error class: unknown class>>

Creates one or more #GTlsCertificates from the PEM-encoded data in @file. If @file cannot be read or parsed, the function will return null and set @error. If @file does not contain any PEM-encoded certificates, this will return an empty list and not set @error.

Link copied to clipboard
fun newFromFiles(certFile: String, keyFile: String): <Error class: unknown class><TlsCertificate>

Creates a #GTlsCertificate from the PEM-encoded data in @cert_file and @key_file. The returned certificate will be the first certificate found in @cert_file. As of GLib 2.44, if @cert_file contains more certificates it will try to load a certificate chain. All certificates will be verified in the order found (top-level certificate should be the last one in the file) and the #GTlsCertificate:issuer property of each certificate will be set accordingly if the verification succeeds. If any certificate in the chain cannot be verified, the first certificate in the file will still be returned.

Link copied to clipboard
fun newFromFileWithPassword(file: String, password: String): <Error class: unknown class><TlsCertificate>

Creates a #GTlsCertificate from the data in @file.