diff options
author | Alexis Ballier <aballier@gentoo.org> | 2009-05-12 09:05:51 +0000 |
---|---|---|
committer | Alexis Ballier <aballier@gentoo.org> | 2009-05-12 09:05:51 +0000 |
commit | 9da6ad8cc86d8515b9754dc05a317e7eadcaa2b0 (patch) | |
tree | 93db1235c4215d2cd193c0d58e11869ccb31fa34 /sys-freebsd/freebsd-sources | |
parent | x11-libs/libXCalibrate: add missing deps, small clean up (fixes bug #269380) (diff) | |
download | historical-9da6ad8cc86d8515b9754dc05a317e7eadcaa2b0.tar.gz historical-9da6ad8cc86d8515b9754dc05a317e7eadcaa2b0.tar.bz2 historical-9da6ad8cc86d8515b9754dc05a317e7eadcaa2b0.zip |
Add patch for ktimer security issue, bug #263844 and http://security.freebsd.org/advisories/FreeBSD-SA-09:06.ktimer.asc
Package-Manager: portage-2.2_rc33/cvs/Linux x86_64
Diffstat (limited to 'sys-freebsd/freebsd-sources')
-rw-r--r-- | sys-freebsd/freebsd-sources/ChangeLog | 9 | ||||
-rw-r--r-- | sys-freebsd/freebsd-sources/Manifest | 12 | ||||
-rw-r--r-- | sys-freebsd/freebsd-sources/files/freebsd-sources-7.1-ktimer.patch | 18 | ||||
-rw-r--r-- | sys-freebsd/freebsd-sources/freebsd-sources-7.1-r1.ebuild | 105 |
4 files changed, 138 insertions, 6 deletions
diff --git a/sys-freebsd/freebsd-sources/ChangeLog b/sys-freebsd/freebsd-sources/ChangeLog index f40e13ee531a..e49e0a59212b 100644 --- a/sys-freebsd/freebsd-sources/ChangeLog +++ b/sys-freebsd/freebsd-sources/ChangeLog @@ -1,6 +1,13 @@ # ChangeLog for sys-freebsd/freebsd-sources # Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/sys-freebsd/freebsd-sources/ChangeLog,v 1.45 2009/01/22 21:05:47 the_paya Exp $ +# $Header: /var/cvsroot/gentoo-x86/sys-freebsd/freebsd-sources/ChangeLog,v 1.46 2009/05/12 09:05:50 aballier Exp $ + +*freebsd-sources-7.1-r1 (12 May 2009) + + 12 May 2009; Alexis Ballier <aballier@gentoo.org> + +freebsd-sources-7.1-r1.ebuild, +files/freebsd-sources-7.1-ktimer.patch: + Add patch for ktimer security issue, bug #263844 and + http://security.freebsd.org/advisories/FreeBSD-SA-09:06.ktimer.asc *freebsd-sources-7.1 (22 Jan 2009) diff --git a/sys-freebsd/freebsd-sources/Manifest b/sys-freebsd/freebsd-sources/Manifest index 3a1020b6593a..a1bf1a4cbad5 100644 --- a/sys-freebsd/freebsd-sources/Manifest +++ b/sys-freebsd/freebsd-sources/Manifest @@ -26,6 +26,7 @@ AUX freebsd-sources-7.0-tmpfs_whiteout_stub.patch 1015 RMD160 af12f7948ebb3704f6 AUX freebsd-sources-7.0-werror.patch 948 RMD160 8862a2ee66980cc24a5950329e4983fe316d5f7e SHA1 fca026de5887cad2f29298858a1684434edaec34 SHA256 64d576efa55feefda2084ac2254f60318abf9c038db2f9f54df14278eff63d43 AUX freebsd-sources-7.1-asm.patch 4185 RMD160 57c23aa1bc5624e49709ab7d2f47404b52a62d48 SHA1 13465c42d7efcd0aa4138bbef829b389c6819582 SHA256 62724ee4426419dd8057c2fd1a3b22f1dc04df0e64f4785907691a75be2138db AUX freebsd-sources-7.1-binutils_link.patch 1297 RMD160 f0cd329298d0f3d02ca98c56dae73b6570518f1a SHA1 e91a865c7e9874e8ecd244172c19703c9062d16a SHA256 957c03640f3aac6141efa3e775f33fcadd501f920612055d0e00b3f80fcd8f17 +AUX freebsd-sources-7.1-ktimer.patch 605 RMD160 c2299b874db81a13f82b8c56dce1b93b0d92b08d SHA1 477fe455a6dfdf66ae58e519a03310e11c2707cc SHA256 04b1c7d2b2a39c732a081fcff32d71b24eded0dd11b8926eb31315468399cd9e AUX freebsd-sources-7.1-sparc64.patch 513 RMD160 53b026e81bac9942491aa6566332944fbd060435 SHA1 de8ad9175cf9e0b0ed6afe3f3b42c30c790f5fdd SHA256 d5729d425115f4054dfa557df7ed4e333501a337ea27993738fb7711463f5050 AUX freebsd-sources-7.1-subnet-route-pr40133.patch 546 RMD160 b6b1df97612860dbb8d281926f133348a0409f47 SHA1 fd1b1b8637cd49d5d2ae2a6448db66e87f1a2515 SHA256 e9ccfb24bb05122ec939f6ecbbee0447fe9281c3a7d80387402e058315435673 AUX freebsd-sources-7.1-types.h-fix.patch 371 RMD160 d514196ccf1ba246a158b5f421f009d96d2dd8c4 SHA1 b04bec25903446c20bdfd144796fe9924f9ba39f SHA256 9e745fcfe046c405a365d8d0db8763867f0a618952f7d6bab4c76a8c82273473 @@ -34,13 +35,14 @@ DIST freebsd-sys-6.2.tar.bz2 18344936 RMD160 784230e22ccaf09933ef3f053ff29cc3e57 DIST freebsd-sys-7.1.tar.bz2 22471627 RMD160 2e09c51d3ffaaf62bd2fbeed8dd949a1463fab4e SHA1 8c53e0d3e20c52c21e8017b35c6e63a65a72a390 SHA256 336734d3e6e90cfc73e5f6b082a42fd4ccb7141912710e173a7da454159750ce EBUILD freebsd-sources-6.2-r4.ebuild 3301 RMD160 b2d8a7b6702151ad5e2c7a7d171f32b2335fbd0f SHA1 21a5b149e9f76bb4375e6de26659632650fd8900 SHA256 e69bd4a87fdbcfb0e22acaef8462d53dc4c0e892fa92069e1c4975ee0c6821c1 EBUILD freebsd-sources-6.2-r5.ebuild 3965 RMD160 4f877e3779c32711d781d8cd2ed579286c24ab3a SHA1 062afd930996a8bc037712584e9dcd041bf31bcd SHA256 59ff17393a1291a1d67000f1f66d7d4601c5cef644db4b9a0c7da56009ffb2fe +EBUILD freebsd-sources-7.1-r1.ebuild 3722 RMD160 6a07c408e99e4620f25acee38ac9f1443b690627 SHA1 2e2ca68e04283c1efb9d90a97cecf34446dc5d6e SHA256 9aa2081e06054958cde7015b81a9c9f90d51c2902d897429bea362efcff301b2 EBUILD freebsd-sources-7.1.ebuild 3878 RMD160 2f3b47e47240dda0ac0634bf3b372e7d6f5e770f SHA1 025d8da864731e84d603c585ec9df25b8f85050f SHA256 a8186758f67654550057c7fa9d8fcc6574e95b5969f2178d81b93fcd01c37705 -MISC ChangeLog 12947 RMD160 feb9fa03e30b383a4a93619137adbd9466e57eca SHA1 79bf9ed08403575ee1bf2a50a506f3d304128032 SHA256 b26f90d0f0c2aeebcccc0766039e57936f853bfff8f464ff32efa2b02cfe0921 +MISC ChangeLog 13238 RMD160 a975617732dae17de697b4c7c22797ac8a1de597 SHA1 1782318c6f5f52a5b6fb4be543b9ef06474f4e25 SHA256 680a32f71b9286b450578d77365c8919c73ab691f858222de5e7190c7503ef57 MISC metadata.xml 156 RMD160 60b5820a08275f307e5bd936d78f5afd1f141086 SHA1 d9d9d4f2b5afc58339ea3e562fca490156935f1f SHA256 30ab515d6ac492d3d6c36ac3c675511742c2149e56a6b3228c8d22ab8edb3ff7 -----BEGIN PGP SIGNATURE----- -Version: GnuPG v2.0.9 (FreeBSD) +Version: GnuPG v2.0.11 (GNU/Linux) -iEYEARECAAYFAkl437QACgkQoAP6MIsfg8J5rACdER9UVLeX6EuZx2vIj0Zjh534 -rHoAniMnMkuA7Bz+hhaDPJEOg1d2VZ9t -=jwy0 +iEYEARECAAYFAkoJO/UACgkQvFcC4BYPU0pYXgCgmYrviDhR6iuFnhHygqiysiQL +nlMAoL0ZKIbguGXWwh2Z6pSK07YCoufc +=+i4k -----END PGP SIGNATURE----- diff --git a/sys-freebsd/freebsd-sources/files/freebsd-sources-7.1-ktimer.patch b/sys-freebsd/freebsd-sources/files/freebsd-sources-7.1-ktimer.patch new file mode 100644 index 000000000000..5778738771f2 --- /dev/null +++ b/sys-freebsd/freebsd-sources/files/freebsd-sources-7.1-ktimer.patch @@ -0,0 +1,18 @@ +http://security.freebsd.org/advisories/FreeBSD-SA-09:06.ktimer.asc +https://bugs.gentoo.org/show_bug.cgi?id=263844 +CVE-2009-1041 + +Index: sys/kern/kern_time.c +=================================================================== +--- sys/kern/kern_time.c (revision 190192) ++++ sys/kern/kern_time.c (working copy) +@@ -1085,7 +1085,8 @@ + struct itimer *it; + + PROC_LOCK_ASSERT(p, MA_OWNED); +- if ((p->p_itimers == NULL) || (timerid >= TIMER_MAX) || ++ if ((p->p_itimers == NULL) || ++ (timerid < 0) || (timerid >= TIMER_MAX) || + (it = p->p_itimers->its_timers[timerid]) == NULL) { + return (NULL); + } diff --git a/sys-freebsd/freebsd-sources/freebsd-sources-7.1-r1.ebuild b/sys-freebsd/freebsd-sources/freebsd-sources-7.1-r1.ebuild new file mode 100644 index 000000000000..b902a1a31271 --- /dev/null +++ b/sys-freebsd/freebsd-sources/freebsd-sources-7.1-r1.ebuild @@ -0,0 +1,105 @@ +# Copyright 1999-2009 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/sys-freebsd/freebsd-sources/freebsd-sources-7.1-r1.ebuild,v 1.1 2009/05/12 09:05:50 aballier Exp $ + +inherit bsdmk freebsd flag-o-matic + +DESCRIPTION="FreeBSD kernel sources" +SLOT="${PVR}" +KEYWORDS="~sparc-fbsd ~x86-fbsd" + +IUSE="symlink" + +SRC_URI="mirror://gentoo/${SYS}.tar.bz2" + +RDEPEND=">=sys-freebsd/freebsd-mk-defs-7.0" +DEPEND="" + +RESTRICT="strip binchecks" + +S="${WORKDIR}/sys" + +MY_PVR="${PVR}" + +[[ ${MY_PVR} == "${RV}" ]] && MY_PVR="${MY_PVR}-r0" + +src_unpack() { + unpack ${A} + cd "${S}" + + # This replaces the gentoover patch, it doesn't need reapply every time. + sed -i -e 's:^REVISION=.*:REVISION="'${PVR}'":' \ + -e 's:^BRANCH=.*:BRANCH="Gentoo":' \ + -e 's:^VERSION=.*:VERSION="${TYPE} ${BRANCH} ${REVISION}":' \ + "${S}/conf/newvers.sh" + + # __FreeBSD_cc_version comes from FreeBSD's gcc. + # on 7.0-RELEASE it's 700003. + sed -e "s:-D_KERNEL:-D_KERNEL -D__FreeBSD_cc_version=700004:g" \ + -i "${S}/conf/kern.pre.mk" \ + -i "${S}/conf/kmod.mk" || die "Couldn't set __FreeBSD_cc_version" + + epatch "${FILESDIR}/${PN}-7.0-gentoo.patch" + epatch "${FILESDIR}/${PN}-6.0-flex-2.5.31.patch" + epatch "${FILESDIR}/${PN}-7.1-asm.patch" + epatch "${FILESDIR}/${PN}-7.0-werror.patch" + epatch "${FILESDIR}/${PN}-7.1-sparc64.patch" + epatch "${FILESDIR}/${PN}-6.1-ntfs.patch" + epatch "${FILESDIR}/${PN}-6.2-debug-O2.patch" + epatch "${FILESDIR}/${PN}-7.1-types.h-fix.patch" + epatch "${FILESDIR}/${PN}-7.1-subnet-route-pr40133.patch" + epatch "${FILESDIR}/${PN}-7.1-ktimer.patch" + + # Disable SSP for the kernel + grep -Zlr -- -ffreestanding "${S}" | xargs -0 sed -i -e \ + "s:-ffreestanding:-ffreestanding $(test-flags -fno-stack-protector -fno-stack-protector-all):g" + + # By adding -DGENTOO_LIVECD to CFLAGS activate this stub + # vop_whiteout to tmpfs, so it can be used as an overlay + # unionfs filesystem over the cd9660 readonly filesystem. + epatch "${FILESDIR}/${PN}-7.0-tmpfs_whiteout_stub.patch" + + # See http://sourceware.org/bugzilla/show_bug.cgi?id=5391 + # ld doesn't provide symbols constructed as the __start_set_(s) ones + # are on FreeBSD modules. + # This patch adds code to generate a list of these and adds them + # as undefined references to ld's commandline to get them. + # Without this kernel modules will not load. + epatch "${FILESDIR}/${PN}-7.1-binutils_link.patch" +} + +src_compile() { + einfo "Nothing to compile.." +} + +src_install() { + insinto "/usr/src/sys-${MY_PVR}" + doins -r "${S}/"* +} + +pkg_postinst() { + if [[ ! -L "${ROOT}/usr/src/sys" ]]; then + einfo "/usr/src/sys symlink doesn't exist; creating symlink to sys-${MY_PVR}..." + ln -sf "sys-${MY_PVR}" "${ROOT}/usr/src/sys" || \ + eerror "Couldn't create ${ROOT}/usr/src/sys symlink." + # just in case... + [[ -L ""${ROOT}/usr/src/sys-${RV}"" ]] && rm "${ROOT}/usr/src/sys-${RV}" + ln -sf "sys-${MY_PVR}" "${ROOT}/usr/src/sys-${RV}" || \ + eerror "Couldn't create ${ROOT}/usr/src/sys-${RV} symlink." + elif use symlink; then + einfo "Updating /usr/src/sys symlink to sys-${MY_PVR}..." + rm "${ROOT}/usr/src/sys" "${ROOT}/usr/src/sys-${RV}" || \ + eerror "Couldn't remove previous symlinks, please fix manually." + ln -sf "sys-${MY_PVR}" "${ROOT}/usr/src/sys" || \ + eerror "Couldn't create ${ROOT}/usr/src/sys symlink." + ln -sf "sys-${MY_PVR}" "${ROOT}/usr/src/sys-${RV}" || \ + eerror "Couldn't create ${ROOT}/usr/src/sys-${RV} symlink." + fi + + if use sparc-fbsd ; then + ewarn "WARNING: kldload currently causes kernel panics" + ewarn "on sparc64. This is probably a gcc-4.1 issue, but" + ewarn "we need gcc-4.1 to compile the kernel correctly :/" + ewarn "Please compile all modules you need into the kernel" + fi +} |