From: Daniel Jacobowitz <drow@false.org>
To: David Miller <davem@davemloft.net>
Cc: uweigand@de.ibm.com, gdb-patches@sourceware.org
Subject: Re: longjmp handling vs. glibc LD_POINTER_GUARD problems
Date: Thu, 15 May 2008 00:39:00 -0000 [thread overview]
Message-ID: <20080514215853.GA27037@caradoc.them.org> (raw)
In-Reply-To: <20080514.142658.174642357.davem@davemloft.net>
On Wed, May 14, 2008 at 02:26:58PM -0700, David Miller wrote:
> I think you can treat this the same way we treat the signal frame
> layout. It's something undocumented but effectively fixed in stone.
>
> If glibc ever changed the offset within the thread struct for this
> cookie, so many binaries would break. So it is very likely the value
> will stay the same for the forseeable future.
I don't think that's true, is it? There's two cookies, only one of
them is exposed to GCC, and glibc uses internal macros to protect the
contents of a jmp_buf which are not necessarily the same as those used
by GCC.
e.g. gcc uses xor with %fs:0x14 on i386-linux. That's
__stack_chk_guard and jmp_buf uses PTR_MANGLE -> __pointer_chk_guard.
Many architectures don't expose either variable.
--
Daniel Jacobowitz
CodeSourcery
prev parent reply other threads:[~2008-05-14 21:59 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-05-14 18:24 Ulrich Weigand
2008-05-14 19:14 ` Daniel Jacobowitz
2008-05-14 22:01 ` Ulrich Weigand
2008-05-14 19:17 ` Pedro Alves
2008-05-17 14:00 ` Pedro Alves
2008-05-21 4:20 ` [patch] " Pedro Alves
2008-05-22 0:11 ` Ulrich Weigand
2008-05-22 0:14 ` Pedro Alves
2008-05-22 15:20 ` Pedro Alves
2008-05-22 15:34 ` Daniel Jacobowitz
2008-05-22 16:17 ` Pedro Alves
2008-05-22 16:38 ` Ulrich Weigand
2008-05-22 17:03 ` [patch] Re: longjmp handling vs. glibc LD_POINTER_GUARD ?problems Daniel Jacobowitz
2008-05-22 16:29 ` [patch] Re: longjmp handling vs. glibc LD_POINTER_GUARD problems Ulrich Weigand
2008-05-22 3:14 ` Daniel Jacobowitz
2008-05-14 23:03 ` David Miller
2008-05-15 0:39 ` Daniel Jacobowitz [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20080514215853.GA27037@caradoc.them.org \
--to=drow@false.org \
--cc=davem@davemloft.net \
--cc=gdb-patches@sourceware.org \
--cc=uweigand@de.ibm.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox