Home Upgrade Search Memberlist Extras Hacker Tools Award Goals Help Wiki Contact

BOF Win64 issue

Here is the bof program
Code
#include <string.h>

void do_something(char *Buffer)
{
     char MyVar[8];
     strcpy(MyVar,Buffer);
}

int main (int argc, char **argv)
{
     do_something(argv[1]);
}
being learning about bof but got stuck here
tried to insert the address in hex but it kept reading it as asci like EX: AAAAAAAABBBB/*55/*99..
Can someone overwrite the EIP address in here making it point to another location of my choice
thanks
Ironic enough after 5 hours I solved it but you could think of it as challenge to overwrite the EIP in this program
(Jan 8, 2019 02:09 AM)emadaldin1 Wrote:  Here is the bof program
Code
#include <string.h>

void do_something(char *Buffer)
{
    char MyVar[8];
    strcpy(MyVar,Buffer);
}

int main (int argc, char **argv)
{
    do_something(argv[1]);
}
being learning about bof but got stuck here
tried to insert the address in hex but it kept reading it as asci like EX: AAAAAAAABBBB/*55/*99..
Can someone overwrite the EIP address in here making it point to another location of my choice
thanks
Ironic enough after 5 hours I solved it but you could think of it as challenge to overwrite the EIP in this program

I would expect 5 hours minimum for someone new to stack-based buffer overflows. Congratulations on figuring it out for yourself. If you want to learn more advanced methods on the subject, might I suggest the Corelan Blog. Shellcoder's Handbook and Hacking: The Art of Exploitation are also good books to study it more in-depth.
Malware Dev & Grey Hat available for contract work. DM if you need me.
OSCP, OSCE, OSEE, OSWE, OSWP, CEH, CISSP
Yeah, I've been around a while


Possibly Related Threads...
Thread / Author Replies Views Last Post
by GoodiesMay 14, 2017 01:02 PM 37 2,146 May 14, 2017 01:02 PM
Last Post: Freshnuts
by AbductedOct 10, 2016 10:26 AM 4 241 Oct 10, 2016 10:26 AM
Last Post: Abducted
by GoodiesJan 18, 2016 11:06 AM 21 2,435 Jan 18, 2016 11:06 AM
Last Post: seyt