mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* problem with userland exec()
       [not found] <93517968-4587-4045-853a-70d2702f11a3@d21g2000prf.googlegroups.com>
@ 2008-03-26 17:55 ` bbb arc
  0 siblings, 0 replies; only message in thread
From: bbb arc @ 2008-03-26 17:55 UTC (permalink / raw)
  To: linux-kernel

i am trying grugq's userland exec()  [1]
 but is unable to run with my simple static linked hello world program
 [2]

 because of the random stack start address,I tried added the following
 three lines in the
 save.c:ul_setup_stack():

    stack_top = mmap(0,0x16000, PROT_WRITE |PROT_READ,
                MAP_PRIVATE|MAP_ANONYMOUS|MAP_GROWSDOWN,-1,0);// test
    stack_top +=0x16000;

 the program still segmentation fault at memcpy: 0x804d95f:      rep
 movsl %ds:(%esi),%es:(%edi)

 Does anyone have ideas about it?

 Kind Regards,
 arcbbb

 [1] http://www.phrack.org/issues.html?issue=62&id=8
 [2] my simple hello world compiled with gcc -g -static
     #include <unistd.h>
     #define hello   "Hello World!\n"

     int
     main(void)
     {
             write(1, hello, 13);
             return (0);
     }

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2008-03-26 17:56 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <93517968-4587-4045-853a-70d2702f11a3@d21g2000prf.googlegroups.com>
2008-03-26 17:55 ` problem with userland exec() bbb arc

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®