foreman_openscap 2.0.1 → 2.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/controllers/api/v2/compliance/arf_reports_controller.rb +6 -0
- data/app/controllers/api/v2/compliance/policies_controller.rb +1 -8
- data/app/controllers/api/v2/compliance/scap_contents_controller.rb +2 -8
- data/app/controllers/api/v2/compliance/tailoring_files_controller.rb +2 -8
- data/app/controllers/concerns/foreman_openscap/api/v2/scap_api_controller_extensions.rb +9 -0
- data/app/views/arf_reports/_list.html.erb +1 -1
- data/app/views/hosts/select_multiple_openscap_proxy.html.erb +1 -1
- data/app/views/policies/disassociate_multiple_hosts.html.erb +1 -1
- data/app/views/policies/select_multiple_hosts.html.erb +1 -1
- data/lib/foreman_openscap/version.rb +1 -1
- data/locale/de/foreman_openscap.edit.po +0 -0
- data/locale/en_GB/foreman_openscap.edit.po +0 -0
- data/locale/es/foreman_openscap.edit.po +0 -0
- data/locale/fr/foreman_openscap.edit.po +0 -0
- data/locale/gl/foreman_openscap.edit.po +0 -0
- data/locale/it/foreman_openscap.edit.po +0 -0
- data/locale/ja/foreman_openscap.edit.po +0 -0
- data/locale/ko/foreman_openscap.edit.po +0 -0
- data/locale/pt_BR/foreman_openscap.edit.po +0 -0
- data/locale/ru/foreman_openscap.edit.po +0 -0
- data/locale/sv_SE/foreman_openscap.edit.po +0 -0
- data/locale/zh_CN/foreman_openscap.edit.po +0 -0
- data/locale/zh_TW/foreman_openscap.edit.po +0 -0
- metadata +16 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 541cd28ad75afe6563bcdcb9826e6418b6071c3e
|
4
|
+
data.tar.gz: dd618d8b18408d1f369a705f3722778b75a1d1ed
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f41d6c12b74959b58d7afe09c86f8f3c995a0532d7ad92889fd78d7c0f3b3b71ac9a55b2c116471f6852976bc5be9d6c7a219e093d8e7d279186ffa25970ed7e
|
7
|
+
data.tar.gz: 7613f7b7fa78403705f71ecf20d4d511b9788608cfd704583bf6f6c93664578feeafccd3fa011dc51c3973f2f1011f2e5bd2a0d2b512e930ad40187d75d679e6
|
@@ -3,6 +3,7 @@ module Api::V2
|
|
3
3
|
class PoliciesController < ::Api::V2::BaseController
|
4
4
|
include Foreman::Controller::SmartProxyAuth
|
5
5
|
include Foreman::Controller::Parameters::PolicyApi
|
6
|
+
include ForemanOpenscap::Api::V2::ScapApiControllerExtensions
|
6
7
|
|
7
8
|
add_smart_proxy_filters %i[content tailoring], :features => 'Openscap'
|
8
9
|
|
@@ -10,14 +11,6 @@ module Api::V2
|
|
10
11
|
|
11
12
|
skip_after_action :log_response_body, :only => [:content]
|
12
13
|
|
13
|
-
def resource_name(resource = '::ForemanOpenscap::Policy')
|
14
|
-
super resource
|
15
|
-
end
|
16
|
-
|
17
|
-
def get_resource(message = 'no resource loaded')
|
18
|
-
instance_variable_get(:"@policy") || raise(message)
|
19
|
-
end
|
20
|
-
|
21
14
|
def policy_url(policy = nil)
|
22
15
|
api_compliance_policy_url(@policy)
|
23
16
|
end
|
@@ -3,15 +3,9 @@ module Api::V2
|
|
3
3
|
class ScapContentsController < ::Api::V2::BaseController
|
4
4
|
include Foreman::Controller::Parameters::ScapContent
|
5
5
|
include ForemanOpenscap::BodyLogExtensions
|
6
|
-
|
7
|
-
|
8
|
-
def resource_name(resource = '::ForemanOpenscap::ScapContent')
|
9
|
-
super resource
|
10
|
-
end
|
6
|
+
include ForemanOpenscap::Api::V2::ScapApiControllerExtensions
|
11
7
|
|
12
|
-
|
13
|
-
instance_variable_get(:"@scap_content") || raise(message)
|
14
|
-
end
|
8
|
+
before_action :find_resource, :except => %w[index create]
|
15
9
|
|
16
10
|
api :GET, '/compliance/scap_contents', N_('List SCAP contents')
|
17
11
|
param_group :search_and_pagination, ::Api::V2::BaseController
|
@@ -3,17 +3,11 @@ module Api::V2
|
|
3
3
|
class TailoringFilesController < ::Api::V2::BaseController
|
4
4
|
include Foreman::Controller::Parameters::TailoringFile
|
5
5
|
include ForemanOpenscap::BodyLogExtensions
|
6
|
+
include ForemanOpenscap::Api::V2::ScapApiControllerExtensions
|
7
|
+
|
6
8
|
before_action :find_resource, :except => %w[index create]
|
7
9
|
before_action :openscap_proxy_check, :only => %w[create]
|
8
10
|
|
9
|
-
def resource_name(resource = '::ForemanOpenscap::TailoringFile')
|
10
|
-
super resource
|
11
|
-
end
|
12
|
-
|
13
|
-
def get_resource(message = 'no resource loaded')
|
14
|
-
instance_variable_get(:"@tailoring_file") || raise(message)
|
15
|
-
end
|
16
|
-
|
17
11
|
api :GET, '/compliance/tailoring_files', N_('List Tailoring files')
|
18
12
|
param_group :search_and_pagination, ::Api::V2::BaseController
|
19
13
|
add_scoped_search_description_for(::ForemanOpenscap::TailoringFile)
|
@@ -51,7 +51,7 @@
|
|
51
51
|
</div>
|
52
52
|
<div class="modal-footer">
|
53
53
|
<button type="button" class="btn btn-default" data-dismiss="modal"><%= _('Cancel') %></button>
|
54
|
-
<button type="button" class="btn btn-primary" onclick="
|
54
|
+
<button type="button" class="btn btn-primary" onclick="tfm.hosts.table.submitModalForm()"><%= _('Submit') %></button>
|
55
55
|
</div>
|
56
56
|
</div>
|
57
57
|
</div>
|
@@ -4,5 +4,5 @@
|
|
4
4
|
:url => update_multiple_openscap_proxy_hosts_path(:host_ids => params[:host_ids]) do |f| %>
|
5
5
|
<%= selectable_f f, :id, [[_("Select OpenSCAP Proxy"), "None"],
|
6
6
|
] + SmartProxy.with_features(['Openscap']).map{|e| [e.name, e.id]},{},
|
7
|
-
:onchange => "
|
7
|
+
:onchange => "tfm.hosts.table.toggleMultipleOkButton(this)" %>
|
8
8
|
<% end %>
|
@@ -3,5 +3,5 @@
|
|
3
3
|
:url => remove_policy_from_multiple_hosts_policies_path(:host_ids => params[:host_ids]) do |f| %>
|
4
4
|
<%= selectable_f f, :id, [[_('Select Compliance Policy'), 'disabled'],
|
5
5
|
] + ForemanOpenscap::Policy.all.map{|e| [e.name, e.id]},{},
|
6
|
-
:onchange => '
|
6
|
+
:onchange => 'tfm.hosts.table.toggleMultipleOkButton(this)' %>
|
7
7
|
<% end %>
|
@@ -4,5 +4,5 @@
|
|
4
4
|
:url => update_multiple_hosts_policies_path(:host_ids => params[:host_ids]) do |f| %>
|
5
5
|
<%= selectable_f f, :id, [[_("Select Compliance Policy"), "disabled"],
|
6
6
|
] + ForemanOpenscap::Policy.all.map{|e| [e.name, e.id]},{},
|
7
|
-
:onchange => "
|
7
|
+
:onchange => "tfm.hosts.table.toggleMultipleOkButton(this)" %>
|
8
8
|
<% end %>
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: foreman_openscap
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.0.
|
4
|
+
version: 2.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- slukasik@redhat.com
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-11-
|
11
|
+
date: 2019-11-15 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rake
|
@@ -56,6 +56,7 @@ files:
|
|
56
56
|
- app/controllers/concerns/foreman/controller/parameters/scap_content.rb
|
57
57
|
- app/controllers/concerns/foreman/controller/parameters/tailoring_file.rb
|
58
58
|
- app/controllers/concerns/foreman_openscap/api/v2/hosts_controller_extensions.rb
|
59
|
+
- app/controllers/concerns/foreman_openscap/api/v2/scap_api_controller_extensions.rb
|
59
60
|
- app/controllers/concerns/foreman_openscap/arf_reports_controller_common_extensions.rb
|
60
61
|
- app/controllers/concerns/foreman_openscap/body_log_extensions.rb
|
61
62
|
- app/controllers/concerns/foreman_openscap/hosts_and_hostgroups_controller_extensions.rb
|
@@ -252,32 +253,45 @@ files:
|
|
252
253
|
- locale/Makefile
|
253
254
|
- locale/action_names.rb
|
254
255
|
- locale/de/LC_MESSAGES/foreman_openscap.mo
|
256
|
+
- locale/de/foreman_openscap.edit.po
|
255
257
|
- locale/de/foreman_openscap.po
|
256
258
|
- locale/en_GB/LC_MESSAGES/foreman_openscap.mo
|
259
|
+
- locale/en_GB/foreman_openscap.edit.po
|
257
260
|
- locale/en_GB/foreman_openscap.po
|
258
261
|
- locale/es/LC_MESSAGES/foreman_openscap.mo
|
262
|
+
- locale/es/foreman_openscap.edit.po
|
259
263
|
- locale/es/foreman_openscap.po
|
260
264
|
- locale/foreman_openscap.pot
|
261
265
|
- locale/fr/LC_MESSAGES/foreman_openscap.mo
|
266
|
+
- locale/fr/foreman_openscap.edit.po
|
262
267
|
- locale/fr/foreman_openscap.po
|
263
268
|
- locale/gl/LC_MESSAGES/foreman_openscap.mo
|
269
|
+
- locale/gl/foreman_openscap.edit.po
|
264
270
|
- locale/gl/foreman_openscap.po
|
265
271
|
- locale/it/LC_MESSAGES/foreman_openscap.mo
|
272
|
+
- locale/it/foreman_openscap.edit.po
|
266
273
|
- locale/it/foreman_openscap.po
|
267
274
|
- locale/ja/LC_MESSAGES/foreman_openscap.mo
|
275
|
+
- locale/ja/foreman_openscap.edit.po
|
268
276
|
- locale/ja/foreman_openscap.po
|
269
277
|
- locale/ko/LC_MESSAGES/foreman_openscap.mo
|
278
|
+
- locale/ko/foreman_openscap.edit.po
|
270
279
|
- locale/ko/foreman_openscap.po
|
271
280
|
- locale/pt_BR/LC_MESSAGES/foreman_openscap.mo
|
281
|
+
- locale/pt_BR/foreman_openscap.edit.po
|
272
282
|
- locale/pt_BR/foreman_openscap.po
|
273
283
|
- locale/ru/LC_MESSAGES/foreman_openscap.mo
|
284
|
+
- locale/ru/foreman_openscap.edit.po
|
274
285
|
- locale/ru/foreman_openscap.po
|
275
286
|
- locale/sv_SE/LC_MESSAGES/foreman_openscap.mo
|
287
|
+
- locale/sv_SE/foreman_openscap.edit.po
|
276
288
|
- locale/sv_SE/foreman_openscap.po
|
277
289
|
- locale/zanata.xml
|
278
290
|
- locale/zh_CN/LC_MESSAGES/foreman_openscap.mo
|
291
|
+
- locale/zh_CN/foreman_openscap.edit.po
|
279
292
|
- locale/zh_CN/foreman_openscap.po
|
280
293
|
- locale/zh_TW/LC_MESSAGES/foreman_openscap.mo
|
294
|
+
- locale/zh_TW/foreman_openscap.edit.po
|
281
295
|
- locale/zh_TW/foreman_openscap.po
|
282
296
|
- test/factories/arf_report_factory.rb
|
283
297
|
- test/factories/asset_factory.rb
|