4 Dec 2004 17:45
Re: [Patch] Fixing the PROCESS_DUP_HANDLE security hole.
Pierre A. Humblet <pierre <at> phumblet.no-ip.org>
2004-12-04 16:45:28 GMT
2004-12-04 16:45:28 GMT
At 12:43 AM 12/4/2004 -0500, Christopher Faylor wrote: > >I wrote a simple test case to check this and I don't see it -- on XP. I >can't easily run Me anymore. Does the attached program demonstrate this >behavior when you run it? It should re-exec itself every time you hit >CTRL-C. That test case has no problem, but the attached one does. Use kill -30 pid Pierre
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <sys/signal.h>
void ouch (int sig)
{
printf ("got signal %d\n", sig);
return;
}
int
main (int argc, char **argv)
{
if (getppid() != 1 && fork())
exit(0);
signal (SIGUSR1, ouch);
(Continue reading)
RSS Feed