Mailinglist Archive: opensuse-commit (2092 mails)

< Previous Next >
commit gnutls
  • From: root@xxxxxxxxxxxxxxx (h_root)
  • Date: Fri, 03 Aug 2007 16:29:05 +0200
  • Message-id: <20070803142905.B3248678331@xxxxxxxxxxxxxxx>

Hello community,

here is the log from the commit of package gnutls
checked in at Fri Aug 3 16:29:05 CEST 2007.

--------
--- gnutls/gnutls.changes       2007-05-10 17:29:10.000000000 +0200
+++ /mounts/work_src_done/STABLE/gnutls/gnutls.changes  2007-08-03 14:05:54.000000000 +0200
@@ -1,0 +2,5 @@
+Fri Aug  3 13:54:37 CEST 2007 - hvogel@xxxxxxx
+
+- Some additions for evolution smart card support
+
+-------------------------------------------------------------------

New:
----
  gnutls-1.4.4-sign-callback.patch

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ gnutls.spec ++++++
--- /var/tmp/diff_new_pack.ZX4165/_old  2007-08-03 16:28:22.000000000 +0200
+++ /var/tmp/diff_new_pack.ZX4165/_new  2007-08-03 16:28:22.000000000 +0200
@@ -13,13 +13,14 @@
 Name:           gnutls
 BuildRequires:  gcc-c++ libgcrypt-devel libopencdk-devel lzo-devel
 Version:        1.6.1
-Release:        8
-License:        GNU General Public License (GPL)
+Release:        25
+License:        GPL v2 or later
 BuildRoot:      %{_tmppath}/%{name}-%{version}-build
 URL:            http://www.gnutls.org/
 Source0:        %name-%version.tar.bz2
 Patch0:         gnutls-char-signedness.patch
 Patch1:         gnutls-fix_size_t.patch
+Patch2:         gnutls-1.4.4-sign-callback.patch
 Summary:        The GNU Transport Layer Security Library
 Group:          Productivity/Networking/Security
 Autoreqprov:    on
@@ -41,7 +42,7 @@
 
 %package devel
 Summary:        Development package for gnutls
-Group:          Productivity/Networking/Security
+Group:          Development/Libraries/C and C++
 Requires:       %name = %version glibc-devel libopencdk-devel libgcrypt-devel libgpg-error-devel zlib-devel lzo-devel 
 
 %description devel
@@ -60,6 +61,7 @@
 %setup -q
 %patch0
 %patch1 -p1
+%patch2 -p1
 
 %build
 autoreconf -fi
@@ -77,6 +79,7 @@
 make DESTDIR=$RPM_BUILD_ROOT install
 rm -rf doc/examples/.deps doc/examples/.libs doc/examples/*.{o,lo,la} doc/examples/Makefile{,.in}
 find doc/examples -perm -111 -exec rm {} \;
+%find_lang %name
 
 %clean
 rm -rf %buildroot
@@ -93,7 +96,7 @@
 %postun devel
 %install_info_delete --info-dir=%{_infodir} %{_infodir}/gnutls.info.gz
 
-%files
+%files -f %name.lang
 %defattr(-, root, root)
 %doc THANKS README NEWS ChangeLog COPYING.LIB COPYING AUTHORS doc/TODO
 %_bindir/certtool
@@ -105,8 +108,6 @@
 %_libdir/*.so.*
 %_mandir/man1/*
 
-%_usr/share/locale/*/*/%{name}.mo
-
 %files devel
 %defattr(-, root, root)
 %_bindir/libgnutls-config
@@ -123,6 +124,8 @@
 %doc doc/examples doc/gnutls.html doc/*.png doc/gnutls.pdf doc/reference/html/*
 
 %changelog
+* Fri Aug 03 2007 - hvogel@xxxxxxx
+- Some additions for evolution smart card support
 * Thu May 10 2007 - mkoenig@xxxxxxx
 - Fix segfault on s390x [#97441]
   gnutls-fix_size_t.patch

++++++ gnutls-1.4.4-sign-callback.patch ++++++
--- gnutls-1.4.4/includes/gnutls/gnutls.h.in~   2007-03-06 10:58:32.000000000 -0500
+++ gnutls-1.4.4/includes/gnutls/gnutls.h.in    2007-03-08 14:59:14.000000000 -0500
@@ -970,6 +970,14 @@ extern "C"
     (gnutls_certificate_credentials_t cred,
      gnutls_certificate_server_retrieve_function * func);
 
+  typedef int gnutls_certificate_client_sign_function (gnutls_datum_t * cert,
+                                                       gnutls_certificate_type_t cert_type,
+                                                       const gnutls_datum_t *hash_concat,
+                                                       gnutls_datum_t * signature);
+  void gnutls_certificate_client_set_sign_function
+    (gnutls_certificate_credentials_t cred,
+     gnutls_certificate_client_sign_function * func);
+
   void gnutls_certificate_server_set_request (gnutls_session_t session,
                                              gnutls_certificate_request_t
                                              req);
--- gnutls-1.4.4/lib/auth_cert.h~       2006-03-08 05:44:59.000000000 -0500
+++ gnutls-1.4.4/lib/auth_cert.h        2007-03-08 14:37:10.000000000 -0500
@@ -95,6 +95,7 @@ typedef struct gnutls_certificate_creden
 
   gnutls_certificate_client_retrieve_function *client_get_cert_callback;
   gnutls_certificate_server_retrieve_function *server_get_cert_callback;
+  gnutls_certificate_client_sign_function *client_sign_callback;
 } certificate_credentials_st;
 
 typedef struct rsa_info_st
--- gnutls-1.4.4/lib/gnutls_cert.c~     2006-03-21 11:11:25.000000000 -0500
+++ gnutls-1.4.4/lib/gnutls_cert.c      2007-03-08 15:13:28.000000000 -0500
@@ -363,6 +363,12 @@ void gnutls_certificate_server_set_retri
   cred->server_get_cert_callback = func;
 }
 
+void gnutls_certificate_client_set_sign_function
+    (gnutls_certificate_credentials_t cred,
+     gnutls_certificate_client_sign_function * func)
+{
+    cred->client_sign_callback = func;
+}
 
 /* These are set by the gnutls_extra library's initialization function.
  */
