void empathy_tls_certificate_reject_async (EmpathyTLSCertificate *self, EmpTLSCertificateRejectReason reason, GHashTable *details, GAsyncReadyCallback callback, gpointer user_data) { GPtrArray *rejections; GSimpleAsyncResult *reject_result; g_assert (EMPATHY_IS_TLS_CERTIFICATE (self)); DEBUG ("Rejecting TLS certificate with reason %u", reason); rejections = build_rejections_array (reason, details); reject_result = g_simple_async_result_new (G_OBJECT (self), callback, user_data, empathy_tls_certificate_reject_async); emp_cli_authentication_tls_certificate_call_reject (TP_PROXY (self), -1, rejections, cert_proxy_reject_cb, reject_result, g_object_unref, G_OBJECT (self)); tp_clear_boxed (EMP_ARRAY_TYPE_TLS_CERTIFICATE_REJECTION_LIST, &rejections); }
EmpathyTLSVerifier * empathy_tls_verifier_new (EmpathyTLSCertificate *certificate, const gchar *hostname, const gchar **reference_identities) { g_assert (EMPATHY_IS_TLS_CERTIFICATE (certificate)); g_assert (hostname != NULL); g_assert (reference_identities != NULL); return g_object_new (EMPATHY_TYPE_TLS_VERIFIER, "certificate", certificate, "hostname", hostname, "reference-identities", reference_identities, NULL); }
GtkWidget * empathy_tls_dialog_new (EmpathyTLSCertificate *certificate, EmpTLSCertificateRejectReason reason, GHashTable *details) { g_assert (EMPATHY_IS_TLS_CERTIFICATE (certificate)); return g_object_new (EMPATHY_TYPE_TLS_DIALOG, "message-type", GTK_MESSAGE_WARNING, "certificate", certificate, "reason", reason, "details", details, NULL); }
void empathy_tls_certificate_accept_async (EmpathyTLSCertificate *self, GAsyncReadyCallback callback, gpointer user_data) { GSimpleAsyncResult *accept_result; g_assert (EMPATHY_IS_TLS_CERTIFICATE (self)); DEBUG ("Accepting TLS certificate"); accept_result = g_simple_async_result_new (G_OBJECT (self), callback, user_data, empathy_tls_certificate_accept_async); emp_cli_authentication_tls_certificate_call_accept (TP_PROXY (self), -1, cert_proxy_accept_cb, accept_result, g_object_unref, G_OBJECT (self)); }