Skip to content

Commit 912bfd5

Browse files
committed
Merge branch 'master' of git://github.com/SherifEldeeb/metasploit-framework into SherifEldeeb-master
2 parents 26f5617 + f0991f3 commit 912bfd5

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

lib/msf/core/handler/reverse_http.rb

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,8 @@ def initialize(info = {})
154154
OptInt.new('SessionCommunicationTimeout', [ false, 'The number of seconds of no activity before this session should be killed', 300]),
155155
OptString.new('MeterpreterUserAgent', [ false, 'The user-agent that the payload should use for communication', 'Mozilla/4.0 (compatible; MSIE 6.1; Windows NT)' ]),
156156
OptString.new('MeterpreterServerName', [ false, 'The server header that the handler will send in response to requests', 'Apache' ]),
157-
OptAddress.new('ReverseListenerBindAddress', [ false, 'The specific IP address to bind to on the local system'])
157+
OptAddress.new('ReverseListenerBindAddress', [ false, 'The specific IP address to bind to on the local system']),
158+
OptString.new('HttpUknownRequestResponse', [ false, 'The returned HTML response body when the handler receives a request that is not from a payload', '<html><body><h1>It works!</h1></body></html>' ])
158159
], Msf::Handler::ReverseHttp)
159160
end
160161

@@ -359,7 +360,7 @@ def on_request(cli, req, obj)
359360
print_status("#{cli.peerhost}:#{cli.peerport} Unknown request to #{uri_match} #{req.inspect}...")
360361
resp.code = 200
361362
resp.message = "OK"
362-
resp.body = "<h3>No site configured at this address</h3>"
363+
resp.body = "#{datastore['HttpUknownRequestResponse']}"
363364
end
364365

365366
cli.send_response(resp) if (resp)

0 commit comments

Comments
 (0)