public inbox for libc-alpha@sourceware.org
 help / color / mirror / Atom feed
* Incorrect IFUNC use in libpthread for fork, vfork wrapper [BZ #19861]
@ 2016-03-30 13:19 Florian Weimer
  2016-03-30 13:38 ` Andreas Schwab
  2016-03-30 16:47 ` Richard Henderson
  0 siblings, 2 replies; 8+ messages in thread
From: Florian Weimer @ 2016-03-30 13:19 UTC (permalink / raw)
  To: GNU C Library; +Cc: Richard Henderson

The IFUNC use is incorrect because you cannot assume that some other
symbol has been relocated, and the current implementation sometimes
returns an unrelocated address.  (The bug is about vfork, but I'm sure
fork has the same issue.)

Is there a reliable test case which exposes this problem?  I made the
vfork wrapper in libpthread a non-tail-call, fixed up the nptl vfork
tests to actually call the wrapper (which I assume they currently don't
due to the compat symbol), and still didn't get any crash.  I even tried
to add a bit of extra work in the child, to make sure that the stack is
overwritten (but downwards only, obviously).

Any ideas?

Florian

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2016-04-11 10:02 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-03-30 13:19 Incorrect IFUNC use in libpthread for fork, vfork wrapper [BZ #19861] Florian Weimer
2016-03-30 13:38 ` Andreas Schwab
2016-03-30 16:47 ` Richard Henderson
2016-03-30 19:10   ` Szabolcs Nagy
2016-03-30 19:51     ` Richard Henderson
2016-04-11  9:34       ` Florian Weimer
2016-04-11  9:58         ` Andreas Schwab
2016-04-11 10:02           ` Florian Weimer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).