From 2535eddad7b1a5cfe95d01c9c3955e82c348e38b0f801662bed6d51c32b4defc Mon Sep 17 00:00:00 2001 From: Stephan Kulow Date: Thu, 22 Mar 2012 11:34:38 +0000 Subject: [PATCH] Accepting request 110162 from devel:libraries:c_c++ - Update to new SVN snapshot rev 603 (ZCP 7.0.6 dependency) * Set Diffie-Hellman prime size (bug SF#3434852) OBS-URL: https://build.opensuse.org/request/show/110162 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/libvmime?expand=0&rev=2 --- libvmime-0.9.1+.tar.bz2 | 3 - libvmime-0.9.1+svn603.tar.bz2 | 3 + libvmime-libgnutls28.diff | 37 ----------- libvmime.changes | 6 ++ libvmime.spec | 71 +++++++++++++--------- vmime-0.9.2-header-value-on-next-line.diff | 45 ++++++++++++++ vmime-0.9.2-qp-in-buffers.diff | 16 +++++ vmime-mixed-qp-in-parameter.diff | 28 +++++++++ 8 files changed, 140 insertions(+), 69 deletions(-) delete mode 100644 libvmime-0.9.1+.tar.bz2 create mode 100644 libvmime-0.9.1+svn603.tar.bz2 delete mode 100644 libvmime-libgnutls28.diff create mode 100644 vmime-0.9.2-header-value-on-next-line.diff create mode 100644 vmime-0.9.2-qp-in-buffers.diff create mode 100644 vmime-mixed-qp-in-parameter.diff diff --git a/libvmime-0.9.1+.tar.bz2 b/libvmime-0.9.1+.tar.bz2 deleted file mode 100644 index 21347a0..0000000 --- a/libvmime-0.9.1+.tar.bz2 +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:2e9c6b31400ac044575a50865893977a46b77415bb9ea45fded7751f9fb34d26 -size 632052 diff --git a/libvmime-0.9.1+svn603.tar.bz2 b/libvmime-0.9.1+svn603.tar.bz2 new file mode 100644 index 0000000..bf32293 --- /dev/null +++ b/libvmime-0.9.1+svn603.tar.bz2 @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9c321da84af04562ab9faeb62702952c3a2faf894ededa0fc675d148b468abe6 +size 351937 diff --git a/libvmime-libgnutls28.diff b/libvmime-libgnutls28.diff deleted file mode 100644 index e98edd0..0000000 --- a/libvmime-libgnutls28.diff +++ /dev/null @@ -1,37 +0,0 @@ -From: Jan Engelhardt -Date: 2011-10-07 00:06:10.890341952 +0200 -Upstream: tbd - -build: resolve build error with libgnutls-3.x - -The gnutls/extra.h include is gone in libgnutls 3.x, and it -does not seem like we need it for libgnutls 2.x anyway, -so just remove it. - -GNUTLS_E_LZO_INIT_FAILED was removed too.. can probably live -without in gnutls2. - ---- - src/net/tls/TLSSession.cpp | 2 -- - 1 file changed, 2 deletions(-) - -Index: vmime/src/net/tls/TLSSession.cpp -=================================================================== ---- vmime.orig/src/net/tls/TLSSession.cpp -+++ vmime/src/net/tls/TLSSession.cpp -@@ -22,7 +22,6 @@ - // - - #include --#include - - #include "vmime/config.hpp" - -@@ -318,7 +317,6 @@ void TLSSession::throwTLSException(const - ERROR(GNUTLS_E_INIT_LIBEXTRA) - ERROR(GNUTLS_E_LIBRARY_VERSION_MISMATCH) - ERROR(GNUTLS_E_NO_TEMPORARY_RSA_PARAMS) -- ERROR(GNUTLS_E_LZO_INIT_FAILED) - ERROR(GNUTLS_E_NO_COMPRESSION_ALGORITHMS) - ERROR(GNUTLS_E_NO_CIPHER_SUITES) - ERROR(GNUTLS_E_OPENPGP_GETKEY_FAILED) diff --git a/libvmime.changes b/libvmime.changes index 86b0005..bfd7172 100644 --- a/libvmime.changes +++ b/libvmime.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Fri Mar 16 12:33:11 UTC 2012 - jengelh@medozas.de + +- Update to new SVN snapshot rev 603 (ZCP 7.0.6 dependency) +* Set Diffie-Hellman prime size (bug SF#3434852) + ------------------------------------------------------------------- Thu Jun 30 14:59:15 UTC 2011 - jengelh@medozas.de diff --git a/libvmime.spec b/libvmime.spec index a0ce03c..f00d0e0 100644 --- a/libvmime.spec +++ b/libvmime.spec @@ -1,7 +1,7 @@ # # spec file for package libvmime # -# Copyright (c) 2011 SUSE LINUX Products GmbH, Nuernberg, Germany. +# Copyright (c) 2012 SUSE LINUX Products GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -15,38 +15,51 @@ # Please submit bugfixes or comments via http://bugs.opensuse.org/ # -Name: libvmime -%define lname libvmime-0_9_2-0 -Summary: Library for working with MIME messages and IMAP/POP/SMTP -Version: 0.9.2 -Release: 0 -Group: Development/Libraries/C and C++ -URL: http://vmime.sf.net/ -License: GPL-3.0+ +Name: libvmime +%define lname libvmime-0_9_2-0 +Summary: Library for working with MIME messages and IMAP/POP/SMTP +License: GPL-3.0+ +Group: Development/Libraries/C and C++ +Version: 0.9.2 +Release: 0 +Url: http://vmime.sf.net/ + +#Svn-Clone: https://vmime.svn.sourceforge.net/svnroot/vmime/trunk #Source: http://downloads.sf.net/vmime/%name-%version.tar.bz2 -Source: %name-0.9.1+.tar.bz2 -Source2: spice_source.sh -#Svn-Clone: https://vmime.svn.sourceforge.net/svnroot/vmime -Patch1: libvmime-nodatetime.diff +Source: %name-0.9.1+svn603.tar.bz2 +Source2: spice_source.sh +Patch1: libvmime-nodatetime.diff # PATCH-WORKAROUND-UPSTREAM libvmime-sotag.diff -Patch2: libvmime-sotag.diff +Patch2: libvmime-sotag.diff # PATCH-FEATURE-UPSTREAM vmime-0.8.1-charset-catch.diff x -- ZCP team will deal with this in time -Patch3: vmime-0.8.1-charset-catch.diff -# PATCH-FIX-UPSTREAM libvmime-libgnutls28.diff -Patch4: libvmime-libgnutls28.diff -BuildRoot: %_tmppath/%name-%version-build -BuildRequires: autoconf, automake, gcc-c++, libgsasl-devel, libtool -BuildRequires: libgcrypt-devel, pkgconfig, postfix, scons, xz +Patch3: vmime-0.8.1-charset-catch.diff +Patch4: vmime-0.9.2-header-value-on-next-line.diff +Patch5: vmime-mixed-qp-in-parameter.diff +Patch6: vmime-0.9.2-qp-in-buffers.diff +BuildRoot: %{_tmppath}/%{name}-%{version}-build +BuildRequires: autoconf +BuildRequires: automake +BuildRequires: gcc-c++ +BuildRequires: libgcrypt-devel +BuildRequires: libgsasl-devel +BuildRequires: libtool +BuildRequires: pkgconfig +BuildRequires: postfix +BuildRequires: scons +BuildRequires: xz %if 0%{?suse_version} >= 1100 -BuildRequires: gettext-tools, libgnutls-devel, libselinux-devel +BuildRequires: gettext-tools +BuildRequires: libgnutls-devel +BuildRequires: libselinux-devel %else %if 0%{?suse_version} > 0 -BuildRequires: gnutls-devel +BuildRequires: gnutls-devel %endif %endif %if 0%{?fedora_version} > 0 -BuildRequires: gettext, gnutls-devel +BuildRequires: gettext +BuildRequires: gnutls-devel %endif %description @@ -59,8 +72,8 @@ over the Internet. The library offers all the features to build a complete mail client. %package -n %lname -Summary: Library for working with MIME messages and IMAP/POP/SMTP -Group: System/Libraries +Summary: Library for working with MIME messages and IMAP/POP/SMTP +Group: System/Libraries %description -n %lname VMime is a powerful C++ class library for working with MIME messages @@ -72,9 +85,9 @@ over the Internet. The library offers all the features to build a complete mail client. %package devel -Summary: Library for working with MIME messages and IMAP/POP/SMTP -Group: Development/Libraries/C and C++ -Requires: %lname = %version +Summary: Library for working with MIME messages and IMAP/POP/SMTP +Group: Development/Libraries/C and C++ +Requires: %lname = %version %description devel VMime is a powerful C++ class library for working with MIME messages @@ -87,7 +100,7 @@ complete mail client. %prep %setup -qn vmime -%patch -P 1 -P 2 -P 3 -P 4 -p1 +%patch -P 1 -P 2 -P 3 -P 4 -P 5 -P 6 -p1 %build # sendmail's awesome location. diff --git a/vmime-0.9.2-header-value-on-next-line.diff b/vmime-0.9.2-header-value-on-next-line.diff new file mode 100644 index 0000000..9de349c --- /dev/null +++ b/vmime-0.9.2-header-value-on-next-line.diff @@ -0,0 +1,45 @@ +diff -Nurb libvmime-0.9.2.orig/src/headerField.cpp libvmime-0.9.2.patched/src/headerField.cpp +--- libvmime-0.9.2.orig/src/headerField.cpp 2010-05-20 05:33:45.000000000 -0700 ++++ libvmime-0.9.2.patched/src/headerField.cpp 2011-08-29 12:10:08.438497914 -0700 +@@ -157,14 +157,12 @@ + { + contentsEnd = pos; + pos += 2; +- break; + } + else if (c == '\n') + { + contentsEnd = pos; + ++pos; +- break; +- } ++ } else { + + while (pos < end) + { +@@ -186,24 +184,13 @@ + + ++pos; + } ++ } + + // Handle the case of folded lines + if (buffer[pos] == ' ' || buffer[pos] == '\t') + { + // This is a folding white-space: we keep it as is and + // we continue with contents parsing... +- +- // If the line contains only space characters, we assume it is +- // the end of the headers. This is not strictly standard-compliant +- // but, hey, we can't fail when parsing some malformed mails... +- while (pos < end && (buffer[pos] == ' ' || buffer[pos] == '\t')) +- ++pos; +- +- if ((pos < end && buffer[pos] == '\n') || +- (pos + 1 < end && buffer[pos] == '\r' && buffer[pos + 1] == '\n')) +- { +- break; +- } + } + else + { diff --git a/vmime-0.9.2-qp-in-buffers.diff b/vmime-0.9.2-qp-in-buffers.diff new file mode 100644 index 0000000..a592ef0 --- /dev/null +++ b/vmime-0.9.2-qp-in-buffers.diff @@ -0,0 +1,16 @@ +--- svn/src/wordEncoder.cpp (revision 603) ++++ svn/src/wordEncoder.cpp (working copy) +@@ -239,6 +239,13 @@ + if (buffer.find_first_of("\n\r") != string::npos) + return true; + ++ // If the string contains a QP string, we need to encode this. ++ // Not a 100% check, but we'd only get more encoded strings. ++ std::string::size_type pos = buffer.find("=?"); ++ std::string::size_type end = buffer.find("?="); ++ if (pos != string::npos && end != string::npos && end > pos) ++ return true; ++ + return false; + } + diff --git a/vmime-mixed-qp-in-parameter.diff b/vmime-mixed-qp-in-parameter.diff new file mode 100644 index 0000000..a0d4be4 --- /dev/null +++ b/vmime-mixed-qp-in-parameter.diff @@ -0,0 +1,28 @@ +Index: svn/src/parameter.cpp +=================================================================== +--- svn/src/parameter.cpp (revision 597) ++++ svn/src/parameter.cpp (working copy) +@@ -239,8 +239,21 @@ + { + value << t.getWholeBuffer(); + +- if (!foundCharsetChunk) +- ch = t.getWordAt(0)->getCharset(); ++ if (!foundCharsetChunk) { ++ // this is still wrong. each word can have it's ++ // own charset, and can be mixed (eg. iso-8859-1 ++ // and iso-2022-jp), but very unlikely. ++ // real fix is to have parameters store a ++ // vmime::text in stead of a vmime::word in ++ // m_value. but that changes the interface ++ for (size_t i = 0; i < t.getWordCount(); i++) { ++ if (t.getWordAt(i)->getCharset() != ch && ch == charsets::US_ASCII) { ++ ch = t.getWordAt(i)->getCharset(); ++ break; ++ } ++ } ++ ++ } + } + } + }