cleanup
authorColin Leroy <colin@colino.net>
Mon, 9 Dec 2002 13:25:33 +0000 (13:25 +0000)
committerColin Leroy <colin@colino.net>
Mon, 9 Dec 2002 13:25:33 +0000 (13:25 +0000)
ChangeLog.claws
configure.in
src/common/ssl_certificate.c

index 43c80ac008e5f346ec696eb6cc4a0d38568bdae6..a965fb089ef8add967fb10e74fbe670024403f09 100644 (file)
@@ -1,3 +1,8 @@
+2002-12-09 [colin]     0.8.6claws87
+
+       * src/ssl_certificate.c
+               cleanup
+
 2002-12-09 [colin]     0.8.6claws86
 
        * src/ssl.c
index 3de924db81551d1a26afaed95ef415646bf7c01d..9bd30e3f06ce88309dcd5b8417ee5d2e5898300c 100644 (file)
@@ -11,7 +11,7 @@ MINOR_VERSION=8
 MICRO_VERSION=6
 INTERFACE_AGE=0
 BINARY_AGE=0
-EXTRA_VERSION=claws86
+EXTRA_VERSION=claws87
 VERSION=$MAJOR_VERSION.$MINOR_VERSION.$MICRO_VERSION$EXTRA_VERSION
 
 dnl set $target
index fff5d117ce81acd87a9d7cbd448ba4f097522804..837d0b49d8233edcb92e8c83b715e6b91d76d52f 100644 (file)
@@ -296,7 +296,6 @@ char *ssl_certificate_check_signer (X509 *cert)
        X509_STORE_CTX store_ctx;
        X509_STORE *store;
        int ok = 0;
-       char *cert_file = NULL;
        char *err_msg = NULL;
 
        store = X509_STORE_new();
@@ -304,20 +303,14 @@ char *ssl_certificate_check_signer (X509 *cert)
                printf("Can't create X509_STORE\n");
                return NULL;
        }
-       if (X509_STORE_set_default_paths(store)) 
-               ok++;
-       if (X509_STORE_load_locations(store, cert_file, NULL))
-               ok++;
-
-       if (ok == 0) {
+       if (!X509_STORE_set_default_paths(store)) {
                X509_STORE_free (store);
                return g_strdup(_("Can't load X509 default paths"));
        }
        
        X509_STORE_CTX_init (&store_ctx, store, cert, NULL);
-       ok = X509_verify_cert (&store_ctx);
-       
-       if (ok == 0) {
+
+       if(!X509_verify_cert (&store_ctx)) {
                err_msg = g_strdup(X509_verify_cert_error_string(
                                        X509_STORE_CTX_get_error(&store_ctx)));
                debug_print("Can't check signer: %s\n", err_msg);