1 |
commit: 3e26009a67724d3af2dbdaae47d1dcf2288c5539 |
2 |
Author: Göktürk Yüksek <gokturk <AT> gentoo <DOT> org> |
3 |
AuthorDate: Thu Jan 24 19:44:24 2019 +0000 |
4 |
Commit: Göktürk Yüksek <gokturk <AT> gentoo <DOT> org> |
5 |
CommitDate: Thu Jan 24 20:17:39 2019 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3e26009a |
7 |
|
8 |
app-forensics/sleuthkit: bump to 4.6.5 |
9 |
|
10 |
Also addresses CVE-2018-19497. |
11 |
|
12 |
Bug: https://bugs.gentoo.org/661160 |
13 |
Package-Manager: Portage-2.3.52, Repoman-2.3.12 |
14 |
Signed-off-by: Göktürk Yüksek <gokturk <AT> gentoo.org> |
15 |
|
16 |
app-forensics/sleuthkit/Manifest | 1 + |
17 |
app-forensics/sleuthkit/sleuthkit-4.6.5.ebuild | 255 +++++++++++++++++++++++++ |
18 |
2 files changed, 256 insertions(+) |
19 |
|
20 |
diff --git a/app-forensics/sleuthkit/Manifest b/app-forensics/sleuthkit/Manifest |
21 |
index 9b98215a04a..281da89a45b 100644 |
22 |
--- a/app-forensics/sleuthkit/Manifest |
23 |
+++ b/app-forensics/sleuthkit/Manifest |
24 |
@@ -3,4 +3,5 @@ DIST libewf-20130128.tar.gz 1978794 BLAKE2B e5d2bd8f4a8b878e13536b89b032d8cee698 |
25 |
DIST sleuthkit-4.5.0.tar.gz 8611141 BLAKE2B a1ae66bfcb74ce1fec24f80dfe60cd68f1de53119331c38848f7f82de8052eda49d78fdea49e42ada5843094939ef212dece42a5ceb85931a79e02adccda30e6 SHA512 911890cacca739f121681514197104cb2dc3bd219f3e068c4ce61264498c56989359976fc75172e1f456c94e4e25c6206413b0234c36e55736a577b8e664e4b3 |
26 |
DIST sleuthkit-4.6.0.tar.gz 8634432 BLAKE2B b45721cdee798d84f0caa0bfe38645346539bb497f5a492c72016a6b3b0246b362ecea676a7a0e788d66cc0dc32335e719912434bd61aa205b7d51b8d4bd7c14 SHA512 dbf880e8503dccb0a686f1d9658d56e9cb40f452127f9b713cf2a4941f4083fa1cf80a886994d58421307a679242cd4ee005b3e874cf429cfb140a597a0dc739 |
27 |
DIST sleuthkit-4.6.4.tar.gz 8655341 BLAKE2B 9d8a2884d1c90e9be3104221c22fdc4346c8f288a13384ef8205cea46bbda2249691b548b7d19a1b34d6d0d1fc6d5390aa0fc8c8b28ea75b53de946b62c8e25c SHA512 0dd3fc3659fd6dee49ababd8033bcc5ce218c9154b61eb072a943e8d1a96fb04dcabc85124583bc69ad0ced2609fed11812164a3db6587446255a9c507f08762 |
28 |
+DIST sleuthkit-4.6.5.tar.gz 8658866 BLAKE2B 29b75c96a14c5d42522e7116a80cc368c8097fa43af27c0e958215142d6ee61131c7b154fb876fa3ea9c727e8100de9bd703dfd8cef9ccce1f6602222c8470fa SHA512 ba21be166da1a7bdd197946722a1e0947f90bbb2c27d635cdfbcbc870aa42937fe6b42f432482f70a5e686942c8891d0367b5ce28615315d8905661e73aefe32 |
29 |
DIST sqlite-jdbc-3.8.11.jar 5131732 BLAKE2B 1a04fa9e9cb97fdddc19af2de9efa7b54c0b527642e6e325e31054e4e294e3bc6af00ea291087ed9dd26668d48dae356035fc85212c0eb81656550d552103ed0 SHA512 5f4705101992e8916e29742c560aef0d01eba9dc0d2d984b75a77e56be3c9fd20b284390fe8f9bb54bf9d1f8528c3413922684c446212ca8961ac731543fb179 |
30 |
|
31 |
diff --git a/app-forensics/sleuthkit/sleuthkit-4.6.5.ebuild b/app-forensics/sleuthkit/sleuthkit-4.6.5.ebuild |
32 |
new file mode 100644 |
33 |
index 00000000000..7acead628b4 |
34 |
--- /dev/null |
35 |
+++ b/app-forensics/sleuthkit/sleuthkit-4.6.5.ebuild |
36 |
@@ -0,0 +1,255 @@ |
37 |
+# Copyright 1999-2019 Gentoo Authors |
38 |
+# Distributed under the terms of the GNU General Public License v2 |
39 |
+ |
40 |
+EAPI=6 |
41 |
+ |
42 |
+JAVA_PKG_BSFIX_NAME="build.xml build-unix.xml" |
43 |
+inherit autotools java-pkg-opt-2 java-ant-2 |
44 |
+ |
45 |
+DESCRIPTION="A collection of file system and media management forensic analysis tools" |
46 |
+HOMEPAGE="https://www.sleuthkit.org/sleuthkit/" |
47 |
+# TODO: sqlite-jdbc does not exist in the tree, we bundle it for now |
48 |
+# TODO: Upstream uses a very specific version of libewf which is not in |
49 |
+# the tree anymore. So we statically compile and link to sleuthkit. |
50 |
+# Hopefully upstream will figure something out in the future. |
51 |
+SRC_URI="https://github.com/${PN}/${PN}/releases/download/${P}/${P}.tar.gz |
52 |
+ java? ( |
53 |
+ http://repo1.maven.org/maven2/org/xerial/sqlite-jdbc/3.8.11/sqlite-jdbc-3.8.11.jar |
54 |
+ http://repo1.maven.org/maven2/com/zaxxer/SparseBitSet/1.1/SparseBitSet-1.1.jar |
55 |
+ ) |
56 |
+ ewf? ( https://dev.gentoo.org/~gokturk/distfiles/app-forensics/libewf/libewf-20130128.tar.gz )" |
57 |
+ |
58 |
+LICENSE="BSD CPL-1.0 GPL-2+ IBM java? ( Apache-2.0 )" |
59 |
+SLOT="0/13" # subslot = major soname version |
60 |
+KEYWORDS="~amd64 ~hppa ~ppc ~x86" |
61 |
+IUSE="aff doc ewf java postgres static-libs test +threads zlib" |
62 |
+ |
63 |
+# Note: It is not possible to move the dep on dev-java/jdbc-postgresql |
64 |
+# inside a conditional postgres? block because java sources import |
65 |
+# org.postgres unconditionally as of writing this (version 4.6.4). The |
66 |
+# postgres USE flag will be used for the TSK postgresql support however. |
67 |
+DEPEND=" |
68 |
+ dev-db/sqlite:3 |
69 |
+ dev-lang/perl:* |
70 |
+ aff? ( app-forensics/afflib ) |
71 |
+ ewf? ( sys-libs/zlib ) |
72 |
+ java? ( |
73 |
+ >=virtual/jdk-1.8:* |
74 |
+ >=dev-java/c3p0-0.9.5:0 |
75 |
+ >=dev-java/jdbc-postgresql-9.4:0 |
76 |
+ ) |
77 |
+ postgres? ( dev-db/postgresql:= ) |
78 |
+ zlib? ( sys-libs/zlib ) |
79 |
+" |
80 |
+# TODO: add support for not-in-tree libraries libvhdi and libvmdk |
81 |
+# libvhdi: https://github.com/libyal/libvhdi |
82 |
+# libvmdk: https://github.com/libyal/libvmdk |
83 |
+# DEPEND="${DEPEND} |
84 |
+# vhdi? ( dev-libs/libvhdi ) |
85 |
+# vmdk? ( dev-libs/libvmdk ) |
86 |
+# " |
87 |
+ |
88 |
+RDEPEND="${DEPEND} |
89 |
+ java? ( >=virtual/jre-1.8:= ) |
90 |
+" |
91 |
+DEPEND="${DEPEND} |
92 |
+ doc? ( app-doc/doxygen ) |
93 |
+ test? ( >=dev-util/cppunit-1.2.1 ) |
94 |
+" |
95 |
+ |
96 |
+PATCHES=( |
97 |
+ "${FILESDIR}"/${PN}-4.1.0-tools-shared-libs.patch |
98 |
+ "${FILESDIR}"/${PN}-4.6.4-default-jar-location-fix.patch |
99 |
+) |
100 |
+ |
101 |
+src_unpack() { |
102 |
+ local f |
103 |
+ |
104 |
+ unpack ${P}.tar.gz |
105 |
+ |
106 |
+ # Ick, the upstream is stuck at libewf-20130128 which is |
107 |
+ # not even in the tree anymore. So we have to bundle it. |
108 |
+ if use ewf; then |
109 |
+ pushd "${T}" &>/dev/null || die |
110 |
+ unpack libewf-20130128.tar.gz |
111 |
+ export TSK_LIBEWF_SRCDIR="${T}"/libewf-20130128 |
112 |
+ popd &>/dev/null || die |
113 |
+ fi |
114 |
+ |
115 |
+ # Copy the jar files that don't exist in the tree yet |
116 |
+ if use java; then |
117 |
+ TSK_JAR_DIR="${T}/lib" |
118 |
+ mkdir "${TSK_JAR_DIR}" || die |
119 |
+ for f in ${A}; do |
120 |
+ if [[ ${f} =~ .jar$ ]]; then |
121 |
+ cp "${DISTDIR}"/"${f}" "${TSK_JAR_DIR}" || die |
122 |
+ fi |
123 |
+ done |
124 |
+ export TSK_JAR_DIR |
125 |
+ fi |
126 |
+} |
127 |
+ |
128 |
+tsk_prepare_libewf() { |
129 |
+ # Yeah, libewf-20130128 obviously doesn't just nicely compile |
130 |
+ sed -e 's/LIBUNA_INLINE inline/LIBUNA_INLINE/' \ |
131 |
+ -i "${TSK_LIBEWF_SRCDIR}"/libuna/libuna_inline.h || die |
132 |
+} |
133 |
+ |
134 |
+src_prepare() { |
135 |
+ use ewf && tsk_prepare_libewf |
136 |
+ |
137 |
+ if use java; then |
138 |
+ pushd "${S}"/bindings/java &>/dev/null || die |
139 |
+ |
140 |
+ # Prevent "make install" from installing |
141 |
+ # jar files under /usr/share/java |
142 |
+ # We'll use the java eclasses for this |
143 |
+ sed -e '/^jar_DATA/ d;' -i Makefile.am || die |
144 |
+ |
145 |
+ java-pkg-opt-2_src_prepare |
146 |
+ |
147 |
+ popd &>/dev/null || die |
148 |
+ fi |
149 |
+ |
150 |
+ # Override the doxygen output directories |
151 |
+ if use doc; then |
152 |
+ sed -e "/^OUTPUT_DIRECTORY/ s|=.*$|= ${T}/doc|" \ |
153 |
+ -i tsk/docs/Doxyfile \ |
154 |
+ -i bindings/java/doxygen/Doxyfile || die |
155 |
+ fi |
156 |
+ |
157 |
+ # It's safe to call this even after java-pkg-opt-2_src_prepare |
158 |
+ # because future calls to eapply_user do nothing and return 0 |
159 |
+ default |
160 |
+ |
161 |
+ eautoreconf |
162 |
+} |
163 |
+ |
164 |
+tsk_compile_libewf() { |
165 |
+ local myeconfargs=( |
166 |
+ --prefix=/ |
167 |
+ --libdir=/lib |
168 |
+ --enable-static |
169 |
+ --disable-shared |
170 |
+ --disable-winapi |
171 |
+ --without-libbfio |
172 |
+ --with-zlib |
173 |
+ --without-bzip2 |
174 |
+ --without-libhmac |
175 |
+ --without-openssl |
176 |
+ --without-libuuid |
177 |
+ --without-libfuse |
178 |
+ ) |
179 |
+ # We want to contain our build flags |
180 |
+ local CFLAGS="${CFLAGS}" |
181 |
+ local LDFLAGS="${LDFLAGS}" |
182 |
+ |
183 |
+ pushd "${TSK_LIBEWF_SRCDIR}" &>/dev/null || die |
184 |
+ |
185 |
+ # Produce relocatable code |
186 |
+ CFLAGS+=" -fPIC" |
187 |
+ LDFLAGS+=" -fPIC" |
188 |
+ econf "${myeconfargs[@]}" |
189 |
+ |
190 |
+ # Do not waste CPU cycles on building ewftools |
191 |
+ sed -e '/ewftools/ d' -i Makefile || die |
192 |
+ emake |
193 |
+ |
194 |
+ # Only install the headers and the library |
195 |
+ emake -C libewf DESTDIR="${T}"/image install |
196 |
+ emake -C include DESTDIR="${T}"/image install |
197 |
+ find "${T}"/image -name '*.la' -delete || die |
198 |
+ |
199 |
+ popd &>/dev/null || die |
200 |
+} |
201 |
+ |
202 |
+src_configure() { |
203 |
+ local myeconfargs=( |
204 |
+ --enable-offline="${TSK_JAR_DIR}" |
205 |
+ $(use_enable java) |
206 |
+ $(use_enable static-libs static) |
207 |
+ $(use_enable threads multithreading) |
208 |
+ $(use_with aff afflib) |
209 |
+ $(use_with zlib) |
210 |
+ ) |
211 |
+ # Workaround the automagic detection of postgresql |
212 |
+ local -x ac_cv_lib_pq_PQlibVersion="$(usex postgres)" |
213 |
+ # TODO: add support for non-existing libraries libvhdi and libvmdk |
214 |
+ # myeconfargs+=( |
215 |
+ # $(use_with vhdi libvhdi) |
216 |
+ # $(use_with vmdk libvmdk) |
217 |
+ # ) |
218 |
+ myeconfargs+=( |
219 |
+ --without-libvhdi |
220 |
+ --without-libvmdk |
221 |
+ ) |
222 |
+ |
223 |
+ use ewf && tsk_compile_libewf |
224 |
+ myeconfargs+=( $(use_with ewf libewf "${T}"/image) ) |
225 |
+ |
226 |
+ if use java; then |
227 |
+ pushd "${S}"/bindings/java &>/dev/null || die |
228 |
+ java-ant-2_src_configure |
229 |
+ popd &>/dev/null || die |
230 |
+ fi |
231 |
+ |
232 |
+ econf "${myeconfargs[@]}" |
233 |
+} |
234 |
+ |
235 |
+src_compile() { |
236 |
+ # Give it an existing bogus ivy home #672220 |
237 |
+ local -x IVY_HOME="${T}" |
238 |
+ |
239 |
+ # Create symlinks of jars for the required dependencies |
240 |
+ if use java; then |
241 |
+ pushd "${S}"/bindings/java &>/dev/null || die |
242 |
+ |
243 |
+ java-pkg_jar-from --into "${TSK_JAR_DIR}" c3p0 |
244 |
+ java-pkg_jar-from --into "${TSK_JAR_DIR}" jdbc-postgresql |
245 |
+ |
246 |
+ popd &>/dev/null || die |
247 |
+ fi |
248 |
+ |
249 |
+ # Create the doc output dirs if requested |
250 |
+ if use doc; then |
251 |
+ mkdir -p "${T}"/doc/{api-docs,jni-docs} || die |
252 |
+ fi |
253 |
+ |
254 |
+ emake all $(usex doc api-docs "") |
255 |
+} |
256 |
+ |
257 |
+src_install() { |
258 |
+ local f |
259 |
+ |
260 |
+ if use java; then |
261 |
+ pushd "${S}"/bindings/java &>/dev/null || die |
262 |
+ |
263 |
+ java-pkg_newjar "dist/${P}.jar" "${PN}.jar" |
264 |
+ |
265 |
+ # Install the bundled jar files |
266 |
+ pushd "${TSK_JAR_DIR}" &>/dev/null || die |
267 |
+ for f in *; do |
268 |
+ # Skip the symlinks java-pkg_jar-from created |
269 |
+ [[ -f ${f} ]] || continue |
270 |
+ |
271 |
+ # Strip the version numbers as per eclass recommendation |
272 |
+ [[ ${f} =~ -([0-9]+\.)+jar$ ]] || continue |
273 |
+ |
274 |
+ java-pkg_newjar "${f}" "${f/${BASH_REMATCH[0]}/.jar}" |
275 |
+ done |
276 |
+ popd &>/dev/null || die |
277 |
+ |
278 |
+ popd &>/dev/null || die |
279 |
+ fi |
280 |
+ |
281 |
+ default |
282 |
+ |
283 |
+ # It unconditionally builds both api and jni docs |
284 |
+ # We install conditionally based on the provided use flags |
285 |
+ if use doc; then |
286 |
+ dodoc -r "${T}"/doc/api-docs |
287 |
+ use java && dodoc -r "${T}"/doc/jni-docs |
288 |
+ fi |
289 |
+ |
290 |
+ find "${D}" -name '*.la' -delete || die |
291 |
+} |