[packages/libytnef] - added segv patch (buffer overflow fix from git) - release 3
qboosh
qboosh at pld-linux.org
Sun Dec 28 13:54:25 CET 2014
commit cf6c80f8f037bf3806c065ed0ad48b209a49a9d2
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date: Sun Dec 28 13:55:33 2014 +0100
- added segv patch (buffer overflow fix from git)
- release 3
libytnef-segv.patch | 11 +++++++++++
libytnef.spec | 6 ++++--
2 files changed, 15 insertions(+), 2 deletions(-)
---
diff --git a/libytnef.spec b/libytnef.spec
index 25896be..31b97d6 100644
--- a/libytnef.spec
+++ b/libytnef.spec
@@ -3,11 +3,12 @@ Summary: C library for decoding application/ms-tnef e-mail attachments
Summary(pl.UTF-8): Biblioteka C do dekodowania załączników e-maili typu application/ms-tnef
Name: libytnef
Version: 1.5
-Release: 2
-License: GPL v2
+Release: 3
+License: GPL v2+
Group: Libraries
Source0: http://downloads.sourceforge.net/ytnef/%{name}-%{version}.tar.gz
# Source0-md5: 6c44b955f33cf714c75a7bbe895cc352
+Patch0: %{name}-segv.patch
URL: http://ytnef.sourceforge.net/
BuildRequires: autoconf >= 2.50
BuildRequires: automake
@@ -49,6 +50,7 @@ Statyczna biblioteka libytnef.
%prep
%setup -q
+%patch0 -p1
%build
%{__libtoolize}
diff --git a/libytnef-segv.patch b/libytnef-segv.patch
new file mode 100644
index 0000000..cdde2b8
--- /dev/null
+++ b/libytnef-segv.patch
@@ -0,0 +1,11 @@
+--- libytnef-1.5/ytnef.c.orig 2004-08-26 19:09:05.000000000 +0200
++++ libytnef-1.5/ytnef.c 2014-12-28 13:22:11.710584874 +0100
+@@ -1328,7 +1328,7 @@
+
+ comp_Prebuf.size = strlen(RTF_PREBUF);
+ comp_Prebuf.data = calloc(comp_Prebuf.size, 1);
+- strcpy(comp_Prebuf.data, RTF_PREBUF);
++ memcpy(comp_Prebuf.data, RTF_PREBUF, comp_Prebuf.size);
+
+ src = p->data;
+ in = 0;
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/libytnef.git/commitdiff/cf6c80f8f037bf3806c065ed0ad48b209a49a9d2
More information about the pld-cvs-commit
mailing list