summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexander Vershilov <qnikst@gentoo.org>2012-11-01 15:52:28 +0000
committerAlexander Vershilov <qnikst@gentoo.org>2012-11-01 15:52:28 +0000
commitb7d4cc42602a5116a499a7b08aa8e73032f35572 (patch)
tree2f68b1876a28b0c400ecc08d8ce2594b02a77169 /net-libs/neon
parentmask useflags requiring dev-ml/ocamlduce so that we can mask it and unmask oc... (diff)
downloadhistorical-b7d4cc42602a5116a499a7b08aa8e73032f35572.tar.gz
historical-b7d4cc42602a5116a499a7b08aa8e73032f35572.tar.bz2
historical-b7d4cc42602a5116a499a7b08aa8e73032f35572.zip
fix gnutls-3 breakage #421441, thanks to Bartosz Brachaczek
Package-Manager: portage-2.2.0_alpha142/cvs/Linux x86_64
Diffstat (limited to 'net-libs/neon')
-rw-r--r--net-libs/neon/ChangeLog7
-rw-r--r--net-libs/neon/Manifest16
-rw-r--r--net-libs/neon/files/neon-0.29.6-gnutls-3-functions.patch120
-rw-r--r--net-libs/neon/files/neon-0.29.6-gnutls-3-types.patch57
-rw-r--r--net-libs/neon/neon-0.29.6-r1.ebuild4
5 files changed, 190 insertions, 14 deletions
diff --git a/net-libs/neon/ChangeLog b/net-libs/neon/ChangeLog
index 0c44ca99beb2..2e1331d266d4 100644
--- a/net-libs/neon/ChangeLog
+++ b/net-libs/neon/ChangeLog
@@ -1,6 +1,11 @@
# ChangeLog for net-libs/neon
# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-libs/neon/ChangeLog,v 1.44 2012/09/05 19:43:54 floppym Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-libs/neon/ChangeLog,v 1.45 2012/11/01 15:52:27 qnikst Exp $
+
+ 01 Nov 2012; Alexander Vershilov <qnikst@gentoo.org>
+ +files/neon-0.29.6-gnutls-3-functions.patch,
+ +files/neon-0.29.6-gnutls-3-types.patch, neon-0.29.6-r1.ebuild:
+ fix gnutls-3 breakage #421441, thanks to Bartosz Brachaczek
05 Sep 2012; Mike Gilbert <floppym@gentoo.org> neon-0.29.6-r1.ebuild:
Fix handling of EPREFIX with whitespace. Patch by Arfrever.
diff --git a/net-libs/neon/Manifest b/net-libs/neon/Manifest
index 0388e7c338e7..e637995f5f1f 100644
--- a/net-libs/neon/Manifest
+++ b/net-libs/neon/Manifest
@@ -1,15 +1,7 @@
------BEGIN PGP SIGNED MESSAGE-----
-Hash: SHA256
-
+AUX neon-0.29.6-gnutls-3-functions.patch 4867 SHA256 3d1e50fe2fc79e92e42acbab179a41e9c1c0f96d6f72c19a9f650eebc1f1bd11 SHA512 d278085db6d0d75db67881bedc11c323317a28e70a0f474a5c4d29f1b0d96f4cef2a59d4af1dbfed175e496b091f3dbb9f604d67a45d11638bc1a597729b8e73 WHIRLPOOL 78e40d87f6ad1f0754b566a43700e50934e954f460b6b4c5f704ca7da67af123018b0eb8939a4ff3ab421d937a2007089408be07fb6a995c8946269850ca0db3
+AUX neon-0.29.6-gnutls-3-types.patch 1996 SHA256 1a2aabc6183abe942d5cf547a6f3dd2f28ba98b3e709f718527ba0d9c6969ae3 SHA512 7a139c36329f1125007184da4c50dbe50747486336835e67601033be82ed8ad0838d7af05f9737c8849c76cad0ec4494fffb8390062c268ae747a41a7ac7773d WHIRLPOOL b1432084f5726cfa8460876d99742366238e5d063b86088793d4d80945cd6b6a913a682c05204cab13bfffeabeaff81a9b0e552961811c4d07610a339c28cfa5
AUX neon-0.29.6-no-ssl-check.patch 834 SHA256 4377b91e901c61feb9ddecc0160cda6717fe24d6caeac8c912ec19a71565bd0e SHA512 36577a6da214e0b354ab646ec678b58d30a56680d8dad1a325025f844b487c58768778da4ac9f6e86e327f5b849c0cc538824672aff5eb611adb11631f03f4f5 WHIRLPOOL 973a2de0606ec2749d174b4dfb1e9ae615c4d3941d6e065e9c3c6df820d64245a8b239166770e187a3d7bac2e0d046edf27bfe938441f4c5e0a43c3aa30a4691
DIST neon-0.29.6.tar.gz 882267 SHA256 9c640b728d6dc80ef1e48f83181166ab6bc95309cece5537e01ffdd01b96eb43 SHA512 26424f30936170a28fdb0188e10985c2b0e1e4266c4c1832384a02b69828741eb1370015646656f979cc74f2fd6a092d0d32bca401c04939b9890db3fb696260 WHIRLPOOL 8b77ed8a52eec1993b41d19963252ce2637c3ff1e21fbbdfd54a8416fff4f9827d03827e51ca3712a92dc529ed329444b4ce3603f547a66420e9a2b750017b03
-EBUILD neon-0.29.6-r1.ebuild 2768 SHA256 9a2ee4a1f2b8b28932333d3b6ac5df45b4298ad082b14ea53a55c097a819f106 SHA512 93841db8776377dcd49c7fb4e0fe1515d44b45316d0ce7034b6e4e81b827df34f6a6a1d9b7fb69ea909d8eb20aa3fd7ba8d4e8c3ffa7bb6ffe0cb090dd01dbdb WHIRLPOOL ff916935b4c56a57a0150ab6d500dc12af6cb3296d610b51dee863444c7212e5c56c4464bba188bd4859155c2dd40204ca89b1a8e5226d00cf75a1d0629dff1a
-MISC ChangeLog 25303 SHA256 c9459eaf9a2146a0ce2b14350cd8b40bba397a314f6fbed771583bdf88a21ebc SHA512 6fdf8e6218dda61ade6d76e9759f69989d261257816efbb603db363c62b5a716aff001853ecb1b1073d316ab23b8bb2f773bb1bc2f2a5d160169fb2bd834bf64 WHIRLPOOL cdb780712b75a400c88a76335921388ee5bf6f799d16e171d02d937b48a72dbb20fb41f2b6022dfb649828b3b8e134464e4b37fc20abbbeb28136ea507814883
+EBUILD neon-0.29.6-r1.ebuild 2883 SHA256 ed2805a8362fdfd90d5d4d2cdca2bf5bf1b1c90ef9a0a807657f06188868e2a2 SHA512 d425f25b8d716c1a82b1e929737eeb2f1bd6f468fb1abefb9e4888256e1bd2c344ff370a01cc1ba84554f6fd454aa04ba48fc16b59a72906d9b4c3e585e3e5f3 WHIRLPOOL 68ab92026645dd2fb345106c0744ddb15f86e6542b130269eb9d639531400dfcfccf97d57d44c349670fc4b899e41e17dae2deb9e6e731315b41c0b873808d57
+MISC ChangeLog 25533 SHA256 f78a62ad5142a7b3c89b5e851006b9cb6312f4b37ca1e03c8eed907e05205abd SHA512 5b10c409a01bb4c6dcdcb34fb009e6a16443abcf8195d25b433c16a4ce2ab3cc374c03b125e1d437c9c9c7256de2b3e45ccfb0cc0bdc92e655ee072206a393e1 WHIRLPOOL acaf4b5b61d701e9812fb3e609a6dd8540394dc6c3587969cffa4333b0e5fbc1d1da7ef55db0784a5f89a37a742d6cae05c5b28e24e130f464c3b4a29876552b
MISC metadata.xml 1208 SHA256 2697b773cf5d2673a1bfd349724f0ef0a70ecea111713373ba348cee6e075ca1 SHA512 e08f9806282d877c9db6ae6c08aac05c3c0e2104338117d4047a9e31afca5dd0b648b5acd6410477960516cf27788e0c41c108995192231a5aa2676beac23934 WHIRLPOOL fc07bf5d350a6225788567f0fb0adb5e8caf2ce3e20af586236fec938d784d8218cd9d6d426ba6623f544b5f34d07274e1d008be78048e67f366a7db2fcc1e39
------BEGIN PGP SIGNATURE-----
-Version: GnuPG v2.0.19 (GNU/Linux)
-
-iF4EAREIAAYFAlBHq4AACgkQC77qH+pIQ6R/JAEAw7/KXUofSUqZxQXzmCuBf/Sz
-+76RUPuupyRWDq1HQ2UA/ikcVOq5tsbjp5Xz6unGjdz/iZOLXrTYQJ5jsPnOISDm
-=SBBF
------END PGP SIGNATURE-----
diff --git a/net-libs/neon/files/neon-0.29.6-gnutls-3-functions.patch b/net-libs/neon/files/neon-0.29.6-gnutls-3-functions.patch
new file mode 100644
index 000000000000..77fe9320228d
--- /dev/null
+++ b/net-libs/neon/files/neon-0.29.6-gnutls-3-functions.patch
@@ -0,0 +1,120 @@
+From d7516e56dc854308349419b81904e9a61751cde4 Mon Sep 17 00:00:00 2001
+From: Alexander V Vershilov <alexander.vershilov@gmail.com>
+Date: Thu, 1 Nov 2012 11:44:10 +0400
+Subject: [PATCH 1/2] neon gnutls-3 fixes
+
+---
+ macros/neon.m4 | 9 ++++++++-
+ src/ne_gnutls.c | 13 +++++++++++--
+ src/ne_socket.c | 10 +++++++---
+ 3 files changed, 26 insertions(+), 6 deletions(-)
+
+diff --git a/macros/neon.m4 b/macros/neon.m4
+index 32111c7..40f1d71 100644
+--- a/macros/neon.m4
++++ b/macros/neon.m4
+@@ -982,13 +982,20 @@ gnutls)
+ # Check for functions in later releases
+ NE_CHECK_FUNCS([gnutls_session_get_data2 gnutls_x509_dn_get_rdn_ava \
+ gnutls_sign_callback_set \
++ gnutls_certificate_get_issuer \
+ gnutls_certificate_get_x509_cas \
+- gnutls_certificate_verify_peers2])
++ gnutls_certificate_verify_peers2 \
++ gnutls_x509_crt_sign2])
+
+ # fail if gnutls_certificate_verify_peers2 is not found
+ if test x${ac_cv_func_gnutls_certificate_verify_peers2} != xyes; then
+ AC_MSG_ERROR([GnuTLS version predates gnutls_certificate_verify_peers2, newer version required])
+ fi
++
++ # fail if gnutls_x509_crt_sign2 is not found (it was introduced in 1.2.0, which is required)
++ if test x${ac_cv_func_gnutls_x509_crt_sign2} != xyes; then
++ AC_MSG_ERROR([GnuTLS version predates gnutls_x509_crt_sign2, newer version required (at least 1.2.0)])
++ fi
+
+ # Check for iconv support if using the new RDN access functions:
+ if test ${ac_cv_func_gnutls_x509_dn_get_rdn_ava}X${ac_cv_header_iconv_h} = yesXyes; then
+diff --git a/src/ne_gnutls.c b/src/ne_gnutls.c
+index eec5655..d50c6ce 100644
+--- a/src/ne_gnutls.c
++++ b/src/ne_gnutls.c
+@@ -692,7 +692,7 @@ void ne_ssl_context_destroy(ne_ssl_context *ctx)
+ ne_free(ctx);
+ }
+
+-#ifdef HAVE_GNUTLS_CERTIFICATE_GET_X509_CAS
++#if !defined(HAVE_GNUTLS_CERTIFICATE_GET_ISSUER) && defined(HAVE_GNUTLS_CERTIFICATE_GET_X509_CAS)
+ /* Return the issuer of the given certificate, or NULL if none can be
+ * found. */
+ static gnutls_x509_crt find_issuer(gnutls_x509_crt *ca_list,
+@@ -747,20 +747,29 @@ static ne_ssl_certificate *make_peers_chain(gnutls_session sock,
+ }
+ }
+
+-#ifdef HAVE_GNUTLS_CERTIFICATE_GET_X509_CAS
++#if defined(HAVE_GNUTLS_CERTIFICATE_GET_ISSUER) || defined(HAVE_GNUTLS_CERTIFICATE_GET_X509_CAS)
+ /* GnuTLS only returns the peers which were *sent* by the server
+ * in the Certificate list during the handshake. Fill in the
+ * complete chain manually against the certs we trust: */
+ if (current->issuer == NULL) {
+ gnutls_x509_crt issuer;
++
++#ifndef HAVE_GNUTLS_CERTIFICATE_GET_ISSUER
+ gnutls_x509_crt *ca_list;
+ unsigned int num_cas;
+
+ gnutls_certificate_get_x509_cas(crd, &ca_list, &num_cas);
++#endif
+
+ do {
+ /* Look up the issuer. */
++#ifndef HAVE_GNUTLS_CERTIFICATE_GET_ISSUER
+ issuer = find_issuer(ca_list, num_cas, current->subject);
++#else
++ if (gnutls_certificate_get_issuer(crd, current->subject, &issuer, 0))
++ issuer = NULL;
++#endif
++
+ if (issuer) {
+ issuer = x509_crt_copy(issuer);
+ cert = populate_cert(ne_calloc(sizeof *cert), issuer);
+diff --git a/src/ne_socket.c b/src/ne_socket.c
+index 12cf020..faee20c 100644
+--- a/src/ne_socket.c
++++ b/src/ne_socket.c
+@@ -721,9 +721,11 @@ static ssize_t error_gnutls(ne_socket *sock, ssize_t sret)
+ _("SSL alert received: %s"),
+ gnutls_alert_get_name(gnutls_alert_get(sock->ssl)));
+ break;
++#if GNUTLS_VERSION_MAJOR > 2 || (GNUTLS_VERSION_MAJOR == 2 && GNUTLS_VERSION_MINOR >= 99)
++ case GNUTLS_E_PREMATURE_TERMINATION:
++#else
+ case GNUTLS_E_UNEXPECTED_PACKET_LENGTH:
+- /* It's not exactly an API guarantee but this error will
+- * always mean a premature EOF. */
++#endif
+ ret = NE_SOCK_TRUNC;
+ set_error(sock, _("Secure connection truncated"));
+ break;
+@@ -1678,6 +1680,8 @@ int ne_sock_accept_ssl(ne_socket *sock, ne_ssl_context *ctx)
+ NE_DEBUG(NE_DBG_SSL, "ssl: Server reused session.\n");
+ }
+ #elif defined(HAVE_GNUTLS)
++ unsigned int verify_status;
++
+ gnutls_init(&ssl, GNUTLS_SERVER);
+ gnutls_credentials_set(ssl, GNUTLS_CRD_CERTIFICATE, ctx->cred);
+ gnutls_set_default_priority(ssl);
+@@ -1697,7 +1701,7 @@ int ne_sock_accept_ssl(ne_socket *sock, ne_ssl_context *ctx)
+ if (ret < 0) {
+ return error_gnutls(sock, ret);
+ }
+- if (ctx->verify && gnutls_certificate_verify_peers(ssl)) {
++ if (ctx->verify && (gnutls_certificate_verify_peers2(ssl, &verify_status) || verify_status)) {
+ set_error(sock, _("Client certificate verification failed"));
+ return NE_SOCK_ERROR;
+ }
+--
+1.7.12.3
+
diff --git a/net-libs/neon/files/neon-0.29.6-gnutls-3-types.patch b/net-libs/neon/files/neon-0.29.6-gnutls-3-types.patch
new file mode 100644
index 000000000000..861207d4b600
--- /dev/null
+++ b/net-libs/neon/files/neon-0.29.6-gnutls-3-types.patch
@@ -0,0 +1,57 @@
+From 9033b72dc4fa250519379cb39142a3e42141d3f5 Mon Sep 17 00:00:00 2001
+From: Alexander V Vershilov <alexander.vershilov@gmail.com>
+Date: Thu, 1 Nov 2012 11:44:36 +0400
+Subject: [PATCH 2/2] neon gnutls types fix
+
+---
+ src/ne_gnutls.c | 10 +++++-----
+ 1 file changed, 5 insertions(+), 5 deletions(-)
+
+diff --git a/src/ne_gnutls.c b/src/ne_gnutls.c
+index d50c6ce..11dfd8e 100644
+--- a/src/ne_gnutls.c
++++ b/src/ne_gnutls.c
+@@ -83,7 +83,7 @@ struct ne_ssl_certificate_s {
+ };
+
+ struct ne_ssl_client_cert_s {
+- gnutls_pkcs12 p12;
++ gnutls_pkcs12_t p12;
+ int decrypted; /* non-zero if successfully decrypted. */
+ int keyless;
+ ne_ssl_certificate cert;
+@@ -1041,11 +1041,11 @@ static int read_to_datum(const char *filename, gnutls_datum *datum)
+ /* Parses a PKCS#12 structure and loads the certificate, private key
+ * and friendly name if possible. Returns zero on success, non-zero
+ * on error. */
+-static int pkcs12_parse(gnutls_pkcs12 p12, gnutls_x509_privkey *pkey,
++static int pkcs12_parse(gnutls_pkcs12_t p12, gnutls_x509_privkey *pkey,
+ gnutls_x509_crt *x5, char **friendly_name,
+ const char *password)
+ {
+- gnutls_pkcs12_bag bag = NULL;
++ gnutls_pkcs12_bag_t bag = NULL;
+ int i, j, ret = 0;
+
+ for (i = 0; ret == 0; ++i) {
+@@ -1060,7 +1060,7 @@ static int pkcs12_parse(gnutls_pkcs12 p12, gnutls_x509_privkey *pkey,
+ gnutls_pkcs12_bag_decrypt(bag, password);
+
+ for (j = 0; ret == 0 && j < gnutls_pkcs12_bag_get_count(bag); ++j) {
+- gnutls_pkcs12_bag_type type;
++ gnutls_pkcs12_bag_type_t type;
+ gnutls_datum data;
+
+ if (friendly_name && *friendly_name == NULL) {
+@@ -1130,7 +1130,7 @@ ne_ssl_client_cert *ne_ssl_clicert_read(const char *filename)
+ {
+ int ret;
+ gnutls_datum data;
+- gnutls_pkcs12 p12;
++ gnutls_pkcs12_t p12;
+ ne_ssl_client_cert *cc;
+ char *friendly_name = NULL;
+ gnutls_x509_crt cert = NULL;
+--
+1.7.12.3
+
diff --git a/net-libs/neon/neon-0.29.6-r1.ebuild b/net-libs/neon/neon-0.29.6-r1.ebuild
index e4e9a90495fe..56b8a93c6417 100644
--- a/net-libs/neon/neon-0.29.6-r1.ebuild
+++ b/net-libs/neon/neon-0.29.6-r1.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2012 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-libs/neon/neon-0.29.6-r1.ebuild,v 1.14 2012/09/05 19:43:54 floppym Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-libs/neon/neon-0.29.6-r1.ebuild,v 1.15 2012/11/01 15:52:27 qnikst Exp $
EAPI="4"
@@ -47,6 +47,8 @@ src_prepare() {
sed -i -e "s/ALL_LINGUAS=.*/ALL_LINGUAS=\"${linguas}\"/g" configure.in
epatch "${FILESDIR}"/${PN}-0.29.6-no-ssl-check.patch
+ epatch "${FILESDIR}"/${PN}-0.29.6-gnutls-3-functions.patch
+ epatch "${FILESDIR}"/${PN}-0.29.6-gnutls-3-types.patch
AT_M4DIR="macros" eautoreconf
elibtoolize