]> git.ipfire.org Git - thirdparty/gnutls.git/commitdiff
*** empty log message ***
authorNikos Mavrogiannopoulos <nmav@gnutls.org>
Sat, 3 Jan 2004 09:36:47 +0000 (09:36 +0000)
committerNikos Mavrogiannopoulos <nmav@gnutls.org>
Sat, 3 Jan 2004 09:36:47 +0000 (09:36 +0000)
lib/gnutls.h.in.in
lib/x509/compat.c
libextra/gnutls_openpgp.c
libextra/openpgp/gnutls_openpgp.h
src/cli.c

index 8cbfb749c97980c4fb968ab558e7058b4d847d90..7c4cceeac1b3a8ace638ba3dc188665f7e67e77a 100644 (file)
@@ -145,7 +145,8 @@ typedef enum gnutls_openpgp_key_status { GNUTLS_OPENPGP_KEY,
 
 typedef enum gnutls_close_request { GNUTLS_SHUT_RDWR=0, GNUTLS_SHUT_WR=1 } gnutls_close_request;
 
-typedef enum gnutls_protocol_version { GNUTLS_SSL3=1, GNUTLS_TLS1,
+#define GNUTLS_TLS1 GNUTLS_TLS1_0
+typedef enum gnutls_protocol_version { GNUTLS_SSL3=1, GNUTLS_TLS1_0,
        GNUTLS_TLS1_1 } gnutls_protocol_version;
 
 typedef enum gnutls_certificate_type { GNUTLS_CRT_X509=1, GNUTLS_CRT_OPENPGP 
index ac9e33c901c37b80b20a6c0382a879690fe1323b..00fcd4629a5bfabbed7c6558c2ddd9e59161c9fa 100644 (file)
@@ -31,7 +31,6 @@
 #include <dn.h>
 #include <libtasn1.h>
 #include <gnutls/x509.h>
-#include <gnutls/compat8.h>
 
 /**
   * gnutls_x509_extract_certificate_activation_time - This function returns the peer's certificate activation time
@@ -42,7 +41,7 @@
   * Returns a (time_t) -1 in case of an error.
   *
   **/
-time_t gnutls_x509_extract_certificate_activation_time(const
+time_t _gnutls_x509_get_raw_crt_activation_time(const
                                                          gnutls_datum *
                                                          cert)
 {
@@ -74,7 +73,7 @@ time_t gnutls_x509_extract_certificate_activation_time(const
   * Returns a (time_t) -1 in case of an error.
   *
   **/
-time_t gnutls_x509_extract_certificate_expiration_time(const
+time_t _gnutls_x509_get_raw_crt_expiration_time(const
                                                          gnutls_datum *
                                                          cert)
 {
index 4ba3061bcb00b17b881106935b2f99a95bdf39f5..e510fbda7207cd2e96e43918c6654fefda562a93 100644 (file)
@@ -28,7 +28,6 @@
 #include <openpgp/gnutls_openpgp.h>
 
 #ifdef HAVE_LIBOPENCDK
-#include <gnutls/compat8.h>
 #include <strfile.h>
 #include <gnutls_str.h>
 #include <stdio.h>
index 7b526144b1e0f34db5e2db6bda08b9621a47fea3..4d21e160c78676f675d018a8ab5485b5e9cdb7e5 100644 (file)
@@ -5,7 +5,6 @@
 #ifndef GNUTLS_OPENPGP_H
 #define GNUTLS_OPENPGP_H
 
-#include <gnutls/compat8.h>
 #include <auth_cert.h>
 #include <opencdk.h>
 
index db98a7dc27f5e9b0c8b60524acfce68b1eddcc1c..52a43cb71b50d7cc7378538881a61a21e62d7d3c 100644 (file)
--- a/src/cli.c
+++ b/src/cli.c
@@ -74,7 +74,7 @@ static gnutls_srp_client_credentials srp_cred;
 static gnutls_anon_client_credentials anon_cred;
 static gnutls_certificate_credentials xcred;
 
-int protocol_priority[PRI_MAX] = { GNUTLS_TLS1, GNUTLS_SSL3, 0 };
+int protocol_priority[PRI_MAX] = { GNUTLS_TLS1_1, GNUTLS_TLS1, GNUTLS_SSL3, 0 };
 int kx_priority[PRI_MAX] =
     { GNUTLS_KX_RSA, GNUTLS_KX_DHE_DSS, GNUTLS_KX_DHE_RSA, GNUTLS_KX_SRP,
        /* Do not use anonymous authentication, unless you know what that means */
@@ -677,10 +677,14 @@ static int do_handshake(socket_st * socket)
 static int srp_username_callback( gnutls_session session, unsigned int times,
        char** username, char** password)
 {
+       if (srp_username == NULL || srp_passwd ==NULL) {
+               return -1;
+       }
+
        /* We should ask here the user for his SRP username
         * and password.
         */
-       if (times == 1 && srp_username && srp_passwd) {
+       if (times == 1) {
                *username = gnutls_strdup( srp_username);
                *password = gnutls_strdup( srp_passwd);