[Exploit] [Remote] [Local] [Web Apps] [Dos/Poc] [Shellcode] [RSS]
# Title : os-x/PPC simple write() 75 bytes
# Published : 2004-09-26
# Author : B-r00t
# Previous Title : os-x/PPC create /tmp/suid 122 bytes
# Next Title : os-x/PPC execve /usr/X11R6/bin/xterm 141 bytes
/*
PPC OSX/Darwin Shellcode by B-r00t. 2003.
Does write(); exit();
See ASM below.
75 Bytes.
*/
char shellcode[] =
"x7cx63x1ax79x40x82xffxfd"
"x7fxe8x02xa6x39x40x01x70"
"x38x6axfex91x38x9fx01x38"
"x38x84xfexf4x38xaaxfexa7"
"x38x0axfex94x44xffxffx02"
"x60x60x60x60x38x0axfex91"
"x44xffxffx02x0ax42x2dx72"
"x30x30x74x20x52x30x78x20"
"x59x33x52x20x57x30x72x31"
"x64x21x0a";
int main (void)
{
__asm__("b _shellcode");
}
/*
; PPC OS X / Darwin Shellcode by B-r00t.
; write() exit().
; Simply writes 'B-r00t R0x Y3R W0r1d!
;
.globl _main
.text
_main:
xor. r3, r3, r3
bnel _main
mflr r31
li r10, 368
addi r3, r10, -367
addi r4, r31, 268+44
addi r4, r4, -268
addi r5, r10, -345
addi r0, r10, -364
.long 0x44ffff02
.long 0x60606060
addi r0, r10, - 367
.long 0x44ffff02
string: .asciz "nB-r00t R0x Y3R W0r1d!n"
*/
// www.Syue.com [2004-09-26]