summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNP-Hardass <NP-Hardass@gentoo.org>2015-08-13 19:02:36 -0400
committerNP-Hardass <NP-Hardass@gentoo.org>2015-08-13 19:19:37 -0400
commit526f3a75301840d7e04e436ca06aaa341b006d2c (patch)
tree70dba56886b8e53dc7616b20337979339705b4af /net-fs/openafs-kernel
parentdev-java/javacsv: Move package from overlay to the tree. Fixes bug 217500. (diff)
downloadgentoo-526f3a75301840d7e04e436ca06aaa341b006d2c.tar.gz
gentoo-526f3a75301840d7e04e436ca06aaa341b006d2c.tar.bz2
gentoo-526f3a75301840d7e04e436ca06aaa341b006d2c.zip
net-fs/openafs{,-kernel}: Resolves bug #556354 and bug #425352
Patches for CVE-2015-{3282,3283,3284,3285,3286,3287} FreeBSD ebuild code backported to all versions in the newly created -r1s
Diffstat (limited to 'net-fs/openafs-kernel')
-rw-r--r--net-fs/openafs-kernel/Manifest1
-rw-r--r--net-fs/openafs-kernel/openafs-kernel-1.6.11-r1.ebuild125
-rw-r--r--net-fs/openafs-kernel/openafs-kernel-1.6.11.1-r1.ebuild125
-rw-r--r--net-fs/openafs-kernel/openafs-kernel-1.6.12-r1.ebuild125
4 files changed, 376 insertions, 0 deletions
diff --git a/net-fs/openafs-kernel/Manifest b/net-fs/openafs-kernel/Manifest
index b08b12942f08..703a6891a39c 100644
--- a/net-fs/openafs-kernel/Manifest
+++ b/net-fs/openafs-kernel/Manifest
@@ -9,3 +9,4 @@ DIST openafs-1.6.13-doc.tar.bz2 3501580 SHA256 a0517efcb665efc70ac0813256730443b
DIST openafs-1.6.13-src.tar.bz2 14373447 SHA256 6139370633b48f0149d4dacdd01af7ee29b800b0866c2d18a679c1669e317b26 SHA512 1c50ff5c482be76af8ca1a62bd4d0402c33f8107b8ee5bcbf2b582b734619a26ba54ec49251360583a5d1b3e43827314742e7fe1aee95223c995730e9e00d887 WHIRLPOOL 6cffed9877a27531f7eb49857bdc7bead44fa804b7be36e983dffeb6587cadc1a7372502cd83072b8f3c63c67151ac807e83bdb0e2a6e4fec4042f557937c98c
DIST openafs-patches-20150503.tar.xz 9736 SHA256 066f61fe795e2cb3235a0a991abe8c5e876758bae7ea9bec61e98a3f601c9d7d SHA512 c687be78c7a6442b81c1362cab6ba215301911bdefcf39d2758ffeddecfa3efaa67990ea8277bbc1dedc14ad70a33213a37dbc45c43cd53871eec089759596c6 WHIRLPOOL 0935946c9a535f8e9ce6dd292801c671aef1c40f2a3f51aa4a85e5f4181fb46c3b2df55be56eec56c7fcab0eaf27d97cc6cef98c1b70178ba8cd7258174036cf
DIST openafs-patches-20150626.tar.xz 10588 SHA256 b221842e82e4807e6b8064454df3792b12f3d73104462d83aa88c79e3028fb4a SHA512 b77df9dc734965301585d5f66732fef119282e49cbd5c121f45aa9f0b64fc6c62e1cd93c8b7ff81702f6baece0df3cf9d99ab796e84f2c0c610dc2e2fd3cedf6 WHIRLPOOL 71778ab6f64a156f8f559d446e09cbb8278f2f0965225a21767a2a28883e228620c37241cd439426a3163ede8b04f676f2b4aea7c14394c82bdc47dc2643e6b2
+DIST openafs-patches-20150813.tar.xz 15520 SHA256 209766f5e97e924eab91d862875f360e0ed9821b317ee609789a77d7fbdeb8f0 SHA512 2703f65e7c3f1a724e9330d8f2aedf80f9d0b8ba4b03a5f466cd523eb8d0a1692542df722b24e06ce4ced476fb8615e2caca6159de7b18f151ecf7a14a5f0565 WHIRLPOOL c4055a7c0cf19847ecd8679316a0146b41589f157996b2f15b807d272270e65c1a6ee5f916d3127803cd26370c392b1e751d100d2ab383a57530b768e1682d60
diff --git a/net-fs/openafs-kernel/openafs-kernel-1.6.11-r1.ebuild b/net-fs/openafs-kernel/openafs-kernel-1.6.11-r1.ebuild
new file mode 100644
index 000000000000..30a7cf6763ef
--- /dev/null
+++ b/net-fs/openafs-kernel/openafs-kernel-1.6.11-r1.ebuild
@@ -0,0 +1,125 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI="5"
+
+inherit autotools eutils linux-mod multilib toolchain-funcs versionator
+
+MY_PV=$(delete_version_separator '_')
+MY_PN="${PN/-kernel}"
+MY_P="${MY_PN}-${MY_PV}"
+PVER="20150813"
+
+DESCRIPTION="The OpenAFS distributed file system kernel module"
+HOMEPAGE="http://www.openafs.org/"
+# We always d/l the doc tarball as man pages are not USE=doc material
+[[ ${PV} == *_pre* ]] && MY_PRE="candidate/" || MY_PRE=""
+SRC_URI="
+ http://openafs.org/dl/openafs/${MY_PRE}${MY_PV}/${MY_P}-src.tar.bz2
+ http://openafs.org/dl/openafs/${MY_PV}/${MY_P}-doc.tar.bz2
+ http://dev.gentoo.org/~bircoph/afs/${MY_PN}-patches-${PVER}.tar.xz
+"
+
+LICENSE="IBM BSD openafs-krb5-a APSL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~amd64-fbsd ~amd64-linux ~sparc ~x86 ~x86-fbsd ~x86-linux"
+IUSE=""
+
+S=${WORKDIR}/${MY_P}
+
+CONFIG_CHECK="!DEBUG_RODATA ~!AFS_FS KEYS"
+ERROR_DEBUG_RODATA="OpenAFS is incompatible with linux' CONFIG_DEBUG_RODATA option"
+ERROR_AFS_FS="OpenAFS conflicts with the in-kernel AFS-support. Make sure not to load both at the same time!"
+ERROR_KEYS="OpenAFS needs CONFIG_KEYS option enabled"
+
+QA_TEXTRELS_x86_fbsd="/boot/modules/libafs.ko"
+QA_TEXTRELS_amd64_fbsd="/boot/modules/libafs.ko"
+
+pkg_pretend() {
+ if use kernel_linux && kernel_is ge 4 ; then
+ ewarn "Gentoo supports kernels which are supported by OpenAFS"
+ ewarn "which are limited to the kernel versions: <4.0"
+ ewarn ""
+ ewarn "You are free to utilize epatch_user to provide whatever"
+ ewarn "support you feel is appropriate, but will not receive"
+ ewarn "support as a result of those changes."
+ ewarn ""
+ ewarn "Please do not file a bug report about this."
+ fi
+}
+
+pkg_setup() {
+ if use kernel_linux; then
+ linux-mod_pkg_setup
+ fi
+}
+
+src_prepare() {
+ # do not tamper with CFLAGS for the kernel module
+ EPATCH_EXCLUDE="040_all_flags.patch" \
+ EPATCH_SUFFIX="patch" \
+ epatch "${WORKDIR}"/gentoo/patches
+ epatch "${WORKDIR}"/gentoo/security-patches/CVE-2015-{3282..3287}.patch
+ epatch_user
+
+ # packaging is f-ed up, so we can't run eautoreconf
+ # run autotools commands based on what is listed in regen.sh
+ eaclocal -I src/cf
+ eautoconf
+ eautoconf -o configure-libafs configure-libafs.ac
+ eautoheader
+ einfo "Deleting autom4te.cache directory"
+ rm -rf autom4te.cache
+}
+
+src_configure() {
+ local myconf=""
+ # OpenAFS 1.6.11 has a bug with kernels 3.17-3.17.2 that requires a config option
+ if use kernel_linux && kernel_is -ge 3 17 && kernel_is -le 3 17 2; then
+ myconf="--enable-linux-d_splice_alias-extra-iput"
+ fi
+
+ local ARCH="$(tc-arch-kernel)"
+ local MY_ARCH="$(tc-arch)"
+ local BSD_BUILD_DIR="/usr/src/sys/${MY_ARCH}/compile/GENERIC"
+
+ if use kernel_linux; then
+ myconf+=( --with-linux-kernel-headers="${KV_DIR}" \
+ --with-linux-kernel-build="${KV_OUT_DIR}"
+ )
+ elif use kernel_FreeBSD; then
+ myconf+=( --with-bsd-kernel-build="${BSD_BUILD_DIR}" )
+ fi
+ econf "${myconf[@]}"
+}
+
+src_compile() {
+ ARCH="$(tc-arch-kernel)" AR="$(tc-getAR)" emake V=1 -j1 only_libafs
+}
+
+src_install() {
+ if use kernel_linux; then
+ local srcdir=$(expr "${S}"/src/libafs/MODLOAD-*)
+ [[ -f ${srcdir}/libafs.${KV_OBJ} ]] || die "Couldn't find compiled kernel module"
+
+ MODULE_NAMES="libafs(fs/openafs:${srcdir})"
+
+ linux-mod_src_install
+ elif use kernel_FreeBSD; then
+ insinto /boot/modules
+ doins "${S}"/src/libafs/MODLOAD/libafs.ko
+ fi
+}
+
+pkg_postinst() {
+ # Update linker.hints file
+ use kernel_FreeBSD && /usr/sbin/kldxref "${EPREFIX}/boot/modules"
+ use kernel_linux && linux-mod_pkg_postinst
+}
+
+pkg_postrm() {
+ # Update linker.hints file
+ use kernel_FreeBSD && /usr/sbin/kldxref "${EPREFIX}/boot/modules"
+ use kernel_linux && linux-mod_pkg_postrm
+}
diff --git a/net-fs/openafs-kernel/openafs-kernel-1.6.11.1-r1.ebuild b/net-fs/openafs-kernel/openafs-kernel-1.6.11.1-r1.ebuild
new file mode 100644
index 000000000000..068ea99e22e5
--- /dev/null
+++ b/net-fs/openafs-kernel/openafs-kernel-1.6.11.1-r1.ebuild
@@ -0,0 +1,125 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI="5"
+
+inherit autotools eutils linux-mod multilib toolchain-funcs versionator
+
+MY_PV=$(delete_version_separator '_')
+MY_PN="${PN/-kernel}"
+MY_P="${MY_PN}-${MY_PV}"
+PVER="20150813"
+
+DESCRIPTION="The OpenAFS distributed file system kernel module"
+HOMEPAGE="http://www.openafs.org/"
+# We always d/l the doc tarball as man pages are not USE=doc material
+[[ ${PV} == *_pre* ]] && MY_PRE="candidate/" || MY_PRE=""
+SRC_URI="
+ http://openafs.org/dl/openafs/${MY_PRE}${MY_PV}/${MY_P}-src.tar.bz2
+ http://openafs.org/dl/openafs/${MY_PV}/${MY_P}-doc.tar.bz2
+ http://dev.gentoo.org/~bircoph/afs/${MY_PN}-patches-${PVER}.tar.xz
+"
+
+LICENSE="IBM BSD openafs-krb5-a APSL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~amd64-fbsd ~amd64-linux ~sparc ~x86 ~x86-fbsd ~x86-linux"
+IUSE=""
+
+S=${WORKDIR}/${MY_P}
+
+CONFIG_CHECK="!DEBUG_RODATA ~!AFS_FS KEYS"
+ERROR_DEBUG_RODATA="OpenAFS is incompatible with linux' CONFIG_DEBUG_RODATA option"
+ERROR_AFS_FS="OpenAFS conflicts with the in-kernel AFS-support. Make sure not to load both at the same time!"
+ERROR_KEYS="OpenAFS needs CONFIG_KEYS option enabled"
+
+QA_TEXTRELS_x86_fbsd="/boot/modules/libafs.ko"
+QA_TEXTRELS_amd64_fbsd="/boot/modules/libafs.ko"
+
+pkg_pretend() {
+ if use kernel_linux && kernel_is ge 4 1 ; then
+ ewarn "Gentoo supports kernels which are supported by OpenAFS"
+ ewarn "which are limited to the kernel versions: <4.1"
+ ewarn ""
+ ewarn "You are free to utilize epatch_user to provide whatever"
+ ewarn "support you feel is appropriate, but will not receive"
+ ewarn "support as a result of those changes."
+ ewarn ""
+ ewarn "Please do not file a bug report about this."
+ fi
+}
+
+pkg_setup() {
+ if use kernel_linux; then
+ linux-mod_pkg_setup
+ fi
+}
+
+src_prepare() {
+ # do not tamper with CFLAGS for the kernel module
+ EPATCH_EXCLUDE="040_all_flags.patch" \
+ EPATCH_SUFFIX="patch" \
+ epatch "${WORKDIR}"/gentoo/patches
+ epatch "${WORKDIR}"/gentoo/security-patches/CVE-2015-{3282..3287}.patch
+ epatch_user
+
+ # packaging is f-ed up, so we can't run eautoreconf
+ # run autotools commands based on what is listed in regen.sh
+ eaclocal -I src/cf
+ eautoconf
+ eautoconf -o configure-libafs configure-libafs.ac
+ eautoheader
+ einfo "Deleting autom4te.cache directory"
+ rm -rf autom4te.cache
+}
+
+src_configure() {
+ local myconf=""
+ # OpenAFS 1.6.11 has a bug with kernels 3.17-3.17.2 that requires a config option
+ if use kernel_linux && kernel_is -ge 3 17 && kernel_is -le 3 17 2; then
+ myconf="--enable-linux-d_splice_alias-extra-iput"
+ fi
+
+ local ARCH="$(tc-arch-kernel)"
+ local MY_ARCH="$(tc-arch)"
+ local BSD_BUILD_DIR="/usr/src/sys/${MY_ARCH}/compile/GENERIC"
+
+ if use kernel_linux; then
+ myconf+=( --with-linux-kernel-headers="${KV_DIR}" \
+ --with-linux-kernel-build="${KV_OUT_DIR}"
+ )
+ elif use kernel_FreeBSD; then
+ myconf+=( --with-bsd-kernel-build="${BSD_BUILD_DIR}" )
+ fi
+ econf "${myconf[@]}"
+}
+
+src_compile() {
+ ARCH="$(tc-arch-kernel)" AR="$(tc-getAR)" emake V=1 -j1 only_libafs
+}
+
+src_install() {
+ if use kernel_linux; then
+ local srcdir=$(expr "${S}"/src/libafs/MODLOAD-*)
+ [[ -f ${srcdir}/libafs.${KV_OBJ} ]] || die "Couldn't find compiled kernel module"
+
+ MODULE_NAMES="libafs(fs/openafs:${srcdir})"
+
+ linux-mod_src_install
+ elif use kernel_FreeBSD; then
+ insinto /boot/modules
+ doins "${S}"/src/libafs/MODLOAD/libafs.ko
+ fi
+}
+
+pkg_postinst() {
+ # Update linker.hints file
+ use kernel_FreeBSD && /usr/sbin/kldxref "${EPREFIX}/boot/modules"
+ use kernel_linux && linux-mod_pkg_postinst
+}
+
+pkg_postrm() {
+ # Update linker.hints file
+ use kernel_FreeBSD && /usr/sbin/kldxref "${EPREFIX}/boot/modules"
+ use kernel_linux && linux-mod_pkg_postrm
+}
diff --git a/net-fs/openafs-kernel/openafs-kernel-1.6.12-r1.ebuild b/net-fs/openafs-kernel/openafs-kernel-1.6.12-r1.ebuild
new file mode 100644
index 000000000000..7e474e15bf89
--- /dev/null
+++ b/net-fs/openafs-kernel/openafs-kernel-1.6.12-r1.ebuild
@@ -0,0 +1,125 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI="5"
+
+inherit autotools eutils linux-mod multilib toolchain-funcs versionator
+
+MY_PV=$(delete_version_separator '_')
+MY_PN="${PN/-kernel}"
+MY_P="${MY_PN}-${MY_PV}"
+PVER="20150813"
+
+DESCRIPTION="The OpenAFS distributed file system kernel module"
+HOMEPAGE="http://www.openafs.org/"
+# We always d/l the doc tarball as man pages are not USE=doc material
+[[ ${PV} == *_pre* ]] && MY_PRE="candidate/" || MY_PRE=""
+SRC_URI="
+ http://openafs.org/dl/openafs/${MY_PRE}${MY_PV}/${MY_P}-src.tar.bz2
+ http://openafs.org/dl/openafs/${MY_PV}/${MY_P}-doc.tar.bz2
+ http://dev.gentoo.org/~bircoph/afs/${MY_PN}-patches-${PVER}.tar.xz
+"
+
+LICENSE="IBM BSD openafs-krb5-a APSL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~amd64-fbsd ~amd64-linux ~sparc ~x86 ~x86-fbsd ~x86-linux"
+IUSE=""
+
+S=${WORKDIR}/${MY_P}
+
+CONFIG_CHECK="!DEBUG_RODATA ~!AFS_FS KEYS"
+ERROR_DEBUG_RODATA="OpenAFS is incompatible with linux' CONFIG_DEBUG_RODATA option"
+ERROR_AFS_FS="OpenAFS conflicts with the in-kernel AFS-support. Make sure not to load both at the same time!"
+ERROR_KEYS="OpenAFS needs CONFIG_KEYS option enabled"
+
+QA_TEXTRELS_x86_fbsd="/boot/modules/libafs.ko"
+QA_TEXTRELS_amd64_fbsd="/boot/modules/libafs.ko"
+
+pkg_pretend() {
+ if use kernel_linux && kernel_is ge 4 2 ; then
+ ewarn "Gentoo supports kernels which are supported by OpenAFS"
+ ewarn "which are limited to the kernel versions: <4.2"
+ ewarn ""
+ ewarn "You are free to utilize epatch_user to provide whatever"
+ ewarn "support you feel is appropriate, but will not receive"
+ ewarn "support as a result of those changes."
+ ewarn ""
+ ewarn "Please do not file a bug report about this."
+ fi
+}
+
+pkg_setup() {
+ if use kernel_linux; then
+ linux-mod_pkg_setup
+ fi
+}
+
+src_prepare() {
+ # do not tamper with CFLAGS for the kernel module
+ EPATCH_EXCLUDE="040_all_flags.patch" \
+ EPATCH_SUFFIX="patch" \
+ epatch "${WORKDIR}"/gentoo/patches
+ epatch "${WORKDIR}"/gentoo/security-patches/CVE-2015-{3282..3287}.patch
+ epatch_user
+
+ # packaging is f-ed up, so we can't run eautoreconf
+ # run autotools commands based on what is listed in regen.sh
+ eaclocal -I src/cf
+ eautoconf
+ eautoconf -o configure-libafs configure-libafs.ac
+ eautoheader
+ einfo "Deleting autom4te.cache directory"
+ rm -rf autom4te.cache
+}
+
+src_configure() {
+ local myconf=""
+ # OpenAFS 1.6.11 has a bug with kernels 3.17-3.17.2 that requires a config option
+ if use kernel_linux && kernel_is -ge 3 17 && kernel_is -le 3 17 2; then
+ myconf="--enable-linux-d_splice_alias-extra-iput"
+ fi
+
+ local ARCH="$(tc-arch-kernel)"
+ local MY_ARCH="$(tc-arch)"
+ local BSD_BUILD_DIR="/usr/src/sys/${MY_ARCH}/compile/GENERIC"
+
+ if use kernel_linux; then
+ myconf+=( --with-linux-kernel-headers="${KV_DIR}" \
+ --with-linux-kernel-build="${KV_OUT_DIR}"
+ )
+ elif use kernel_FreeBSD; then
+ myconf+=( --with-bsd-kernel-build="${BSD_BUILD_DIR}" )
+ fi
+ econf "${myconf[@]}"
+}
+
+src_compile() {
+ ARCH="$(tc-arch-kernel)" AR="$(tc-getAR)" emake V=1 -j1 only_libafs
+}
+
+src_install() {
+ if use kernel_linux; then
+ local srcdir=$(expr "${S}"/src/libafs/MODLOAD-*)
+ [[ -f ${srcdir}/libafs.${KV_OBJ} ]] || die "Couldn't find compiled kernel module"
+
+ MODULE_NAMES="libafs(fs/openafs:${srcdir})"
+
+ linux-mod_src_install
+ elif use kernel_FreeBSD; then
+ insinto /boot/modules
+ doins "${S}"/src/libafs/MODLOAD/libafs.ko
+ fi
+}
+
+pkg_postinst() {
+ # Update linker.hints file
+ use kernel_FreeBSD && /usr/sbin/kldxref "${EPREFIX}/boot/modules"
+ use kernel_linux && linux-mod_pkg_postinst
+}
+
+pkg_postrm() {
+ # Update linker.hints file
+ use kernel_FreeBSD && /usr/sbin/kldxref "${EPREFIX}/boot/modules"
+ use kernel_linux && linux-mod_pkg_postrm
+}