dradis-calculator_cvss 4.15.0 → 4.17.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 7e67ffa3e5bb684be2dde584761663436af37c178aede04c7a988fe5ec64587b
4
- data.tar.gz: 0f5d543c45ccf0a4b0b5fbf56ba974e3869e5c29f86c0e9549efd30bd520d09e
3
+ metadata.gz: c54eba362c5e81e2a2641c5cd6fea9ef5f4a7e6e75a437111727c588e2f888e6
4
+ data.tar.gz: 34f6be96f5493ff5c6faa21525ce29478d9c74c7e4f82afb045e9c70179f4c4c
5
5
  SHA512:
6
- metadata.gz: 060d4ef4a0faacba6ef4a22a95a256792c59ffaa80a0254013e0f8ce53c2236c383707abd0418ccd270555eb2d195749cf7d4654130d4dfaab5db95d751f5318
7
- data.tar.gz: 9f2c12f67e3ab107bc80613db98583f4a82eaf5b933c462d4b6db4882f9077f1e350e8edb5592d9a00afd6ce2729f37abd7ff6358a040ff80bddfe9f17d4e0e4
6
+ metadata.gz: 73d820ff9105df7a39c37f0a1f96f1fa39fed7f4e4289e4462afe5bac4584cfd043c60a49c2fb57f8e213e27c41c2d7fa327855264f2b1319eab0c83bf1bfce1
7
+ data.tar.gz: 5c221c66700f2fc27bf773c88a02004ab4ea42d5315379a843477562cc0705a14f4cea523a843b094597b7ca59d05554b773897b269686b7dc85aaf102452a4d
data/CHANGELOG.md CHANGED
@@ -1,101 +1,143 @@
1
+ v4.17.0 (July 2025)
2
+ - Bug fixes: Enable access for CE users
3
+
4
+ v4.16.0 (May 2025)
5
+
6
+ - Hera layout compatibility changes
7
+ - Update turbolinks references to turbo
8
+ - Improve navigation for contributors
9
+
1
10
  v4.15.0 (December 2024)
2
- - No changes
11
+
12
+ - No changes
3
13
 
4
14
  v4.14.0 (October 2024)
5
- - No changes
15
+
16
+ - No changes
6
17
 
7
18
  v4.13.0 (July 2024)
8
- - Add ability to enable/disable calculator in the Tools Manager
19
+
20
+ - Add ability to enable/disable calculator in the Tools Manager
9
21
 
10
22
  v4.12.0 (May 2024)
11
- - Add CVSS v4 support
23
+
24
+ - Add CVSS v4 support
12
25
 
13
26
  v4.11.0 (January 2024)
14
- - No changes
27
+
28
+ - No changes
15
29
 
16
30
  v4.10.0 (September 2023)
17
- - Update gemspec links
18
- - Update views for compatibility with Font Awesome 6
31
+
32
+ - Update gemspec links
33
+ - Update views for compatibility with Font Awesome 6
19
34
 
20
35
  v4.9.0 (June 2023)
21
- - Update views for compatibility with Bootstrap 5
36
+
37
+ - Update views for compatibility with Bootstrap 5
22
38
 
23
39
  v4.8.0 (April 2023)
24
- - No changes
40
+
41
+ - No changes
25
42
 
26
43
  v4.7.0 (February 2023)
27
- - No changes
44
+
45
+ - No changes
28
46
 
29
47
  v4.6.0 (November 2022)
30
- - Show CVSS in Tools menu
48
+
49
+ - Show CVSS in Tools menu
31
50
 
32
51
  v4.5.0 (August 2022)
33
- - No changes
52
+
53
+ - No changes
34
54
 
35
55
  v4.4.0 (June 2022)
36
- - No changes
56
+
57
+ - No changes
37
58
 
38
59
  v4.3.0 (April 2022)
39
- - No changes
60
+
61
+ - No changes
40
62
 
41
63
  v4.2.0 (February 2022)
42
- - No changes
64
+
65
+ - No changes
43
66
 
44
67
  v4.1.0 (November 2021)
45
- - Settings: show/hide the calculator in the Issues view
46
- - Toggle between CVSSv3.0 and CVSSv3.1
68
+
69
+ - Settings: show/hide the calculator in the Issues view
70
+ - Toggle between CVSSv3.0 and CVSSv3.1
47
71
 
48
72
  v4.0.0 (July 2021)
49
- - No changes
73
+
74
+ - No changes
50
75
 
51
76
  v3.22.0 (April 2021)
52
- - Update css manifest to use font-awesome assets from vendor files (rather than old gem)
77
+
78
+ - Update css manifest to use font-awesome assets from vendor files (rather than old gem)
53
79
 
