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-devel

Re: [Xen-devel][PATCH][RFC] _chk_fail and _chk canaries for minios and n

To: "George S. Coker, II" <gscoker@xxxxxxxxxxxxxx>
Subject: Re: [Xen-devel][PATCH][RFC] _chk_fail and _chk canaries for minios and newlib
From: Samuel Thibault <samuel.thibault@xxxxxxxxxxxx>
Date: Mon, 9 Mar 2009 19:50:35 +0100
Cc: xen-devel <xen-devel@xxxxxxxxxxxxxxxxxxx>
Delivery-date: Mon, 09 Mar 2009 11:51:01 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <C5DAD806.2AA3A%gscoker@xxxxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Mail-followup-to: Samuel Thibault <samuel.thibault@xxxxxxxxxxxx>, "George S. Coker, II" <gscoker@xxxxxxxxxxxxxx>, xen-devel <xen-devel@xxxxxxxxxxxxxxxxxxx>
References: <20090309181317.GR15127@xxxxxxxxxxxxxxxxxxxxxxx> <C5DAD806.2AA3A%gscoker@xxxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mutt/1.5.12-2006-07-14
George S. Coker, II, le Mon 09 Mar 2009 14:28:22 -0500, a écrit :
> It probably isn't enough.  It's more of a stub to make the linker and
> libraries happy.

Right, in this particular case it's read-only code so it shouldn't
harm so much and the code could be checked-in as is.  I'm however
wondering how these reads do not trigger traps, as we unmap page 0 in
clear_bootstrap(), and thus e.g. on i386 gs:0x14 should trap.

> I was a little uncertain about the split between minios and newlib.

The way you did it seems right to me: checking printf size is more a
matter of newlib, while reacting to stack smashing is a kernel matter.

Samuel

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