TlsCertificate.from_files


Description:

public TlsCertificate.from_files (string cert_file, string key_file) throws Error

Creates a TlsCertificate from the PEM-encoded data in cert_file and key_file.

If either file cannot be read or parsed, the function will return null and set throws. Otherwise, this behaves like TlsCertificate.from_pem.

Parameters:

cert_file

file containing a PEM-encoded certificate to import

key_file

file containing a PEM-encoded private key to import

Returns:

the new certificate, or null on error