Skip to content

Commit f61afe2

Browse files
committed
Merge branch 'master' into bug/MSP-11368/boot-profiling
MSP-11368
2 parents 5884cbc + ebacb26 commit f61afe2

File tree

34 files changed

+764
-746
lines changed

34 files changed

+764
-746
lines changed

Gemfile

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,11 @@ gemspec
66
group :db do
77
# Needed for Msf::DbManager
88
gem 'activerecord', '>= 3.0.0', '< 4.0.0'
9-
# Metasploit::Concern hooks
10-
gem 'metasploit-concern', '~> 0.1.1'
9+
1110
# Metasploit::Credential database models
12-
gem 'metasploit-credential', '>= 0.9.0'
11+
gem 'metasploit-credential', '~> 0.10.1'
1312
# Database models shared between framework and Pro.
14-
gem 'metasploit_data_models', '~> 0.19'
13+
gem 'metasploit_data_models', '~> 0.20.1'
1514
# Needed for module caching in Mdm::ModuleDetails
1615
gem 'pg', '>= 0.11'
1716
end
@@ -53,7 +52,7 @@ group :test do
5352
# cucumber extension for testing command line applications, like msfconsole
5453
gem 'aruba'
5554
# cucumber + automatic database cleaning with database_cleaner
56-
gem 'cucumber-rails'
55+
gem 'cucumber-rails', :require => false
5756
gem 'shoulda-matchers'
5857
# code coverage for tests
5958
# any version newer than 0.5.4 gives an Encoding error when trying to read the source files.

Gemfile.lock

Lines changed: 21 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,15 @@ PATH
55
actionpack (< 4.0.0)
66
activesupport (>= 3.0.0, < 4.0.0)
77
bcrypt
8+
jsobfu (~> 0.1.7)
89
json
9-
metasploit-model (~> 0.26.1)
10+
metasploit-concern (~> 0.2.1)
11+
metasploit-model (~> 0.27.1)
1012
meterpreter_bins (= 0.0.7)
1113
msgpack
1214
nokogiri
1315
packetfu (= 1.1.9)
1416
railties
15-
rkelly-remix (= 0.0.6)
1617
robots
1718
rubyzip (~> 1.1)
1819
sqlite3
@@ -90,34 +91,40 @@ GEM
9091
hike (1.2.3)
9192
i18n (0.6.11)
9293
journey (1.0.4)
94+
jsobfu (0.1.7)
95+
rkelly-remix (= 0.0.6)
9396
json (1.8.1)
9497
mail (2.5.4)
9598
mime-types (~> 1.16)
9699
treetop (~> 1.4.8)
97-
metasploit-concern (0.1.1)
100+
metasploit-concern (0.2.1)
98101
activesupport (~> 3.0, >= 3.0.0)
99-
metasploit-credential (0.9.0)
100-
metasploit-concern (~> 0.1.0)
101-
metasploit-model (~> 0.26.1)
102-
metasploit_data_models (~> 0.19.4)
102+
railties (< 4.0.0)
103+
metasploit-credential (0.10.1)
104+
metasploit-concern (~> 0.2.1)
105+
metasploit-model (~> 0.27.0)
106+
metasploit_data_models (~> 0.20.0)
103107
pg
108+
railties (< 4.0.0)
104109
rubyntlm
105110
rubyzip (~> 1.1)
106-
metasploit-model (0.26.1)
111+
metasploit-model (0.27.1)
107112
activesupport
108-
metasploit_data_models (0.19.4)
113+
railties (< 4.0.0)
114+
metasploit_data_models (0.20.1)
109115
activerecord (>= 3.2.13, < 4.0.0)
110116
activesupport
111117
arel-helpers
112-
metasploit-concern (~> 0.1.0)
113-
metasploit-model (~> 0.26.1)
118+
metasploit-concern (~> 0.2.1)
119+
metasploit-model (~> 0.27.0)
114120
pg
121+
railties (< 4.0.0)
115122
meterpreter_bins (0.0.7)
116123
method_source (0.8.2)
117124
mime-types (1.25.1)
118125
mini_portile (0.6.0)
119126
msgpack (0.5.8)
120-
multi_json (1.0.3)
127+
multi_json (1.0.4)
121128
network_interface (0.0.1)
122129
nokogiri (1.6.3.1)
123130
mini_portile (= 0.6.0)
@@ -211,10 +218,9 @@ DEPENDENCIES
211218
factory_girl (>= 4.1.0)
212219
factory_girl_rails
213220
fivemat (= 1.2.1)
214-
metasploit-concern (~> 0.1.1)
215-
metasploit-credential (>= 0.9.0)
221+
metasploit-credential (~> 0.10.1)
216222
metasploit-framework!
217-
metasploit_data_models (~> 0.19)
223+
metasploit_data_models (~> 0.20.1)
218224
network_interface (~> 0.0.1)
219225
pcaprub
220226
pg (>= 0.11)

