From: Samuel Thibault Subject: Re: [PATCH][RFC] _chk_fail and _chk canaries for minios and newlib Date: Mon, 9 Mar 2009 19:50:35 +0100 Message-ID: <20090309185035.GA5010@const.famille.thibault.fr> References: <20090309181317.GR15127@const.bordeaux.inria.fr> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable Return-path: Content-Disposition: inline In-Reply-To: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: "George S. Coker, II" Cc: xen-devel List-Id: xen-devel@lists.xenproject.org George S. Coker, II, le Mon 09 Mar 2009 14:28:22 -0500, a =E9crit : > 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