[arch-commits] Commit in file/repos (6 files)

Sébastien Luttringer seblu at archlinux.org
Wed Nov 12 18:22:45 UTC 2014


    Date: Wednesday, November 12, 2014 @ 19:22:45
  Author: seblu
Revision: 226130

archrelease: copy trunk to testing-i686, testing-x86_64

Added:
  file/repos/testing-i686/
  file/repos/testing-i686/01-cve-2014-3710.patch
    (from rev 226129, file/trunk/01-cve-2014-3710.patch)
  file/repos/testing-i686/PKGBUILD
    (from rev 226129, file/trunk/PKGBUILD)
  file/repos/testing-x86_64/
  file/repos/testing-x86_64/01-cve-2014-3710.patch
    (from rev 226129, file/trunk/01-cve-2014-3710.patch)
  file/repos/testing-x86_64/PKGBUILD
    (from rev 226129, file/trunk/PKGBUILD)

---------------------------------------+
 testing-i686/01-cve-2014-3710.patch   |   18 +++++++++++++++
 testing-i686/PKGBUILD                 |   38 ++++++++++++++++++++++++++++++++
 testing-x86_64/01-cve-2014-3710.patch |   18 +++++++++++++++
 testing-x86_64/PKGBUILD               |   38 ++++++++++++++++++++++++++++++++
 4 files changed, 112 insertions(+)

Copied: file/repos/testing-i686/01-cve-2014-3710.patch (from rev 226129, file/trunk/01-cve-2014-3710.patch)
===================================================================
--- testing-i686/01-cve-2014-3710.patch	                        (rev 0)
+++ testing-i686/01-cve-2014-3710.patch	2014-11-12 18:22:45 UTC (rev 226130)
@@ -0,0 +1,18 @@
+diff --git a/src/readelf.c b/src/readelf.c
+index 08f81f5..9ebdebd 100644
+--- a/src/readelf.c
++++ b/src/readelf.c
+@@ -477,6 +477,13 @@ donote(struct magic_set *ms, void *vbuf, size_t offset, size_t size,
+ 	uint32_t namesz, descsz;
+ 	unsigned char *nbuf = CAST(unsigned char *, vbuf);
+ 
++	if (xnh_sizeof + offset > size) {
++		/*
++		 * We're out of note headers.
++		 */
++		return xnh_sizeof + offset;
++	}
++
+ 	(void)memcpy(xnh_addr, &nbuf[offset], xnh_sizeof);
+ 	offset += xnh_sizeof;
+ 

Copied: file/repos/testing-i686/PKGBUILD (from rev 226129, file/trunk/PKGBUILD)
===================================================================
--- testing-i686/PKGBUILD	                        (rev 0)
+++ testing-i686/PKGBUILD	2014-11-12 18:22:45 UTC (rev 226130)
@@ -0,0 +1,38 @@
+# $Id$
+# Mainainer: Sébastien Luttringer <seblu at archlinux.org>
+# Contributor: Allan McRae <allan at archlinux.org>
+# Contributor: Andreas Radke <andyrtr at archlinux.org>
+
+pkgname=file
+pkgver=5.20
+pkgrel=2
+pkgdesc='File type identification utility'
+arch=('i686' 'x86_64')
+license=('custom')
+groups=('base' 'base-devel')
+url='http://www.darwinsys.com/file/'
+depends=('glibc' 'zlib')
+source=("ftp://ftp.astron.com/pub/$pkgname/$pkgname-$pkgver.tar.gz"
+		'01-cve-2014-3710.patch')
+md5sums=('5d5e13eb3e0e13839da869a31790faf2'
+         'dde0002f513f44c4ef6c2152f0ece4ed')
+
+prepare() {
+  # https://bugs.archlinux.org/task/42759
+  patch -p1 -d $pkgname-$pkgver < '01-cve-2014-3710.patch'
+}
+
+build() {
+  cd $pkgname-$pkgver
+  ./configure --prefix=/usr --datadir=/usr/share/file
+  make
+}
+
+package() {
+  cd $pkgname-$pkgver
+  make DESTDIR="$pkgdir" install
+  install -Dm644 COPYING "$pkgdir/usr/share/licenses/$pkgname/COPYING"
+  rmdir "$pkgdir/usr/share/man/man5"
+}
+
+# vim:set ts=2 sw=2 et:

Copied: file/repos/testing-x86_64/01-cve-2014-3710.patch (from rev 226129, file/trunk/01-cve-2014-3710.patch)
===================================================================
--- testing-x86_64/01-cve-2014-3710.patch	                        (rev 0)
+++ testing-x86_64/01-cve-2014-3710.patch	2014-11-12 18:22:45 UTC (rev 226130)
@@ -0,0 +1,18 @@
+diff --git a/src/readelf.c b/src/readelf.c
+index 08f81f5..9ebdebd 100644
+--- a/src/readelf.c
++++ b/src/readelf.c
+@@ -477,6 +477,13 @@ donote(struct magic_set *ms, void *vbuf, size_t offset, size_t size,
+ 	uint32_t namesz, descsz;
+ 	unsigned char *nbuf = CAST(unsigned char *, vbuf);
+ 
++	if (xnh_sizeof + offset > size) {
++		/*
++		 * We're out of note headers.
++		 */
++		return xnh_sizeof + offset;
++	}
++
+ 	(void)memcpy(xnh_addr, &nbuf[offset], xnh_sizeof);
+ 	offset += xnh_sizeof;
+ 

Copied: file/repos/testing-x86_64/PKGBUILD (from rev 226129, file/trunk/PKGBUILD)
===================================================================
--- testing-x86_64/PKGBUILD	                        (rev 0)
+++ testing-x86_64/PKGBUILD	2014-11-12 18:22:45 UTC (rev 226130)
@@ -0,0 +1,38 @@
+# $Id$
+# Mainainer: Sébastien Luttringer <seblu at archlinux.org>
+# Contributor: Allan McRae <allan at archlinux.org>
+# Contributor: Andreas Radke <andyrtr at archlinux.org>
+
+pkgname=file
+pkgver=5.20
+pkgrel=2
+pkgdesc='File type identification utility'
+arch=('i686' 'x86_64')
+license=('custom')
+groups=('base' 'base-devel')
+url='http://www.darwinsys.com/file/'
+depends=('glibc' 'zlib')
+source=("ftp://ftp.astron.com/pub/$pkgname/$pkgname-$pkgver.tar.gz"
+		'01-cve-2014-3710.patch')
+md5sums=('5d5e13eb3e0e13839da869a31790faf2'
+         'dde0002f513f44c4ef6c2152f0ece4ed')
+
+prepare() {
+  # https://bugs.archlinux.org/task/42759
+  patch -p1 -d $pkgname-$pkgver < '01-cve-2014-3710.patch'
+}
+
+build() {
+  cd $pkgname-$pkgver
+  ./configure --prefix=/usr --datadir=/usr/share/file
+  make
+}
+
+package() {
+  cd $pkgname-$pkgver
+  make DESTDIR="$pkgdir" install
+  install -Dm644 COPYING "$pkgdir/usr/share/licenses/$pkgname/COPYING"
+  rmdir "$pkgdir/usr/share/man/man5"
+}
+
+# vim:set ts=2 sw=2 et:


More information about the arch-commits mailing list