changeset 20757:9c226e074462

merge of '4bbc209c8076ef89135700af844ec6bb04602c0a' and 'd2c7c4e1bf264ab31a0d42e7e61e316f2ad2a718'
author Luke Schierer <lschiere@pidgin.im>
date Tue, 02 Oct 2007 14:37:12 +0000
parents 61045691aa72 (current diff) 17e605dd2de1 (diff)
children 398bfc680c63 989f5906ca17
files
diffstat 3 files changed, 44 insertions(+), 10 deletions(-) [+]
line wrap: on
line diff
--- a/libpurple/certificate.c	Tue Oct 02 06:13:27 2007 +0000
+++ b/libpurple/certificate.c	Tue Oct 02 14:37:12 2007 +0000
@@ -88,6 +88,19 @@
 
 	g_return_if_fail(vrq);
 
+	if (st == PURPLE_CERTIFICATE_VALID) {
+		purple_debug_info("certificate",
+				  "Successfully verified certificate for %s\n",
+				  vrq->subject_name);
+	} else {
+		purple_debug_info("certificate",
+				  "Failed to verify certificate for %s\n",
+				  vrq->subject_name);
+	}
+		
+		
+		
+	
 	/* Pass the results on to the request's callback */
 	(vrq->cb)(st, vrq->cb_data);
 
@@ -1372,7 +1385,8 @@
 	purple_debug_info("certificate/x509/tls_cached",
 			  "Checking for a CA with DN=%s\n",
 			  ca_id);
-	if ( !purple_certificate_pool_contains(ca, ca_id) ) {
+	ca_crt = purple_certificate_pool_retrieve(ca, ca_id);
+	if ( NULL == ca_crt ) {
 		purple_debug_info("certificate/x509/tls_cached",
 				  "Certificate Authority with DN='%s' not "
 				  "found. I'll prompt the user, I guess.\n",
@@ -1385,16 +1399,7 @@
 		return;
 	}
 
-	ca_crt = purple_certificate_pool_retrieve(ca, ca_id);
 	g_free(ca_id);
-	if (!ca_crt) {
-		purple_debug_error("certificate/x509/tls_cached",
-				   "Certificate authority disappeared out "
-				   "underneath me!\n");
-		purple_certificate_verify_complete(vrq,
-						   PURPLE_CERTIFICATE_INVALID);
-		return;
-	}
 	
 	/* Check the signature */
 	if ( !purple_certificate_signed_by(end_crt, ca_crt) ) {
--- a/share/ca-certs/Makefile.am	Tue Oct 02 06:13:27 2007 +0000
+++ b/share/ca-certs/Makefile.am	Tue Oct 02 14:37:12 2007 +0000
@@ -2,6 +2,7 @@
 cacerts_DATA =	\
 		Equifax_Secure_CA.pem \
 		GTE_CyberTrust_Global_Root.pem \
+		Microsoft_Secure_Server_Authority.pem \
 		Verisign_RSA_Secure_Server_CA.pem \
 		Verisign_Class3_Primary_CA.pem
 
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/share/ca-certs/Microsoft_Secure_Server_Authority.pem	Tue Oct 02 14:37:12 2007 +0000
@@ -0,0 +1,28 @@
+-----BEGIN CERTIFICATE-----
+MIIE1TCCA72gAwIBAgIKYSsApAADAAAAFDANBgkqhkiG9w0BAQUFADAnMSUwIwYD
+VQQDExxNaWNyb3NvZnQgSW50ZXJuZXQgQXV0aG9yaXR5MB4XDTA2MDQyMTE5MTEw
+NFoXDTA5MDQxOTIzNTkwMFowgYsxEzARBgoJkiaJk/IsZAEZFgNjb20xGTAXBgoJ
+kiaJk/IsZAEZFgltaWNyb3NvZnQxFDASBgoJkiaJk/IsZAEZFgRjb3JwMRcwFQYK
+CZImiZPyLGQBGRYHcmVkbW9uZDEqMCgGA1UEAxMhTWljcm9zb2Z0IFNlY3VyZSBT
+ZXJ2ZXIgQXV0aG9yaXR5MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEA
+syn2tJzCJKsQy98cYrzBT0qMSqTMibRel34u64jqd1GKP9cRMHagyNLZIb1rv8NZ
+XPdf2uI8hGc4lxRh4iprbFPOZSiHQIyq9zoqLS7Bh/KnqnRX4CCntCQbWVa/s5c5
+FbGD5XG5AvA8sjn56WPotYLGeWrSZ/k2bcH9YgvQ2Yrt8t1VxPQciSuX82KSn2Kx
+xxJKgQtAgZpyekR5QdIUUvQsEAPaCfWRsF/OMQoyc4UeAxAELavr2vlq869ye3Fu
+f3fUhVEk8kxtiVPYWYBTAhWts62pEwaKGPteMsGnvbX+BRgIwc55vfs6KWXxnBUL
+9Q8BfQQLbT8nQe7hO4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