|
1 |
| -LineLength: |
2 |
| - Enabled: true |
3 |
| - Max: 180 |
| 1 | +# This list was created by analyzing the last three months (51 modules) |
| 2 | +# committed to Metasploit Framework. Many, many older modules will have |
| 3 | +# offenses, but this should at least provide a baseline for new modules. |
| 4 | +# |
| 5 | +# Updates to this file should include a 'Description' parameter for |
| 6 | +# any explaination needed. |
4 | 7 |
|
5 |
| -MethodLength: |
6 |
| - Enabled: true |
7 |
| - Max: 100 |
| 8 | +inherit_from: .rubocop_todo.yml |
8 | 9 |
|
9 | 10 | Style/ClassLength:
|
| 11 | + Description: 'Most Metasploit modules are quite large. This is ok.' |
| 12 | + Enabled: true |
| 13 | + Exclude: |
| 14 | + - 'modules/**/*' |
| 15 | + |
| 16 | +Style/Documentation: |
| 17 | + Enabled: true |
| 18 | + Description: 'Most Metasploit modules do not have class documentation.' |
10 | 19 | Exclude:
|
11 |
| - # Most modules are quite large and all contained in one class. This is OK. |
12 | 20 | - 'modules/**/*'
|
13 | 21 |
|
| 22 | +Style/Encoding: |
| 23 | + Enabled: true |
| 24 | + Description: 'We prefer binary to UTF-8.' |
| 25 | + EnforcedStyle: 'when_needed' |
| 26 | + |
| 27 | +Style/LineLength: |
| 28 | + Description: >- |
| 29 | + Metasploit modules often pattern match against very |
| 30 | + long strings when identifying targets. |
| 31 | + Enabled: true |
| 32 | + Max: 180 |
| 33 | + |
| 34 | +Style/MethodLength: |
| 35 | + Enabled: true |
| 36 | + Description: >- |
| 37 | + While the style guide suggests 10 lines, exploit definitions |
| 38 | + often exceed 200 lines. |
| 39 | + Max: 300 |
| 40 | + |
14 | 41 | Style/NumericLiterals:
|
15 | 42 | Enabled: false
|
| 43 | + Description: 'This often hurts readability for exploit-ish code.' |
16 | 44 |
|
17 |
| -Documentation: |
18 |
| - Exclude: |
19 |
| - - 'modules/**/*' |
| 45 | +Style/PercentLiteralDelimiters: |
| 46 | + Enabled: false |
| 47 | + Description: >- |
| 48 | + Metasploit devs tend to prefer [] over %w() for |
| 49 | + nearly all cases, since we often deal with funny |
| 50 | + looking arrays of nonwords. Consistency here is |
| 51 | + preferred over element type safety. |
| 52 | +
|
| 53 | +Style/WordArray: |
| 54 | + Enabled: false |
| 55 | + Description: >- |
| 56 | + Metasploit devs have grown comforatble with curly |
| 57 | + braces over parens for %w. Disabling this check |
| 58 | + prefers consistency. |
0 commit comments