WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-changelog

[Xen-changelog] [xen-unstable] minios: _chk_fail and _chk canaries for m

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] minios: _chk_fail and _chk canaries for minios and newlib
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Tue, 07 Apr 2009 23:00:40 -0700
Delivery-date: Tue, 07 Apr 2009 23:02:29 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1238495771 -3600
# Node ID 6ad2b1ded12f886103fb71edde7dfbedf3c4c841
# Parent  b7a11dff84c06fdbb021b9719060b9cadba4d02c
minios: _chk_fail and _chk canaries for minios and newlib

Add __stack_chk_fail to mini-os and __sprintf_chk __fprintf_chk to
newlib, to cope with ocaml runtimes compiled with -fstack-protector.

From: "George S. Coker, II" <gscoker@xxxxxxxxxxxxxx>
Signed-off-by: Samuel Thibault <samuel.thibault@xxxxxxxxxxxx>
---
 extras/mini-os/lib/stack_chk_fail.c |    8 ++++++++
 stubdom/Makefile                    |    1 +
 2 files changed, 9 insertions(+)

diff -r b7a11dff84c0 -r 6ad2b1ded12f extras/mini-os/lib/stack_chk_fail.c
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/extras/mini-os/lib/stack_chk_fail.c       Tue Mar 31 11:36:11 2009 +0100
@@ -0,0 +1,8 @@
+#include <kernel.h>
+#include <console.h>
+
+void __stack_chk_fail(void)
+{
+    printk("stack smashing detected\n");
+    do_exit();
+}
diff -r b7a11dff84c0 -r 6ad2b1ded12f stubdom/Makefile
--- a/stubdom/Makefile  Tue Mar 31 11:33:56 2009 +0100
+++ b/stubdom/Makefile  Tue Mar 31 11:36:11 2009 +0100
@@ -91,6 +91,7 @@ newlib-$(NEWLIB_VERSION): newlib-$(NEWLI
 newlib-$(NEWLIB_VERSION): newlib-$(NEWLIB_VERSION).tar.gz
        tar xzf $<
        patch -d $@ -p0 < newlib.patch
+       patch -d $@ -p0 < newlib-chk.patch
        touch $@
 
 NEWLIB_STAMPFILE=$(CROSS_ROOT)/$(GNU_TARGET_ARCH)-xen-elf/lib/libc.a

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [xen-unstable] minios: _chk_fail and _chk canaries for minios and newlib, Xen patchbot-unstable <=