bump(sys-apps/file): sync with upstream

This commit is contained in:
David Michael 2018-06-26 03:30:49 +00:00
parent efeec47380
commit 6ccb1d3d43
6 changed files with 49 additions and 16 deletions

View File

@ -4,11 +4,11 @@ DESCRIPTION=identify a file's format by scanning binary data for patterns
EAPI=6
HOMEPAGE=https://www.darwinsys.com/file/
IUSE=python static-libs zlib python_targets_pypy python_targets_python2_7 python_targets_python3_4 python_targets_python3_5 python_targets_python3_6 abi_x86_32 abi_x86_64 abi_x86_x32 abi_mips_n32 abi_mips_n64 abi_mips_o32 abi_ppc_32 abi_ppc_64 abi_s390_32 abi_s390_64
KEYWORDS=alpha amd64 arm arm64 hppa ia64 m68k ~mips ppc ppc64 s390 sh sparc x86 ~ppc-aix ~x64-cygwin ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris
KEYWORDS=alpha amd64 arm arm64 hppa ia64 m68k ~mips ppc ppc64 s390 sh sparc x86 ~ppc-aix ~x64-cygwin ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris
LICENSE=BSD-2
RDEPEND=python? ( python_targets_pypy? ( >=virtual/pypy-5:0= ) python_targets_python2_7? ( >=dev-lang/python-2.7.5-r2:2.7 ) python_targets_python3_4? ( dev-lang/python:3.4 ) python_targets_python3_5? ( dev-lang/python:3.5 ) python_targets_python3_6? ( dev-lang/python:3.6 ) >=dev-lang/python-exec-2:=[python_targets_pypy(-)?,python_targets_python2_7(-)?,python_targets_python3_4(-)?,python_targets_python3_5(-)?,python_targets_python3_6(-)?,-python_single_target_pypy(-),-python_single_target_python2_7(-),-python_single_target_python3_4(-),-python_single_target_python3_5(-),-python_single_target_python3_6(-)] dev-python/setuptools[python_targets_pypy(-)?,python_targets_python2_7(-)?,python_targets_python3_4(-)?,python_targets_python3_5(-)?,python_targets_python3_6(-)?,-python_single_target_pypy(-),-python_single_target_python2_7(-),-python_single_target_python3_4(-),-python_single_target_python3_5(-),-python_single_target_python3_6(-)] ) zlib? ( >=sys-libs/zlib-1.2.8-r1[abi_x86_32(-)?,abi_x86_64(-)?,abi_x86_x32(-)?,abi_mips_n32(-)?,abi_mips_n64(-)?,abi_mips_o32(-)?,abi_ppc_32(-)?,abi_ppc_64(-)?,abi_s390_32(-)?,abi_s390_64(-)?] ) python? ( !dev-python/python-magic )
REQUIRED_USE=python? ( || ( python_targets_pypy python_targets_python2_7 python_targets_python3_4 python_targets_python3_5 python_targets_python3_6 ) )
SLOT=0
SRC_URI=ftp://ftp.astron.com/pub/file/file-5.32.tar.gz
SRC_URI=ftp://ftp.astron.com/pub/file/file-5.33.tar.gz
_eclasses_=distutils-r1 63fea93ca1cc4fdc5fa2247afc4e3a15 libtool 0081a71a261724730ec4c248494f044d ltprune 607e058da37aa6dabfa408b7d61da72e multibuild 35719a9cd25ec71ee49c966f6868454c multilib 97f470f374f2e94ccab04a2fb21d811e multilib-build 45f0e78dba7de5c77988265229b4402a multilib-minimal bfa1226d0f1fa0093d10b84acd029633 multiprocessing cac3169468f893670dac3e7cb940e045 python-r1 0b5829eb6369d7af3a834b6eed7b7107 python-utils-r1 ffa9c3284c6b07b8c9f7933911f63812 toolchain-funcs 1e35303c63cd707f6c3422b4493d5607 xdg-utils f2c8335407f0b935b0a96d4adf23ef25
_md5_=cf9df3a682388cb8557e3a7d263b489f
_md5_=2f734cc91d032174af8012af76ddb0aa

