diff --git a/.cvsignore b/.gitignore similarity index 100% rename from .cvsignore rename to .gitignore diff --git a/Makefile b/Makefile deleted file mode 100644 index 9387543..0000000 --- a/Makefile +++ /dev/null @@ -1,21 +0,0 @@ -# Makefile for source rpm: wv2 -# $Id$ -NAME := wv2 -SPECFILE = $(firstword $(wildcard *.spec)) - -define find-makefile-common -for d in common ../common ../../common ; do if [ -f $$d/Makefile.common ] ; then if [ -f $$d/CVS/Root -a -w $$/Makefile.common ] ; then cd $$d ; cvs -Q update ; fi ; echo "$$d/Makefile.common" ; break ; fi ; done -endef - -MAKEFILE_COMMON := $(shell $(find-makefile-common)) - -ifeq ($(MAKEFILE_COMMON),) -# attept a checkout -define checkout-makefile-common -test -f CVS/Root && { cvs -Q -d $$(cat CVS/Root) checkout common && echo "common/Makefile.common" ; } || { echo "ERROR: I can't figure out how to checkout the 'common' module." ; exit -1 ; } >&2 -endef - -MAKEFILE_COMMON := $(shell $(checkout-makefile-common)) -endif - -include $(MAKEFILE_COMMON) diff --git a/wv2-0.2.3-overflow.patch b/wv2-0.2.3-overflow.patch new file mode 100644 index 0000000..d3dc17a --- /dev/null +++ b/wv2-0.2.3-overflow.patch @@ -0,0 +1,15 @@ +diff -up wv2-0.2.3/src/styles.cpp.overflow wv2-0.2.3/src/styles.cpp +--- wv2-0.2.3/src/styles.cpp.overflow 2006-06-12 11:40:11.000000000 -0500 ++++ wv2-0.2.3/src/styles.cpp 2012-08-05 17:47:05.038101800 -0500 +@@ -187,6 +187,11 @@ bool STD::read( U16 baseSize, U16 totalS + #ifdef WV2_DEBUG_STYLESHEET + wvlog << "cbUPX: " << cbUPX << std::endl; + #endif ++ // do not overflow the allocated buffer grupx ++ if (offset + cbUPX > grupxLen) { ++ wvlog << "====> Error: grupx would overflow!" << std::endl; ++ return false; ++ } + for ( U16 j = 0; j < cbUPX; ++j ) { + grupx[ offset + j ] = stream->readU8(); // read the whole UPX + #ifdef WV2_DEBUG_STYLESHEET diff --git a/wv2.spec b/wv2.spec index 08d15ef..2da90a8 100644 --- a/wv2.spec +++ b/wv2.spec @@ -1,16 +1,18 @@ Name: wv2 Version: 0.2.3 -Release: 2%{?dist} +Release: 4%{?dist} Summary: A library which allows access to Microsoft® Word files Group: System Environment/Libraries -License: LGPL +License: LGPLv2 URL: http://wvware.sourceforge.net Source0: http://dl.sf.net/wvware/wv2-0.2.3.tar.bz2 # see bug #182293 Patch1: wv2-0.2.2-no-undefined.patch # see bug #192291 Patch2: wv2-0.2.2-no-extra-libs.patch +# backport calligra msword-odf overflow +Patch3: wv2-0.2.3-overflow.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) @@ -44,6 +46,7 @@ The wv2-devel package includes the header files necessary for developing. %patch1 -p1 -b .no-undefined %patch2 -p1 -b .extra_libs +%patch3 -p1 -b .overflow ./autogen.sh @@ -78,6 +81,12 @@ rm -rf $RPM_BUILD_ROOT %{_includedir}/wv2 %changelog +* Sun Aug 05 2012 Rex Dieter 0.2.3-4 +- backport msword filter overflow + +* Thu Aug 23 2007 Andreas Bierfert 0.2.3-3 +- new license tag + * Fri Sep 15 2006 Andreas Bierfert 0.2.3-2 - FE6 rebuild - fix BR