* [gentoo-commits] proj/hardened-dev:master commit in: sys-boot/tboot/, sys-boot/tboot/files/
@ 2015-05-04 22:31 Jason Zaman
0 siblings, 0 replies; 2+ messages in thread
From: Jason Zaman @ 2015-05-04 22:31 UTC (permalink / raw
To: gentoo-commits
commit: 7b54b19888a5f531159259c54e9fb402f879fedc
Author: Jason Zaman <jason <AT> perfinion <DOT> com>
AuthorDate: Mon May 4 22:23:55 2015 +0000
Commit: Jason Zaman <perfinion <AT> gentoo <DOT> org>
CommitDate: Mon May 4 22:29:46 2015 +0000
URL: https://gitweb.gentoo.org/proj/hardened-dev.git/commit/?id=7b54b198
tboot: fstack-check=no on hardened
...-genkernel_arch.patch => tboot-1.8.2-genkernel_arch.patch} | 0
sys-boot/tboot/files/tboot-1.8.2-stack-check-no.patch | 11 +++++++++++
sys-boot/tboot/metadata.xml | 3 +--
sys-boot/tboot/tboot-1.8.2.ebuild | 10 +++++-----
4 files changed, 17 insertions(+), 7 deletions(-)
diff --git a/sys-boot/tboot/files/1.8.2-genkernel_arch.patch b/sys-boot/tboot/files/tboot-1.8.2-genkernel_arch.patch
similarity index 100%
rename from sys-boot/tboot/files/1.8.2-genkernel_arch.patch
rename to sys-boot/tboot/files/tboot-1.8.2-genkernel_arch.patch
diff --git a/sys-boot/tboot/files/tboot-1.8.2-stack-check-no.patch b/sys-boot/tboot/files/tboot-1.8.2-stack-check-no.patch
new file mode 100644
index 0000000..5d2ea62
--- /dev/null
+++ b/sys-boot/tboot/files/tboot-1.8.2-stack-check-no.patch
@@ -0,0 +1,11 @@
+diff -ur tboot-1.8.2.orig/tboot/Config.mk tboot-1.8.2/tboot/Config.mk
+--- tboot-1.8.2.orig/tboot/Config.mk 2014-07-28 12:24:21.000000000 +0400
++++ tboot-1.8.2/tboot/Config.mk 2015-05-05 02:14:26.333222301 +0400
+@@ -30,6 +30,7 @@
+ CFLAGS += $(call cc-option,$(CC),-nopie,)
+ CFLAGS += $(call cc-option,$(CC),-fno-stack-protector,)
+ CFLAGS += $(call cc-option,$(CC),-fno-stack-protector-all,)
++CFLAGS += $(call cc-option,$(CC),-fstack-check=no,)
+
+ # changeset variable for banner
+ CFLAGS += -DTBOOT_CHANGESET=\""$(shell ((hg parents --template "{isodate|isodate} {rev}:{node|short}" >/dev/null && hg parents --template "{isodate|isodate} {rev}:{node|short}") || echo "2014-07-28 12:00 +0800 1.8.2") 2>/dev/null)"\"
diff --git a/sys-boot/tboot/metadata.xml b/sys-boot/tboot/metadata.xml
index 690f61c..51ab1be 100644
--- a/sys-boot/tboot/metadata.xml
+++ b/sys-boot/tboot/metadata.xml
@@ -1,9 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
- <herd>hardened</herd>
<maintainer>
- <email>jason@perfinion.com</email>
+ <email>perfinion@gentoo.org</email>
<name>Jason Zaman</name>
</maintainer>
diff --git a/sys-boot/tboot/tboot-1.8.2.ebuild b/sys-boot/tboot/tboot-1.8.2.ebuild
index 9432230..389c93c 100644
--- a/sys-boot/tboot/tboot-1.8.2.ebuild
+++ b/sys-boot/tboot/tboot-1.8.2.ebuild
@@ -26,14 +26,14 @@ sys-boot/grub:2"
DOCS=(README COPYING CHANGELOG)
src_prepare() {
- epatch "${FILESDIR}/1.8.2-genkernel_arch.patch"
+ epatch "${FILESDIR}/${P}-genkernel_arch.patch"
+ epatch "${FILESDIR}/${P}-stack-check-no.patch" # breaks with ssp
+ sed -i 's/ -Werror//g' Config.mk
+ sed -i 's/^INSTALL_STRIP = -s$//' Config.mk # QA Errors
# the version number is wrong in the grub files
sed -i 's/tboot_version="1.8.1"/tboot_version="1.8.2"/' tboot/20_linux*tboot
- sed -i 's/ -Werror//g' Config.mk
- sed -i 's/^INSTALL_STRIP = -s$//' Config.mk # QA Errors
-
epatch_user
}
@@ -46,7 +46,7 @@ src_compile() {
MAKEARGS="TARGET_ARCH=i686"
fi
- emake ${MAKEARGS} build
+ emake debug=y ${MAKEARGS} build
}
src_install() {
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [gentoo-commits] proj/hardened-dev:master commit in: sys-boot/tboot/, sys-boot/tboot/files/
@ 2015-05-06 23:27 Jason Zaman
0 siblings, 0 replies; 2+ messages in thread
From: Jason Zaman @ 2015-05-06 23:27 UTC (permalink / raw
To: gentoo-commits
commit: 3bf93797179b43e8d97a66356a9bddefe44d1ccf
Author: Jason Zaman <jason <AT> perfinion <DOT> com>
AuthorDate: Wed May 6 23:26:58 2015 +0000
Commit: Jason Zaman <perfinion <AT> gentoo <DOT> org>
CommitDate: Wed May 6 23:27:46 2015 +0000
URL: https://gitweb.gentoo.org/proj/hardened-dev.git/commit/?id=3bf93797
tboot: add pcid disable patch
.../tboot/files/tboot-1.8.2-disable-pcid.patch | 26 ++++++++++++++++++++++
sys-boot/tboot/tboot-1.8.2.ebuild | 9 ++++----
2 files changed, 31 insertions(+), 4 deletions(-)
diff --git a/sys-boot/tboot/files/tboot-1.8.2-disable-pcid.patch b/sys-boot/tboot/files/tboot-1.8.2-disable-pcid.patch
new file mode 100644
index 0000000..383338e
--- /dev/null
+++ b/sys-boot/tboot/files/tboot-1.8.2-disable-pcid.patch
@@ -0,0 +1,26 @@
+diff -ur tboot-1.8.2.orig/tboot/common/shutdown.S tboot-1.8.2/tboot/common/shutdown.S
+--- tboot-1.8.2.orig/tboot/common/shutdown.S 2014-07-28 12:24:22.000000000 +0400
++++ tboot-1.8.2/tboot/common/shutdown.S 2015-05-07 03:05:47.300985413 +0400
+@@ -34,6 +34,11 @@
+ */
+
+ compat_mode_entry:
++ /* Disable PCID */
++ movl %cr4, %eax
++ andl $~CR4_PCIDE, %eax
++ movl %eax, %cr4
++
+ /* Disable paging and therefore leave 64 bit mode. */
+ movl %cr0, %eax
+ andl $~CR0_PG, %eax
+diff -ur tboot-1.8.2.orig/tboot/include/processor.h tboot-1.8.2/tboot/include/processor.h
+--- tboot-1.8.2.orig/tboot/include/processor.h 2014-07-28 12:24:22.000000000 +0400
++++ tboot-1.8.2/tboot/include/processor.h 2015-05-07 03:04:58.721244858 +0400
+@@ -92,6 +92,7 @@
+ #define CR4_XMM 0x00000400 /* enable SIMD/MMX2 to use except 16 */
+ #define CR4_VMXE 0x00002000/* enable VMX */
+ #define CR4_SMXE 0x00004000/* enable SMX */
++#define CR4_PCIDE 0x00020000/* enable PCID */
+
+ #ifndef __ASSEMBLY__
+
diff --git a/sys-boot/tboot/tboot-1.8.2.ebuild b/sys-boot/tboot/tboot-1.8.2.ebuild
index 389c93c..bcfc004 100644
--- a/sys-boot/tboot/tboot-1.8.2.ebuild
+++ b/sys-boot/tboot/tboot-1.8.2.ebuild
@@ -26,10 +26,11 @@ sys-boot/grub:2"
DOCS=(README COPYING CHANGELOG)
src_prepare() {
- epatch "${FILESDIR}/${P}-genkernel_arch.patch"
- epatch "${FILESDIR}/${P}-stack-check-no.patch" # breaks with ssp
- sed -i 's/ -Werror//g' Config.mk
- sed -i 's/^INSTALL_STRIP = -s$//' Config.mk # QA Errors
+ epatch "${FILESDIR}/tboot-1.8.2-genkernel_arch.patch"
+ epatch "${FILESDIR}/tboot-1.8.2-stack-check-no.patch" # breaks with ssp
+ epatch "${FILESDIR}/tboot-1.8.2-disable-pcid.patch" # PaX enables pcid
+ sed -i 's/ -Werror//g' Config.mk || die
+ sed -i 's/^INSTALL_STRIP = -s$//' Config.mk || die # QA Errors
# the version number is wrong in the grub files
sed -i 's/tboot_version="1.8.1"/tboot_version="1.8.2"/' tboot/20_linux*tboot
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2015-05-06 23:28 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-05-04 22:31 [gentoo-commits] proj/hardened-dev:master commit in: sys-boot/tboot/, sys-boot/tboot/files/ Jason Zaman
-- strict thread matches above, loose matches on Subject: below --
2015-05-06 23:27 Jason Zaman
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox