Skip to contentSkip to conversation

exploitable code?

DISCUSSION jnf 1 participant 1 message Jul 1, 2002

lore
Share & tools
lore

jnf

author
#0 lore raw
Quoted 4 lines

The exit function may well be a "long jump" that uses the return value for the function "main" as its target. Therefore, when the exploiting code overwrites the return address for "main" the "exit" call will use the overwritten value.

every value i overwrite is pushed onto the stack and the next used again, the overwritten ret address is fine for main, but exit never returns, i just went through all of exit today and was hoping to find like pop %eax
jmp %eax

or something to break out of exit, but i didnt find it, So perhaps i missed it, or missed something in strcpy, but exit never returns so that is the problem.

Quoted 4 lines

Too bad people aren't required as a matter of course to look at the assembler output of code from compilers anymore. You learn a lot seeing how your statements get translated to machine code.

if you only knew how much ive learned just getting to this point. I totally agree.

Quoted 1 line

Satch

j

_____________________________________________________________
Sign up for FREE email from DoItYourself.com at http://doityourself.com

_____________________________________________________________
Promote your group and strengthen ties to your members with [email protected] by Everyone.net http://www.everyone.net/?btn=tag