View File

@ -3,10 +3,10 @@ DEPEND=python? ( python_targets_pypy? ( >=virtual/pypy-5:0= ) python_targets_pyt
DESCRIPTION=identify a file's format by scanning binary data for patterns
EAPI=6
HOMEPAGE=https://www.darwinsys.com/file/
IUSE=python static-libs zlib python_targets_pypy python_targets_python2_7 python_targets_python3_4 python_targets_python3_5 python_targets_python3_6 abi_x86_32 abi_x86_64 abi_x86_x32 abi_mips_n32 abi_mips_n64 abi_mips_o32 abi_ppc_32 abi_ppc_64 abi_s390_32 abi_s390_64
IUSE=python seccomp static-libs zlib python_targets_pypy python_targets_python2_7 python_targets_python3_4 python_targets_python3_5 python_targets_python3_6 abi_x86_32 abi_x86_64 abi_x86_x32 abi_mips_n32 abi_mips_n64 abi_mips_o32 abi_ppc_32 abi_ppc_64 abi_s390_32 abi_s390_64
LICENSE=BSD-2
RDEPEND=python? ( python_targets_pypy? ( >=virtual/pypy-5:0= ) python_targets_python2_7? ( >=dev-lang/python-2.7.5-r2:2.7 ) python_targets_python3_4? ( dev-lang/python:3.4 ) python_targets_python3_5? ( dev-lang/python:3.5 ) python_targets_python3_6? ( dev-lang/python:3.6 ) >=dev-lang/python-exec-2:=[python_targets_pypy(-)?,python_targets_python2_7(-)?,python_targets_python3_4(-)?,python_targets_python3_5(-)?,python_targets_python3_6(-)?,-python_single_target_pypy(-),-python_single_target_python2_7(-),-python_single_target_python3_4(-),-python_single_target_python3_5(-),-python_single_target_python3_6(-)] dev-python/setuptools[python_targets_pypy(-)?,python_targets_python2_7(-)?,python_targets_python3_4(-)?,python_targets_python3_5(-)?,python_targets_python3_6(-)?,-python_single_target_pypy(-),-python_single_target_python2_7(-),-python_single_target_python3_4(-),-python_single_target_python3_5(-),-python_single_target_python3_6(-)] ) zlib? ( >=sys-libs/zlib-1.2.8-r1[abi_x86_32(-)?,abi_x86_64(-)?,abi_x86_x32(-)?,abi_mips_n32(-)?,abi_mips_n64(-)?,abi_mips_o32(-)?,abi_ppc_32(-)?,abi_ppc_64(-)?,abi_s390_32(-)?,abi_s390_64(-)?] ) python? ( !dev-python/python-magic )
RDEPEND=python? ( python_targets_pypy? ( >=virtual/pypy-5:0= ) python_targets_python2_7? ( >=dev-lang/python-2.7.5-r2:2.7 ) python_targets_python3_4? ( dev-lang/python:3.4 ) python_targets_python3_5? ( dev-lang/python:3.5 ) python_targets_python3_6? ( dev-lang/python:3.6 ) >=dev-lang/python-exec-2:=[python_targets_pypy(-)?,python_targets_python2_7(-)?,python_targets_python3_4(-)?,python_targets_python3_5(-)?,python_targets_python3_6(-)?,-python_single_target_pypy(-),-python_single_target_python2_7(-),-python_single_target_python3_4(-),-python_single_target_python3_5(-),-python_single_target_python3_6(-)] dev-python/setuptools[python_targets_pypy(-)?,python_targets_python2_7(-)?,python_targets_python3_4(-)?,python_targets_python3_5(-)?,python_targets_python3_6(-)?,-python_single_target_pypy(-),-python_single_target_python2_7(-),-python_single_target_python3_4(-),-python_single_target_python3_5(-),-python_single_target_python3_6(-)] ) zlib? ( >=sys-libs/zlib-1.2.8-r1[abi_x86_32(-)?,abi_x86_64(-)?,abi_x86_x32(-)?,abi_mips_n32(-)?,abi_mips_n64(-)?,abi_mips_o32(-)?,abi_ppc_32(-)?,abi_ppc_64(-)?,abi_s390_32(-)?,abi_s390_64(-)?] ) python? ( !dev-python/python-magic ) seccomp? ( sys-libs/libseccomp )
REQUIRED_USE=python? ( || ( python_targets_pypy python_targets_python2_7 python_targets_python3_4 python_targets_python3_5 python_targets_python3_6 ) )
SLOT=0
_eclasses_=autotools d0e5375d47f4c809f406eb892e531513 distutils-r1 63fea93ca1cc4fdc5fa2247afc4e3a15 git-r3 8f6de46b0aa318aea0e8cac62ece098b libtool 0081a71a261724730ec4c248494f044d ltprune 607e058da37aa6dabfa408b7d61da72e multibuild 35719a9cd25ec71ee49c966f6868454c multilib 97f470f374f2e94ccab04a2fb21d811e multilib-build 45f0e78dba7de5c77988265229b4402a multilib-minimal bfa1226d0f1fa0093d10b84acd029633 multiprocessing cac3169468f893670dac3e7cb940e045 python-r1 0b5829eb6369d7af3a834b6eed7b7107 python-utils-r1 ffa9c3284c6b07b8c9f7933911f63812 toolchain-funcs 1e35303c63cd707f6c3422b4493d5607 xdg-utils f2c8335407f0b935b0a96d4adf23ef25
_md5_=75476a9218dec50753f7bf27175420a3
_md5_=c3dc0750468299a2f34a583fe4b95dfd

View File

@ -1 +1 @@
DIST file-5.32.tar.gz 797025 SHA256 8639dc4d1b21e232285cd483604afc4a6ee810710e00e579dbe9591681722b50 SHA512 315343229fa196335389544ee8010e9e80995ef4721938492dedcfb0465dfc45e1feb96f26dfe53cab484fb5d9bac54d2d72917fbfd28a1d998c6ad8c8f9792f WHIRLPOOL 557b1dba186f263f0c3199952e50b2a167cc9c2cf32286e87d9d2e8b31914765a659d167974ece3d8d43701a611d616847b306fcbd506333bdb153ebc07fbcc4
DIST file-5.33.tar.gz 817060 BLAKE2B 735f176f09085243dacaddda1b734ef2191ff1684f08022ed1874e84fd0c84679b5a765383c5c5ad27a7216abc23b9c2211fb7110846122563e18285de0f0e51 SHA512 36c9f2e2aa814b5557eef114fdd3de159688c7a3c9632a9f5c6355c4d2a5694cee81279bda80897616fca07289a7fedb1f797439a2903c76dc84870694773c9e

View File

@ -1,4 +1,4 @@
# Copyright 1999-2017 Gentoo Foundation
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
@ -13,7 +13,7 @@ if [[ ${PV} == "9999" ]] ; then
inherit autotools git-r3
else
SRC_URI="ftp://ftp.astron.com/pub/file/${P}.tar.gz"
KEYWORDS="alpha amd64 arm arm64 hppa ia64 m68k ~mips ppc ppc64 s390 sh sparc x86 ~ppc-aix ~x64-cygwin ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
KEYWORDS="alpha amd64 arm arm64 hppa ia64 m68k ~mips ppc ppc64 s390 sh sparc x86 ~ppc-aix ~x64-cygwin ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
fi
DESCRIPTION="identify a file's format by scanning binary data for patterns"
@ -33,6 +33,8 @@ DEPEND="
RDEPEND="${DEPEND}
python? ( !dev-python/python-magic )"
PATCHES=( "${FILESDIR}"/${P}-CVE-2018-10360.patch )
src_prepare() {
default
@ -45,6 +47,7 @@ src_prepare() {
multilib_src_configure() {
local myeconfargs=(
--disable-libseccomp
--enable-fsect-man5
$(use_enable static-libs static)
$(use_enable zlib)
@ -70,7 +73,7 @@ src_configure() {
LDFLAGS="${BUILD_LDFLAGS} -static" \
CC=${BUILD_CC} \
CXX=${BUILD_CXX} \
econf --disable-shared
econf --disable-shared --disable-libseccomp
fi
multilib-minimal_src_configure
@ -111,6 +114,11 @@ multilib_src_install() {
multilib_src_install_all() {
dodoc ChangeLog MAINT README
# Required for `file -C`
dodir /usr/share/misc/magic
insinto /usr/share/misc/magic
doins -r magic/Magdir/*
if use python ; then
cd python || die
distutils-r1_src_install

View File

@ -1,4 +1,4 @@
# Copyright 1999-2017 Gentoo Foundation
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
@ -13,7 +13,7 @@ if [[ ${PV} == "9999" ]] ; then
inherit autotools git-r3
else
SRC_URI="ftp://ftp.astron.com/pub/file/${P}.tar.gz"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~ppc-aix ~x64-cygwin ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~ppc-aix ~x64-cygwin ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
fi
DESCRIPTION="identify a file's format by scanning binary data for patterns"
@ -21,7 +21,7 @@ HOMEPAGE="https://www.darwinsys.com/file/"
LICENSE="BSD-2"
SLOT="0"
IUSE="python static-libs zlib"
IUSE="python seccomp static-libs zlib"
REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
DEPEND="
@ -31,7 +31,8 @@ DEPEND="
)
zlib? ( >=sys-libs/zlib-1.2.8-r1[${MULTILIB_USEDEP}] )"
RDEPEND="${DEPEND}
python? ( !dev-python/python-magic )"
python? ( !dev-python/python-magic )
seccomp? ( sys-libs/libseccomp )"
src_prepare() {
default
@ -40,12 +41,13 @@ src_prepare() {
elibtoolize
# don't let python README kill main README #60043
mv python/README{,.python} || die
mv python/README.md README.python || die
}
multilib_src_configure() {
local myeconfargs=(
--enable-fsect-man5
$(use_enable seccomp libseccomp)
$(use_enable static-libs static)
$(use_enable zlib)
)
@ -70,7 +72,7 @@ src_configure() {
LDFLAGS="${BUILD_LDFLAGS} -static" \
CC=${BUILD_CC} \
CXX=${BUILD_CXX} \
econf --disable-shared
econf --disable-shared $(use_enable seccomp libseccomp)
fi
multilib-minimal_src_configure
@ -111,6 +113,11 @@ multilib_src_install() {
multilib_src_install_all() {
dodoc ChangeLog MAINT README
# Required for `file -C`
dodir /usr/share/misc/magic
insinto /usr/share/misc/magic
doins -r magic/Magdir/*
if use python ; then
cd python || die
distutils-r1_src_install

View File

@ -0,0 +1,18 @@
Avoid reading past the end of buffer
CVE-2018-10360
https://github.com/file/file/commit/a642587a9c9e2dd7feacdf513c3643ce26ad3c22
--- a/src/readelf.c
+++ b/src/readelf.c
@@ -842,7 +842,8 @@ do_core_note(struct magic_set *ms, unsigned char *nbuf, uint32_t type,
cname = (unsigned char *)
&nbuf[doff + prpsoffsets(i)];
- for (cp = cname; *cp && isprint(*cp); cp++)
+ for (cp = cname; cp < nbuf + size && *cp
+ && isprint(*cp); cp++)
continue;
/*
* Linux apparently appends a space at the end