All of lore.kernel.org
 help / color / mirror / Atom feed
* 32-on-64 (x86-64) siginfo corruption
@ 2006-04-06  3:20 Albert Cahalan
  2006-04-06  4:41 ` David S. Miller
  0 siblings, 1 reply; 2+ messages in thread
From: Albert Cahalan @ 2006-04-06  3:20 UTC (permalink / raw)
  To: ak, ak, linux-kernel

The situation:  32-bit debugger, 32-bit child, 64-bit kernel

The debugger sends an RT signal to the child. (to stop it, with
a queue and siginfo so that non-debugger signals don't get lost)
To do this, the debugger uses tgkill().

Later, the debugger checks the child's siginfo_t before discarding
it. This is to be sure that the child didn't get the RT signal from
some other source. The debugger fills a siginfo_t with 0xff, then
fetches siginfo data via ptrace. The data is corrupt:

FIELD     32-ON-64   NORMAL
si_pid      -1       getpid()
si_uid    getpid()   getuid()

The "getpid" and "getuid" above are done in the debugger, not in
the child. The si_code values are SI_TKILL.

Probably the other ports with 32-on-64 support ought to verify
that this stuff works right.

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

end of thread, other threads:[~2006-04-06  4:41 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-04-06  3:20 32-on-64 (x86-64) siginfo corruption Albert Cahalan
2006-04-06  4:41 ` David S. Miller

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.