data/js/detect/ie_addons.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1-
window.ie_addons_detect = { };
1+
var ie_addons_detect = { };
22

33
/**
44
* Returns true if this ActiveX is available, otherwise false.
55
* Grabbed this directly from browser_autopwn.rb
66
**/
7-
window.ie_addons_detect.hasActiveX = function (axo_name, method) {
7+
ie_addons_detect.hasActiveX = function (axo_name, method) {
88
var axobj = null;
99
if (axo_name.substring(0,1) == String.fromCharCode(123)) {
1010
axobj = document.createElement("object");
@@ -41,7 +41,7 @@ window.ie_addons_detect.hasActiveX = function (axo_name, method) {
4141
/**
4242
* Returns the version of Microsoft Office. If not found, returns null.
4343
**/
44-
window.ie_addons_detect.getMsOfficeVersion = function () {
44+
ie_addons_detect.getMsOfficeVersion = function () {
4545
var version;
4646
var types = new Array();
4747
for (var i=1; i <= 5; i++) {

data/js/detect/misc_addons.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1-
window.misc_addons_detect = { };
1+
var misc_addons_detect = { };
22

33

44
/**
55
* Detects whether the browser supports Silverlight or not
66
**/
7-
window.misc_addons_detect.hasSilverlight = function () {
7+
misc_addons_detect.hasSilverlight = function () {
88
var found = false;
99

1010
//
@@ -49,7 +49,7 @@ window.misc_addons_detect.hasSilverlight = function () {
4949
/**
5050
* Returns the Adobe Flash version
5151
**/
52-
window.misc_addons_detect.getFlashVersion = function () {
52+
misc_addons_detect.getFlashVersion = function () {
5353
var foundVersion = null;
5454

5555
//
@@ -96,7 +96,7 @@ window.misc_addons_detect.getFlashVersion = function () {
9696
/**
9797
* Returns the Java version
9898
**/
99-
window.misc_addons_detect.getJavaVersion = function () {
99+
misc_addons_detect.getJavaVersion = function () {
100100
var foundVersion = null;
101101

102102
//

data/js/detect/os.js

Lines changed: 23 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,36 +1,36 @@
11

22
// Case matters, see lib/msf/core/constants.rb
33
// All of these should match up with constants in ::Msf::HttpClients
4-
clients_opera = "Opera";
5-
clients_ie = "MSIE";
6-
clients_ff = "Firefox";
7-
clients_chrome= "Chrome";
8-
clients_safari= "Safari";
4+
var clients_opera = "Opera";
5+
var clients_ie = "MSIE";
6+
var clients_ff = "Firefox";
7+
var clients_chrome= "Chrome";
8+
var clients_safari= "Safari";
99

1010
// All of these should match up with constants in ::Msf::OperatingSystems
11-
oses_linux = "Linux";
12-
oses_windows = "Microsoft Windows";
13-
oses_mac_osx = "Mac OS X";
14-
oses_freebsd = "FreeBSD";
15-
oses_netbsd = "NetBSD";
16-
oses_openbsd = "OpenBSD";
11+
var oses_linux = "Linux";
12+
var oses_windows = "Microsoft Windows";
13+
var oses_mac_osx = "Mac OS X";
14+
var oses_freebsd = "FreeBSD";
15+
var oses_netbsd = "NetBSD";
16+
var oses_openbsd = "OpenBSD";
1717

1818
// All of these should match up with the ARCH_* constants
19-
arch_armle = "armle";
20-
arch_x86 = "x86";
21-
arch_x86_64 = "x86_64";
22-
arch_ppc = "ppc";
23-
arch_mipsle = "mipsle";
19+
var arch_armle = "armle";
20+
var arch_x86 = "x86";
21+
var arch_x86_64 = "x86_64";
22+
var arch_ppc = "ppc";
23+
var arch_mipsle = "mipsle";
2424

25-
window.os_detect = {};
25+
var os_detect = {};
2626

2727
/**
2828
* This can reliably detect browser versions for IE and Firefox even in the
2929
* presence of a spoofed User-Agent. OS detection is more fragile and
3030
* requires truthful navigator.appVersion and navigator.userAgent strings in
3131
* order to be accurate for more than just IE on Windows.
3232
**/
33-
window.os_detect.getVersion = function(){
33+
os_detect.getVersion = function(){
3434
//Default values:
3535
var os_name;
3636
var os_flavor;
@@ -1121,7 +1121,7 @@ window.os_detect.getVersion = function(){
11211121
return { os_name:os_name, os_flavor:os_flavor, os_sp:os_sp, os_lang:os_lang, arch:arch, ua_name:ua_name, ua_version:ua_version };
11221122
}; // function getVersion
11231123

1124-
window.os_detect.searchVersion = function(needle, haystack) {
1124+
os_detect.searchVersion = function(needle, haystack) {
11251125
var index = haystack.indexOf(needle);
11261126
var found_version;
11271127
if (index == -1) { return; }
@@ -1137,7 +1137,7 @@ window.os_detect.searchVersion = function(needle, haystack) {
11371137
/*
11381138
* Return -1 if a < b, 0 if a == b, 1 if a > b
11391139
*/
1140-
window.ua_ver_cmp = function(ver_a, ver_b) {
1140+
ua_ver_cmp = function(ver_a, ver_b) {
11411141
// shortcut the easy case
11421142
if (ver_a == ver_b) {
11431143
return 0;
@@ -1181,15 +1181,15 @@ window.ua_ver_cmp = function(ver_a, ver_b) {
11811181
return 0;
11821182
};
11831183

1184-
window.ua_ver_lt = function(a, b) {
1184+
ua_ver_lt = function(a, b) {
11851185
if (-1 == this.ua_ver_cmp(a,b)) { return true; }
11861186
return false;
11871187
};
1188-
window.ua_ver_gt = function(a, b) {
1188+
ua_ver_gt = function(a, b) {
11891189
if (1 == this.ua_ver_cmp(a,b)) { return true; }
11901190
return false;
11911191
};
1192-
window.ua_ver_eq = function(a, b) {
1192+
ua_ver_eq = function(a, b) {
11931193
if (0 == this.ua_ver_cmp(a,b)) { return true; }
11941194
return false;
11951195
};

db/schema.rb

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
#
1212
# It's strongly recommended to check this file into your version control system.
1313

14-
ActiveRecord::Schema.define(:version => 20140801150537) do
14+
ActiveRecord::Schema.define(:version => 20140905031549) do
1515

1616
create_table "api_keys", :force => true do |t|
1717
t.text "token"
@@ -125,6 +125,7 @@
125125
t.integer "host_detail_count", :default => 0
126126
t.integer "exploit_attempt_count", :default => 0
127127
t.integer "cred_count", :default => 0
128+
t.string "detected_arch"
128129
end
129130

130131
add_index "hosts", ["name"], :name => "index_hosts_on_name"

0 commit comments

Comments
 (0)