Skip to content

Commit e3f7398

Browse files
committed
Fix rapid7#4246 - Access payload_exe information correctly
This fixes an undef method 'payload_exe' error. We broke this when all modules started using Msf::Exploit::CmdStager as the only source to get a command stager payload. The problem with that is "payload_exe" is an accessor in CmdStagerTFTP, not in CmdStager, so when the module wants to access that, we trigger the undef method error. To be exact, this is the actual commit that broke it: 7ced592 Fix rapid7#4246
1 parent 85e0d72 commit e3f7398

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

modules/exploits/windows/iis/ms01_026_dbldecode.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -196,12 +196,12 @@ def exploit
196196

197197
# Save these file names for later deletion
198198
@exe_cmd_copy = exe_fname
199-
@exe_payload = payload_exe
199+
@exe_payload = stager_instance.payload_exe
200200

201201
# Just for good measure, we'll make a quick, direct request for the payload
202202
# Using the "start" method doesn't seem to make iis very happy :(
203203
print_status("Triggering the payload via a direct request...")
204-
mini_http_request({ 'uri' => '/scripts/' + payload_exe, 'method' => 'GET' }, 1)
204+
mini_http_request({ 'uri' => '/scripts/' + stager_instance.payload_exe, 'method' => 'GET' }, 1)
205205

206206
handler
207207

0 commit comments

Comments
 (0)