]> git.0d.be Git - empathy.git/commitdiff
Save the certificate when we are told to remember
authorCosimo Cecchi <cosimoc@gnome.org>
Fri, 13 Aug 2010 14:15:17 +0000 (16:15 +0200)
committerCosimo Cecchi <cosimoc@gnome.org>
Fri, 13 Aug 2010 14:22:25 +0000 (16:22 +0200)
src/empathy-auth-helper.c

index 065fc8ded3c606f030ebfdad1d00354b9f0fbd63..7ed4596c2ffbad95f3c00b7c28d57d8bc50f13ec 100644 (file)
@@ -47,12 +47,14 @@ tls_dialog_response_cb (GtkDialog *dialog,
   EmpathyTLSCertificate *certificate = NULL;
   EmpTLSCertificateRejectReason reason = 0;
   EmpathyTLSDialog *tls_dialog = EMPATHY_TLS_DIALOG (dialog);
+  gboolean remember = FALSE;
 
   DEBUG ("Response %d", response_id);
 
   g_object_get (tls_dialog,
       "certificate", &certificate,
       "reason", &reason,
+      "remember", &remember,
       NULL);
 
   gtk_widget_destroy (GTK_WIDGET (dialog));
@@ -62,6 +64,9 @@ tls_dialog_response_cb (GtkDialog *dialog,
   else
     empathy_tls_certificate_reject (certificate, reason, TRUE);
 
+  if (remember)
+    empathy_tls_certificate_store_ca (certificate);
+
   g_object_unref (certificate);
 }