Mailinglist Archive: zypp-commit (233 mails)

< Previous Next >
[zypp-commit] <libzypp> SuSE-Code-11-Branch : Don't fail if installed libcurl4 does not provide CURLOPT_REDIR_PROTOCOLS (bnc #553895)
  • From: Michael Andres <ma@xxxxxxx>
  • Date: Wed, 11 Nov 2009 11:01:46 +0100
  • Message-id: <E1N8A3M-0002zw-H0@xxxxxxxxxxxxxxxx>
ref: refs/heads/SuSE-Code-11-Branch
commit 5fa5d89f17ceab81ec0a743a41eedaddf5bc7d33
Author: Michael Andres <ma@xxxxxxx>
Date: Wed Nov 11 11:01:46 2009 +0100

Don't fail if installed libcurl4 does not provide CURLOPT_REDIR_PROTOCOLS
(bnc #553895)
---
libzypp.spec.cmake | 4 ++--
zypp/media/MediaCurl.cc | 16 ++++++++++++++--
2 files changed, 16 insertions(+), 4 deletions(-)

diff --git a/libzypp.spec.cmake b/libzypp.spec.cmake
index be613bb..cfd7631 100644
--- a/libzypp.spec.cmake
+++ b/libzypp.spec.cmake
@@ -58,8 +58,8 @@ Requires: gnupg

%requires_eq satsolver-tools

-# need CURLOPT_REDIR_PROTOCOLS:
-%min_curl_version 7.19.4
+# need CURLOPT_REDIR_PROTOCOLS: oficially 7.19.4, code 11 backport 7.19.0-11.3
(-11.22 SLES)
+%define min_curl_version 7.19.0-11.3
Requires: libcurl4 >= %{min_curl_version}
BuildRequires: curl-devel >= %{min_curl_version}

diff --git a/zypp/media/MediaCurl.cc b/zypp/media/MediaCurl.cc
index 2908f3b..4a414fc 100644
--- a/zypp/media/MediaCurl.cc
+++ b/zypp/media/MediaCurl.cc
@@ -446,8 +446,20 @@ void MediaCurl::attachTo (bool next)
// restrict following of redirections from https to https only
ret = curl_easy_setopt ( _curl, CURLOPT_REDIR_PROTOCOLS, CURLPROTO_HTTPS );
if ( ret != 0) {
- disconnectFrom();
- ZYPP_THROW(MediaCurlSetOptException(_url, _curlError));
+ // bnc #553895
+ // Actually libzypp had to reqire the specific libcurl4 version that
+ // introduced CURLOPT_REDIR_PROTOCOLS (officially 7.19.4; in code11
+ // introduced by a security backport in 7.19.0-11.22(SLE),
-11.3(openSUSE))
+ //
+ // Autobuild faces the problem that the release numbers for SLE11 and
+ // openSUSE-11.1 are not in sync (-11.22 vs. -11.3), but on the other
+ // hand they don't allow us to test whether a package is built for
+ // SLES-11 or openSUSE-11.
+ //
+ // If we can't require the correct version, we must ignore the return
value.
+ SEC << "Set CURLOPT_REDIR_PROTOCOLS failed: You should update to the
latest libcurl4 version." << endl;
+ //disconnectFrom();
+ //ZYPP_THROW(MediaCurlSetOptException(_url, _curlError));
}

bool verify_peer = false;
--
To unsubscribe, e-mail: zypp-commit+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: zypp-commit+help@xxxxxxxxxxxx

< Previous Next >
This Thread
  • No further messages