--- gnutls-1.4.4/lib/auth_cert.c~       2006-06-28 05:06:09.000000000 -0400
+++ gnutls-1.4.4/lib/auth_cert.c        2007-03-08 15:01:28.000000000 -0500
@@ -1301,20 +1301,25 @@ _gnutls_gen_cert_client_cert_vrfy (gnutl
       return ret;
     }
 
-  if (apr_pkey != NULL)
+  if (apr_pkey == NULL)
     {
-      if ((ret =
-          _gnutls_tls_sign_hdata (session,
-                                  &apr_cert_list[0],
-                                  apr_pkey, &signature)) < 0)
-       {
-         gnutls_assert ();
-         return ret;
-       }
-    }
-  else
+      gnutls_certificate_credentials_t cred;
+      cred = (gnutls_certificate_credentials_t)
+          _gnutls_get_cred (session->key, GNUTLS_CRD_CERTIFICATE, NULL);
+
+      if (cred == NULL || cred->client_sign_callback == NULL)
+        {
+          return 0;
+        }
+    }
+
+  if ((ret =
+       _gnutls_tls_sign_hdata (session,
+                               &apr_cert_list[0],
+                               apr_pkey, &signature)) < 0)
     {
-      return 0;
+      gnutls_assert ();
+      return ret;
     }
 
   *data = gnutls_malloc (signature.size + 2);
--- gnutls-1.4.4/lib/gnutls_sig.c~      2006-03-08 05:44:59.000000000 -0500
+++ gnutls-1.4.4/lib/gnutls_sig.c       2007-03-08 15:06:52.000000000 -0500
@@ -57,6 +57,7 @@ _gnutls_tls_sign_hdata (gnutls_session_t
   mac_hd_t td_md5;
   mac_hd_t td_sha;
   gnutls_protocol_t ver = gnutls_protocol_get_version (session);
+  gnutls_certificate_credentials_t cred;
 
   td_sha = _gnutls_hash_copy (session->internals.handshake_mac_handle_sha);
   if (td_sha == NULL)
@@ -111,7 +112,15 @@ _gnutls_tls_sign_hdata (gnutls_session_t
       gnutls_assert ();
       return GNUTLS_E_INTERNAL_ERROR;
     }
-  ret = _gnutls_tls_sign (cert, pkey, &dconcat, signature);
+
+  cred = (gnutls_certificate_credentials_t)
+      _gnutls_get_cred (session->key, GNUTLS_CRD_CERTIFICATE, NULL);
+
+  if (cred != NULL && cred->client_sign_callback != NULL)
+      ret = cred->client_sign_callback (&cert->raw, cert->cert_type, &dconcat, signature);
+  else
+      ret = _gnutls_tls_sign (cert, pkey, &dconcat, signature);
+
   if (ret < 0)
     {
       gnutls_assert ();
--- gnutls-1.4.4/includes/gnutls/gnutls.h.in~   2007-03-09 12:48:09.000000000 -0500
+++ gnutls-1.4.4/includes/gnutls/gnutls.h.in    2007-03-09 12:48:48.000000000 -0500
@@ -970,7 +970,8 @@ extern "C"
     (gnutls_certificate_credentials_t cred,
      gnutls_certificate_server_retrieve_function * func);
 
-  typedef int gnutls_certificate_client_sign_function (gnutls_datum_t * cert,
+  typedef int gnutls_certificate_client_sign_function (gnutls_session_t session,
+                                                       gnutls_datum_t * cert,
                                                        gnutls_certificate_type_t cert_type,
                                                        const gnutls_datum_t *hash_concat,
                                                        gnutls_datum_t * signature);
--- gnutls-1.4.4/lib/gnutls_sig.c~      2007-03-09 12:50:46.000000000 -0500
+++ gnutls-1.4.4/lib/gnutls_sig.c       2007-03-09 12:51:15.000000000 -0500
@@ -117,7 +117,9 @@ _gnutls_tls_sign_hdata (gnutls_session_t
       _gnutls_get_cred (session->key, GNUTLS_CRD_CERTIFICATE, NULL);
 
   if (cred != NULL && cred->client_sign_callback != NULL)
-      ret = cred->client_sign_callback (&cert->raw, cert->cert_type, &dconcat, signature);
+      ret = cred->client_sign_callback (session,
+                                        &cert->raw, cert->cert_type,
+                                        &dconcat, signature);
   else
       ret = _gnutls_tls_sign (cert, pkey, &dconcat, signature);
 
--- gnutls-1.4.4/lib/auth_cert.c~       2007-03-12 12:48:09.000000000 -0400
+++ gnutls-1.4.4/lib/auth_cert.c        2007-03-13 14:52:42.000000000 -0400
@@ -1301,6 +1301,11 @@ _gnutls_gen_cert_client_cert_vrfy (gnutl
       return ret;
     }
 
+  if (apr_cert_list_length == 0)
+    {
+      return 0;
+    }
+
   if (apr_pkey == NULL)
     {
       gnutls_certificate_credentials_t cred;

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++



Remember to have fun...

---------------------------------------------------------------------
To unsubscribe, e-mail: opensuse-commit+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: opensuse-commit+help@xxxxxxxxxxxx

< Previous Next >
This Thread