mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Willy Tarreau <willy@w.ods.org>
To: DJ.CnX@phreaker.net
Cc: linux-kernel@vger.kernel.org
Subject: Re: execve-bug ...
Date: Sun, 12 Jun 2005 22:49:55 +0200	[thread overview]
Message-ID: <20050612204955.GC8907@alpha.home.local> (raw)
In-Reply-To: <20050612212306.7383a6bd.DJ.CnX@phreaker.net>

On Sun, Jun 12, 2005 at 09:23:06PM +0200, DJ.CnX@phreaker.net wrote:
 
> shell# nasm -f elf -o new.o new.asm 
> shell# ld -o new new.o
> shell# ./new
> Segmentation Fault.
> 
> 
> 
> i even tried to execute the binary i've compiled on 2.6.5.x but it didnt
> work : Segmentation Fault. So i think its a bug in the "execve"-function. 

well, fortunately this is not the case or you would have some difficulties
executing your tools. You should find litterature about all the options
you have to pass to 'ld' to use it this way, or simpler : use gcc as the
linker and keep 'main' as your program's entry point, it WILL work.

You should have tried 'strace -i ./new', it would have showed you that
the program pointer is invalid (I see b7f63fae here), while on older
kernels it was still 8048080. This does not necessarily mean there's a
bug in execve(), but most probably that this code would have worked
before because of a side effect and that this side effect has been
closed now.

For instance, you can check asmutils which still works. But please,
don't post newbie asm problems here, this definitely is not the right
list.

Regards,
Willy


      parent reply	other threads:[~2005-06-12 20:51 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-06-12 19:23 execve-bug DJ.CnX
2005-06-12 19:48 ` execve-bug Christoph Hellwig
2005-06-12 20:49 ` Willy Tarreau [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=20050612204955.GC8907@alpha.home.local \
    --to=willy@w.ods.org \
    --cc=DJ.CnX@phreaker.net \
    --cc=linux-kernel@vger.kernel.org \
    /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

all inboxes | Powered by JetHome®