1 |
commit: ba7ccf31e3da9b82f8dac073ef4eece87b72a43d |
2 |
Author: Andreas Sturmlechner <asturm <AT> gentoo <DOT> org> |
3 |
AuthorDate: Mon Sep 11 17:35:21 2017 +0000 |
4 |
Commit: Andreas Sturmlechner <asturm <AT> gentoo <DOT> org> |
5 |
CommitDate: Mon Sep 11 17:37:32 2017 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ba7ccf31 |
7 |
|
8 |
app-text/libwpd: Security revbump for CVE-2017-14226 |
9 |
|
10 |
Package-Manager: Portage-2.3.6, Repoman-2.3.1 |
11 |
|
12 |
.../files/libwpd-0.10.1-CVE-2017-14226.patch | 50 ++++++++++++++++++++ |
13 |
app-text/libwpd/libwpd-0.10.1-r1.ebuild | 53 ++++++++++++++++++++++ |
14 |
2 files changed, 103 insertions(+) |
15 |
|
16 |
diff --git a/app-text/libwpd/files/libwpd-0.10.1-CVE-2017-14226.patch b/app-text/libwpd/files/libwpd-0.10.1-CVE-2017-14226.patch |
17 |
new file mode 100644 |
18 |
index 00000000000..4a5c0df922f |
19 |
--- /dev/null |
20 |
+++ b/app-text/libwpd/files/libwpd-0.10.1-CVE-2017-14226.patch |
21 |
@@ -0,0 +1,50 @@ |
22 |
+Gentoo-bug: 630682 (CVE-2017-14226) |
23 |
+ |
24 |
+Change-Id: I0d8d6887fa360c05d5f9e2a070410c77926b9ce1 |
25 |
+Reviewed-on: https://gerrit.libreoffice.org/42054 |
26 |
+Tested-by: Jenkins <ci@×××××××××××.org> |
27 |
+Reviewed-by: Caolán McNamara <caolanm@××××××.com> |
28 |
+Tested-by: Caolán McNamara <caolanm@××××××.com> |
29 |
+ |
30 |
+--- a/src/lib/WP5StylesListener.cpp |
31 |
++++ b/src/lib/WP5StylesListener.cpp |
32 |
+@@ -85,8 +85,9 @@ |
33 |
+ m_currentPage = WPXPageSpan(m_pageList.back(), 0.0, 0.0); |
34 |
+ m_currentPage.setPageSpan(1); |
35 |
+ |
36 |
+- for (std::vector<WPXHeaderFooter>::const_iterator HFiter = (m_nextPage.getHeaderFooterList()).begin(); |
37 |
+- HFiter != (m_nextPage.getHeaderFooterList()).end(); ++HFiter) |
38 |
++ std::vector<WPXHeaderFooter> headerFooterList = m_nextPage.getHeaderFooterList(); |
39 |
++ for (std::vector<WPXHeaderFooter>::const_iterator HFiter = headerFooterList.begin(); |
40 |
++ HFiter != headerFooterList.end(); ++HFiter) |
41 |
+ { |
42 |
+ if ((*HFiter).getOccurrence() != NEVER) |
43 |
+ { |
44 |
+--- a/src/lib/WP42StylesListener.cpp |
45 |
++++ b/src/lib/WP42StylesListener.cpp |
46 |
+@@ -84,8 +84,9 @@ |
47 |
+ m_currentPage = WPXPageSpan(m_pageList.back(), 0.0, 0.0); |
48 |
+ m_currentPage.setPageSpan(1); |
49 |
+ |
50 |
+- for (std::vector<WPXHeaderFooter>::const_iterator HFiter = (m_nextPage.getHeaderFooterList()).begin(); |
51 |
+- HFiter != (m_nextPage.getHeaderFooterList()).end(); ++HFiter) |
52 |
++ std::vector<WPXHeaderFooter> headerFooterList = m_nextPage.getHeaderFooterList(); |
53 |
++ for (std::vector<WPXHeaderFooter>::const_iterator HFiter = headerFooterList.begin(); |
54 |
++ HFiter != headerFooterList.end(); ++HFiter) |
55 |
+ { |
56 |
+ if ((*HFiter).getOccurrence() != NEVER) |
57 |
+ { |
58 |
+--- a/src/lib/WP1StylesListener.cpp |
59 |
++++ b/src/lib/WP1StylesListener.cpp |
60 |
+@@ -83,8 +83,9 @@ |
61 |
+ m_currentPage = WPXPageSpan(m_pageList.back(), 0.0, 0.0); |
62 |
+ m_currentPage.setPageSpan(1); |
63 |
+ |
64 |
+- for (std::vector<WPXHeaderFooter>::const_iterator HFiter = (m_nextPage.getHeaderFooterList()).begin(); |
65 |
+- HFiter != (m_nextPage.getHeaderFooterList()).end(); ++HFiter) |
66 |
++ std::vector<WPXHeaderFooter> headerFooterList = m_nextPage.getHeaderFooterList(); |
67 |
++ for (std::vector<WPXHeaderFooter>::const_iterator HFiter = headerFooterList.begin(); |
68 |
++ HFiter != headerFooterList.end(); ++HFiter) |
69 |
+ { |
70 |
+ if ((*HFiter).getOccurrence() != NEVER) |
71 |
+ { |
72 |
|
73 |
diff --git a/app-text/libwpd/libwpd-0.10.1-r1.ebuild b/app-text/libwpd/libwpd-0.10.1-r1.ebuild |
74 |
new file mode 100644 |
75 |
index 00000000000..62f8a7d31f2 |
76 |
--- /dev/null |
77 |
+++ b/app-text/libwpd/libwpd-0.10.1-r1.ebuild |
78 |
@@ -0,0 +1,53 @@ |
79 |
+# Copyright 1999-2017 Gentoo Foundation |
80 |
+# Distributed under the terms of the GNU General Public License v2 |
81 |
+ |
82 |
+EAPI=6 |
83 |
+ |
84 |
+inherit alternatives |
85 |
+ |
86 |
+DESCRIPTION="WordPerfect Document import/export library" |
87 |
+HOMEPAGE="http://libwpd.sf.net" |
88 |
+SRC_URI="mirror://sourceforge/${PN}/${P}.tar.xz" |
89 |
+ |
90 |
+LICENSE="|| ( LGPL-2.1 MPL-2.0 )" |
91 |
+SLOT="0.10" |
92 |
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~x86 ~x86-fbsd" |
93 |
+IUSE="doc +tools" |
94 |
+ |
95 |
+RDEPEND="dev-libs/librevenge" |
96 |
+DEPEND="${RDEPEND} |
97 |
+ virtual/pkgconfig |
98 |
+ doc? ( app-doc/doxygen ) |
99 |
+" |
100 |
+ |
101 |
+PATCHES=( "${FILESDIR}/${P}-CVE-2017-14226.patch" ) |
102 |
+ |
103 |
+src_configure() { |
104 |
+ econf \ |
105 |
+ --disable-static \ |
106 |
+ --disable-werror \ |
107 |
+ $(use_with doc docs) \ |
108 |
+ $(use_enable tools) \ |
109 |
+ --program-suffix=-${SLOT} |
110 |
+} |
111 |
+ |
112 |
+src_install() { |
113 |
+ default |
114 |
+ find "${D}" -name '*.la' -delete || die |
115 |
+} |
116 |
+ |
117 |
+pkg_postinst() { |
118 |
+ if use tools; then |
119 |
+ alternatives_auto_makesym /usr/bin/wpd2html "/usr/bin/wpd2html-[0-9].[0-9][0-9]" |
120 |
+ alternatives_auto_makesym /usr/bin/wpd2raw "/usr/bin/wpd2raw-[0-9].[0-9][0-9]" |
121 |
+ alternatives_auto_makesym /usr/bin/wpd2text "/usr/bin/wpd2text-[0-9].[0-9][0-9]" |
122 |
+ fi |
123 |
+} |
124 |
+ |
125 |
+pkg_postrm() { |
126 |
+ if use tools; then |
127 |
+ alternatives_auto_makesym /usr/bin/wpd2html "/usr/bin/wpd2html-[0-9].[0-9][0-9]" |
128 |
+ alternatives_auto_makesym /usr/bin/wpd2raw "/usr/bin/wpd2raw-[0-9].[0-9][0-9]" |
129 |
+ alternatives_auto_makesym /usr/bin/wpd2text "/usr/bin/wpd2text-[0-9].[0-9][0-9]" |
130 |
+ fi |
131 |
+} |