54
80
  v3.21.0 (February 2021)
55
- - Specify exact js and css file name when precompiling assets
81
+
82
+ - Specify exact js and css file name when precompiling assets
56
83
 
57
84
  v3.20.0 (December 2020)
58
- - Use Bootstrap gem vs vendored assets
85
+
86
+ - Use Bootstrap gem vs vendored assets
59
87
 
60
88
  v3.19.0 (September 2020)
61
- - No changes
89
+
90
+ - No changes
62
91
 
63
92
  v3.18.0 (July 2020)
64
- - No changes
93
+
94
+ - No changes
65
95
 
66
96
  v3.17.0 (May 2020)
67
- - Update REGEX reference for compatibility
97
+
98
+ - Update REGEX reference for compatibility
68
99
 
69
100
  v3.16.0 (February 2020)
70
- - Update for compatibility with Tylium
101
+
102
+ - Update for compatibility with Tylium
71
103
 
72
104
  v3.15.0 (November 2019)
73
- - No changes
105
+
106
+ - No changes
74
107
 
75
108
  v3.14.0 (August 2019)
76
- - No changes
109
+
110
+ - No changes
77
111
 
78
112
  v3.13.0 (June 2019)
79
- - Allow empty 'CVSSv3.Vector' field to trigger the per-issue calculator.
113
+
114
+ - Allow empty 'CVSSv3.Vector' field to trigger the per-issue calculator.
80
115
 
81
116
  v3.12.0 (March 2019)
82
- - Present a per-issue CVSSv3 calculator
117
+
118
+ - Present a per-issue CVSSv3 calculator
83
119
 
84
120
  v3.11.0 (November 2018)
85
- - No changes
121
+
122
+ - No changes
86
123
 
87
124
  v3.10.0 (August 2018)
88
- - Fix vertical button selection behavior
125
+
126
+ - Fix vertical button selection behavior
89
127
 
90
128
  v3.9.0 (January 2018)
91
- - Add metric-specific fields to calculator output (v3.8.1)
129
+
130
+ - Add metric-specific fields to calculator output (v3.8.1)
92
131
 
93
132
  v3.8.0 (September 2017)
94
- - No changes
133
+
134
+ - No changes
95
135
 
96
136
  v3.7.0 (July 2017)
97
- - Add mouseover details to each button
98
- - Add "High" as an option for Exploit Code Maturity (E)
137
+
138
+ - Add mouseover details to each button
139
+ - Add "High" as an option for Exploit Code Maturity (E)
99
140
 
100
141
  v3.6.0 (March 2017)
101
- - No changes
142
+
143
+ - No changes
@@ -1,7 +1,6 @@
1
1
  //= require jquery3
2
2
  //= require popper
3
3
  //= require bootstrap
4
- //= require turbolinks
5
4
 
6
5
  //= require dradis/plugins/calculators/cvss/v3/vendor/cvsscalc30
7
6
  //= require dradis/plugins/calculators/cvss/v3/vendor/cvsscalc30_helptext
