Skip to content

Commit de02b52

Browse files
authored
Merge pull request #4 from rapid7/master
Merging master
2 parents 25eda12 + 71d26a2 commit de02b52

File tree

3,828 files changed

+31010
-21216
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

3,828 files changed

+31010
-21216
lines changed

.dockerignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ data/java
9090

9191
# Avoid checking in Meterpreter libs that are built from
9292
# private source. If you're interested in this functionality,
93-
# check out Metasploit Pro: http://metasploit.com/download
93+
# check out Metasploit Pro: https://metasploit.com/download
9494
data/meterpreter/ext_server_pivot.*.dll
9595

9696
# Avoid checking in metakitty, the source for

.gitignore

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ data/java
7878

7979
# Avoid checking in Meterpreter libs that are built from
8080
# private source. If you're interested in this functionality,
81-
# check out Metasploit Pro: http://metasploit.com/download
81+
# check out Metasploit Pro: https://metasploit.com/download
8282
data/meterpreter/ext_server_pivot.*.dll
8383

8484
# Avoid checking in metakitty, the source for
@@ -88,3 +88,7 @@ data/meterpreter/ext_server_pivot.*.dll
8888

8989
# local docker compose overrides
9090
docker-compose.local*
91+
92+
# Ignore python bytecode
93+
*.pyc
94+
rspec.failures

.rubocop.yml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,18 +8,53 @@
88

99
# inherit_from: .rubocop_todo.yml
1010

11+
AllCops:
12+
TargetRubyVersion: 2.2
13+
1114
Metrics/ClassLength:
1215
Description: 'Most Metasploit modules are quite large. This is ok.'
1316
Enabled: true
1417
Exclude:
1518
- 'modules/**/*'
1619

20+
Metrics/AbcSize:
21+
Enabled: false
22+
Description: 'This is often a red-herring'
23+
24+
Metrics/CyclomaticComplexity:
25+
Enabled: false
26+
Description: 'This is often a red-herring'
27+
28+
Metrics/PerceivedComplexity:
29+
Enabled: false
30+
Description: 'This is often a red-herring'
31+
32+
Style/FrozenStringLiteralComment:
33+
Enabled: false
34+
Description: 'We cannot support this yet without a lot of things breaking'
35+
1736
Style/Documentation:
1837
Enabled: true
1938
Description: 'Most Metasploit modules do not have class documentation.'
2039
Exclude:
2140
- 'modules/**/*'
2241

42+
Style/IndentHeredoc:
43+
Enabled: false
44+
Description: 'We need to leave this disabled for Ruby 2.2 compat, remove in 2018'
45+
46+
Style/GuardClause:
47+
Enabled: false
48+
Description: 'This often introduces bugs in tested code'
49+
50+
Style/NegatedIf:
51+
Enabled: false
52+
Description: 'This often introduces bugs in tested code'
53+
54+
Style/ConditionalAssignment:
55+
Enabled: false
56+
Description: 'This is confusing for folks coming from other languages'
57+
2358
Style/Encoding:
2459
Enabled: true
2560
Description: 'We prefer binary to UTF-8.'

.travis.yml

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,8 @@ rvm:
1616
- '2.4.1'
1717

1818
env:
19-
- CMD=bundle exec rake "cucumber cucumber:boot" CREATE_BINSTUBS=true
20-
- CMD=bundle exec rake spec SPEC_OPTS="--tag content"
21-
- CMD=bundle exec rake spec SPEC_OPTS="--tag ~content"
19+
- CMD='bundle exec rake rspec-rerun:spec SPEC_OPTS="--tag content"'
20+
- CMD='bundle exec rake rspec-rerun:spec SPEC_OPTS="--tag ~content"'
2221

2322
matrix:
2423
fast_finish: true
@@ -32,14 +31,18 @@ before_install:
3231
- ln -sf ../../tools/dev/pre-commit-hook.rb ./.git/hooks/post-merge
3332
- ls -la ./.git/hooks
3433
- ./.git/hooks/post-merge
34+
# Update the bundler
35+
- gem install bundler
3536
before_script:
3637
- cp config/database.yml.travis config/database.yml
3738
- bundle exec rake --version
3839
- bundle exec rake db:create
3940
- bundle exec rake db:migrate
40-
script:
4141
# fail build if db/schema.rb update is not committed
42-
- git diff --exit-code db/schema.rb && $CMD
42+
- git diff --exit-code db/schema.rb
43+
script:
44+
- echo "${CMD}"
45+
- bash -c "${CMD}"
4346

4447
notifications:
4548
irc: "irc.freenode.org#msfnotify"

Gemfile

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,6 @@ source 'https://rubygems.org'
33
# spec.add_runtime_dependency '<name>', [<version requirements>]
44
gemspec name: 'metasploit-framework'
55

6-
gem 'bit-struct', git: 'https://github.com/busterb/bit-struct', branch: 'ruby-2.4'
7-
gem 'method_source', git: 'https://github.com/banister/method_source', branch: 'master'
8-
gem 'rubyntlm', git: 'https://github.com/WinRb/rubyntlm', branch: 'master'
9-
106
# separate from test as simplecov is not run on travis-ci
117
group :coverage do
128
# code coverage for tests
@@ -19,7 +15,7 @@ group :development do
1915
# generating documentation
2016
gem 'yard'
2117
# for development and testing purposes
22-
gem 'pry', git: 'https://github.com/pry/pry', branch: 'master'
18+
gem 'pry'
2319
# module documentation
2420
gem 'octokit'
2521
# metasploit-aggregator as a framework only option for now
@@ -37,14 +33,10 @@ group :development, :test do
3733
# Define `rake spec`. Must be in development AND test so that its available by default as a rake test when the
3834
# environment is development
3935
gem 'rspec-rails'
36+
gem 'rspec-rerun'
4037
end
4138

4239
group :test do
43-
# cucumber extension for testing command line applications, like msfconsole
44-
gem 'aruba'
45-
# cucumber + automatic database cleaning with database_cleaner
46-
gem 'cucumber-rails', :require => false
47-
gem 'shoulda-matchers'
4840
# Manipulate Time.now in specs
4941
gem 'timecop'
5042
end

Gemfile.local.example

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,6 @@ end
2727

2828
# Create a custom group
2929
group :local do
30-
# Use pry-debugger to step through code during development
31-
gem 'pry-debugger', '~> 0.2'
3230
# Add the lab gem so that the 'lab' plugin will work again
3331
gem 'lab', '~> 0.2.7'
3432
end

0 commit comments

Comments
 (0)