get_tls_info


Description:

public bool get_tls_info (out unowned TlsCertificate certificate, out TlsCertificateFlags errors)

Retrieves the TlsCertificate associated with the main resource of this.

Retrieves the TlsCertificate associated with the main resource of this, and the TlsCertificateFlags showing what problems, if any, have been found with that certificate. If the connection is not HTTPS, this function returns false. This function should be called after a response has been received from the server, so you can connect to load_changed and call this function when it's emitted with webkit_load_committed event.

Note that this function provides no information about the security of the web page if the current TLSErrorsPolicy is webkit_tls_errors_policy_ignore, as subresources of the page may be controlled by an attacker. This function may safely be used to determine the security status of the current page only if the current TLSErrorsPolicy is webkit_tls_errors_policy_fail, in which case subresources that fail certificate verification will be blocked.

Parameters:

this

a WebView

certificate

return location for a TlsCertificate

errors

return location for a TlsCertificateFlags the verification status of certificate

Returns:

true if the this connection uses HTTPS and a response has been received from the server, or false otherwise.