@@ -1,4 +1,4 @@
1
- $(document).on('turbolinks:load', function () {
1
+ $(document).on('turbo:load', function () {
2
2
  if ($('[data-behavior~=cvss-version]').length) {
3
3
  function handleVersionSelection() {
4
4
  var selectedValue = $('[data-behavior~=cvss-version]').val();
@@ -0,0 +1,5 @@
1
+ @import '_bootstrap';
2
+ @import 'font-awesome';
3
+
4
+ @import 'hera/variables';
5
+ @import 'hera/modules/buttons';
@@ -0,0 +1 @@
1
+ @import 'hera/variables';
@@ -0,0 +1,3 @@
1
+ <li>
2
+ <%= link_to 'Risk Calculators - CVSS', cvss_calculator.calculators_cvss_path, class: 'dropdown-item', data: { turbolinks: false } %>
3
+ </li>
@@ -1 +1,5 @@
1
- <%= link_to 'Risk Calculators - CVSS', cvss_calculator.calculators_cvss_path, class: 'dropdown-item', data: { turbolinks: false } %>
1
+ <% if defined?(Dradis::Pro) && !current_user.role?(:contributor) %>
2
+ <li>
3
+ <%= link_to 'Risk Calculators - CVSS', cvss_calculator.calculators_cvss_path, class: 'dropdown-item', data: { turbolinks: false } %>
4
+ </li>
5
+ <% end %>
@@ -1,6 +1,6 @@
1
1
  <div class="d-flex align-items-center justify-content-end gap-2 small">
2
2
  <label class="form-label m-0" for="cvss-version">Version:</label>
3
- <select id="cvss-version" class="form-select" aria-label="cvss version select" data-behavior="cvss-version">
3
+ <select id="cvss-version" class="form-select" aria-label="cvss version select" data-behavior="cvss-version" data-combobox-config="no-combobox">
4
4
  <option value="40" <%= 'selected' if @cvss_version == '4.0' %>>v4.0</option>
5
5
  <option value="31" <%= 'selected' if @cvss_version == '3.1' %>>v3.1</option>
6
6
  <option value="30" <%= 'selected' if @cvss_version == '3.0' %>>v3.0</option>
@@ -8,7 +8,7 @@
8
8
 
9
9
  <%= hidden_field_tag :cr, @cvss3_vector['CR'] %>
10
10
 
11
- <div class="btn-group mb-4t>
11
+ <div class="btn-group mb-4">
12
12
  <button type="button" class="btn <%= 'active btn-primary' if @cvss3_vector['CR'] == 'X' %>" name="cr" value="X" data-label="Not Defined" data-cvss="CR_X_Label">N/D <i class="fa-regular fa-question-circle" aria-hidden="true"></i></button>
13
13
 
14
14
  <button type="button" class="btn <%= 'active btn-primary' if @cvss3_vector['CR'] == 'L' %>" name="cr" value="L" data-label="Low" data-cvss="CR_L_Label">Low <i class="fa-regular fa-question-circle" aria-hidden="true"></i></button>
@@ -4,6 +4,21 @@
4
4
  <%= render 'issues/sidebar'%>
5
5
  <% end %>
6
6
 
7
+ <ol class="breadcrumb">
8
+ <li class="breadcrumb-item">
9
+ <%= link_to current_project.name, main_app.project_path(current_project) %>
10
+ </li>
11
+ <li class="breadcrumb-item">
12
+ <%= link_to 'All issues', main_app.project_issues_path(current_project) %>
13
+ </li>
14
+ <li class="breadcrumb-item">
15
+ <%= link_to @issue.title? ? @issue.title : "Issue ##{@issue.id}", main_app.project_issue_path(current_project, @issue) %>
16
+ </li>
17
+ <li class="breadcrumb-item active">
18
+ CVSS Risk Scoring
19
+ </li>
20
+ </ol>
21
+
7
22
  <div class="content-container">
8
23
  <h4 class="header-underline d-flex justify-content-between">
9
24
  <span>Edit CVSS Risk Scoring</span>
@@ -2,9 +2,10 @@
2
2
  <html>
3
3
  <head>
4
4
  <title>CVSS Score Calculator | Dradis Framework</title>
5
- <%= stylesheet_link_tag 'dradis/plugins/calculators/cvss/manifests/application', media: 'all', 'data-turbolinks-track': 'reload' %>
6
- <%= javascript_include_tag 'dradis/plugins/calculators/cvss/manifests/application', 'data-turbolinks-track': 'reload' %>
5
+ <%= stylesheet_link_tag 'dradis/plugins/calculators/cvss/base', media: 'all', 'data-turbo-track': 'reload' %>
6
+ <%= javascript_include_tag 'dradis/plugins/calculators/cvss/base', 'data-turbo-track': 'reload' %>
7
7
  <%= csrf_meta_tags %>
8
+ <%= javascript_importmap_tags %>
8
9
 
9
10
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
10
11
  </head>
@@ -14,7 +15,7 @@
14
15
  <a href="javascript:void(0)" class="navbar-brand">CVSS score calculator</a>
15
16
  <ul class="navbar-nav pull-right">
16
17
  <li class="nav-item">
17
- <%= link_to main_app.root_path, class: 'nav-link', data: { turbolinks: false } do %>
18
+ <%= link_to main_app.root_path, class: 'nav-link', data: { turbo: false } do %>
18
19
  Back to the app &rarr;
19
20
  <% end %>
20
21
  </li>
@@ -8,10 +8,10 @@ module Dradis::Plugins::Calculators::CVSS
8
8
 
9
9
  initializer 'calculator_cvss.asset_precompile_paths' do |app|
10
10
  app.config.assets.precompile += [
11
- 'dradis/plugins/calculators/cvss/manifests/application.css',
12
- 'dradis/plugins/calculators/cvss/manifests/application.js',
13
- 'dradis/plugins/calculators/cvss/manifests/tylium.js',
14
- 'dradis/plugins/calculators/cvss/manifests/tylium.css'
11
+ 'dradis/plugins/calculators/cvss/base.css',
12
+ 'dradis/plugins/calculators/cvss/base.js',
13
+ 'dradis/plugins/calculators/cvss/manifests/hera.js',
14
+ 'dradis/plugins/calculators/cvss/manifests/hera.css'
15
15
  ]
16
16
  end
17
17
 
@@ -22,17 +22,12 @@ module Dradis::Plugins::Calculators::CVSS
22
22
  end
23
23
 
24
24
  initializer 'calculator_cvss.mount_engine' do
25
- # By default, this engine is loaded into the main app. So, upon app
26
- # initialization, we first check if the DB is loaded and the Configuration
27
- # table has been created, before checking if the engine is enabled
28
25
  Rails.application.reloader.to_prepare do
29
- if (ActiveRecord::Base.connection rescue false) && ::Configuration.table_exists?
30
- Rails.application.routes.append do
31
- # Enabling/disabling integrations calls Rails.application.reload_routes! we need the enable
32
- # check inside the block to ensure the routes can be re-enabled without a server restart
33
- if Engine.enabled?
34
- mount Engine => '/', as: :cvss_calculator
35
- end
26
+ Rails.application.routes.append do
27
+ # Enabling/disabling integrations calls Rails.application.reload_routes! we need the enable
28
+ # check inside the block to ensure the routes can be re-enabled without a server restart
29
+ if Engine.enabled?
30
+ mount Engine => '/', as: :cvss_calculator
36
31
  end
37
32
  end
38
33
  end
@@ -9,7 +9,7 @@ module Dradis
9
9
 
10
10
  module VERSION
11
11
  MAJOR = 4
12
- MINOR = 15
12
+ MINOR = 17
13
13
  TINY = 0
14
14
  PRE = nil
15
15
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dradis-calculator_cvss
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.15.0
4
+ version: 4.17.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Daniel Martin
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-12-20 00:00:00.000000000 Z
11
+ date: 2025-07-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: dradis-plugins
@@ -68,9 +68,9 @@ files:
68
68
  - LICENSE
69
69
  - README.md
70
70
  - Rakefile
71
+ - app/assets/javascripts/dradis/plugins/calculators/cvss/base.js
71
72
  - app/assets/javascripts/dradis/plugins/calculators/cvss/cvss.js
72
- - app/assets/javascripts/dradis/plugins/calculators/cvss/manifests/application.js
73
- - app/assets/javascripts/dradis/plugins/calculators/cvss/manifests/tylium.js
73
+ - app/assets/javascripts/dradis/plugins/calculators/cvss/manifests/hera.js
74
74
  - app/assets/javascripts/dradis/plugins/calculators/cvss/v3/calculator.js.coffee
75
75
  - app/assets/javascripts/dradis/plugins/calculators/cvss/v3/vendor/cvsscalc30.js
76
76
  - app/assets/javascripts/dradis/plugins/calculators/cvss/v3/vendor/cvsscalc30_helptext.js
@@ -84,12 +84,13 @@ files:
84
84
  - app/assets/javascripts/dradis/plugins/calculators/cvss/v4/vendor/max_composed.js
85
85
  - app/assets/javascripts/dradis/plugins/calculators/cvss/v4/vendor/max_severity.js
86
86
  - app/assets/javascripts/dradis/plugins/calculators/cvss/v4/vendor/metrics.js
87
- - app/assets/stylesheets/dradis/plugins/calculators/cvss/manifests/application.css.scss
88
- - app/assets/stylesheets/dradis/plugins/calculators/cvss/manifests/tylium.scss
87
+ - app/assets/stylesheets/dradis/plugins/calculators/cvss/base.css.scss
88
+ - app/assets/stylesheets/dradis/plugins/calculators/cvss/manifests/hera.scss
89
89
  - app/controllers/dradis/plugins/calculators/cvss/base_controller.rb
90
90
  - app/controllers/dradis/plugins/calculators/cvss/issues_controller.rb
91
91
  - app/models/dradis/plugins/calculators/cvss/v3.rb
92
92
  - app/models/dradis/plugins/calculators/cvss/v4.rb
93
+ - app/views/dradis/plugins/calculators/cvss/_ce_tools_menu.html.erb
93
94
  - app/views/dradis/plugins/calculators/cvss/_tools_menu.html.erb
94
95
  - app/views/dradis/plugins/calculators/cvss/_version_menu.html.erb
95
96
  - app/views/dradis/plugins/calculators/cvss/base/index.html.erb
@@ -1,6 +0,0 @@
1
- @import '_bootstrap';
2
- @import 'font-awesome';
3
-
4
- @import 'tylium/variables';
5
- @import 'shared/mixins';
6
- @import 'tylium/modules/buttons';
@@ -1 +0,0 @@
1
- @import 'tylium/variables';