inspec 1.48.0 → 1.49.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.rubocop.yml +4 -0
- data/CHANGELOG.md +40 -16
- data/Rakefile +1 -1
- data/docs/resources/bond.md.erb +6 -1
- data/docs/resources/mysql_session.md.erb +24 -12
- data/docs/resources/passwd.md.erb +1 -1
- data/docs/resources/xml.md.erb +7 -2
- data/docs/shell.md +22 -0
- data/inspec.gemspec +1 -1
- data/lib/bundles/inspec-artifact/cli.rb +0 -2
- data/lib/bundles/inspec-compliance/api.rb +58 -3
- data/lib/bundles/inspec-compliance/cli.rb +1 -1
- data/lib/bundles/inspec-habitat/profile.rb +1 -1
- data/lib/fetchers/url.rb +1 -1
- data/lib/inspec/base_cli.rb +3 -1
- data/lib/inspec/cli.rb +11 -1
- data/lib/inspec/control_eval_context.rb +13 -2
- data/lib/inspec/dependencies/lockfile.rb +0 -2
- data/lib/inspec/dsl_shared.rb +8 -0
- data/lib/inspec/library_eval_context.rb +12 -1
- data/lib/inspec/metadata.rb +13 -44
- data/lib/inspec/objects/attribute.rb +1 -1
- data/lib/inspec/plugins/resource.rb +18 -2
- data/lib/inspec/profile.rb +17 -11
- data/lib/inspec/profile_context.rb +9 -3
- data/lib/inspec/profile_vendor.rb +1 -1
- data/lib/inspec/resource.rb +5 -0
- data/lib/inspec/rspec_json_formatter.rb +3 -3
- data/lib/inspec/rule.rb +1 -1
- data/lib/inspec/runner.rb +13 -5
- data/lib/inspec/schema.rb +1 -1
- data/lib/inspec/shell.rb +1 -1
- data/lib/inspec/version.rb +1 -1
- data/lib/resources/aide_conf.rb +0 -2
- data/lib/resources/apache_conf.rb +9 -2
- data/lib/resources/auditd.rb +0 -1
- data/lib/resources/auditd_rules.rb +0 -2
- data/lib/resources/bond.rb +4 -0
- data/lib/resources/crontab.rb +1 -1
- data/lib/resources/docker.rb +1 -1
- data/lib/resources/elasticsearch.rb +1 -1
- data/lib/resources/file.rb +2 -0
- data/lib/resources/groups.rb +29 -5
- data/lib/resources/grub_conf.rb +1 -1
- data/lib/resources/os.rb +8 -20
- data/lib/resources/package.rb +20 -21
- data/lib/resources/platform.rb +112 -0
- data/lib/resources/port.rb +1 -1
- data/lib/resources/processes.rb +1 -1
- data/lib/resources/registry_key.rb +1 -1
- data/lib/resources/service.rb +1 -1
- data/lib/resources/virtualization.rb +1 -1
- data/lib/resources/x509_certificate.rb +1 -1
- data/lib/resources/xml.rb +1 -0
- metadata +5 -10
data/lib/resources/port.rb
CHANGED
@@ -381,7 +381,7 @@ module Inspec::Resources
|
|
381
381
|
end
|
382
382
|
|
383
383
|
# extract port information from netstat
|
384
|
-
class LinuxPorts < PortsInfo
|
384
|
+
class LinuxPorts < PortsInfo
|
385
385
|
ALLOWED_PROTOCOLS = %w{tcp tcp6 udp udp6}.freeze
|
386
386
|
|
387
387
|
def info
|
data/lib/resources/processes.rb
CHANGED
@@ -7,7 +7,7 @@ require 'utils/filter'
|
|
7
7
|
require 'ostruct'
|
8
8
|
|
9
9
|
module Inspec::Resources
|
10
|
-
class Processes < Inspec.resource(1)
|
10
|
+
class Processes < Inspec.resource(1)
|
11
11
|
name 'processes'
|
12
12
|
desc 'Use the processes InSpec audit resource to test properties for programs that are running on the system.'
|
13
13
|
example "
|
@@ -47,7 +47,7 @@ require 'json'
|
|
47
47
|
# end
|
48
48
|
|
49
49
|
module Inspec::Resources
|
50
|
-
class RegistryKey < Inspec.resource(1)
|
50
|
+
class RegistryKey < Inspec.resource(1)
|
51
51
|
name 'registry_key'
|
52
52
|
desc 'Use the registry_key InSpec audit resource to test key values in the Microsoft Windows registry.'
|
53
53
|
example "
|
data/lib/resources/service.rb
CHANGED
@@ -68,7 +68,7 @@ module Inspec::Resources
|
|
68
68
|
# Ubuntu < 15.04 : upstart
|
69
69
|
#
|
70
70
|
# TODO: extend the logic to detect the running init system, independently of OS
|
71
|
-
class Service < Inspec.resource(1)
|
71
|
+
class Service < Inspec.resource(1)
|
72
72
|
name 'service'
|
73
73
|
desc 'Use the service InSpec audit resource to test if the named service is installed, running and/or enabled.'
|
74
74
|
example "
|
@@ -4,7 +4,7 @@
|
|
4
4
|
require 'hashie/mash'
|
5
5
|
|
6
6
|
module Inspec::Resources
|
7
|
-
class Virtualization < Inspec.resource(1)
|
7
|
+
class Virtualization < Inspec.resource(1)
|
8
8
|
name 'virtualization'
|
9
9
|
desc 'Use the virtualization InSpec audit resource to test the virtualization platform on which the system is running'
|
10
10
|
example "
|
@@ -6,7 +6,7 @@ require 'openssl'
|
|
6
6
|
require 'hashie/mash'
|
7
7
|
|
8
8
|
module Inspec::Resources
|
9
|
-
class X509CertificateResource < Inspec.resource(1)
|
9
|
+
class X509CertificateResource < Inspec.resource(1)
|
10
10
|
name 'x509_certificate'
|
11
11
|
desc 'Used to test x.509 certificates'
|
12
12
|
example "
|
data/lib/resources/xml.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: inspec
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.49.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Dominik Richter
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2018-01-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: train
|
@@ -16,20 +16,14 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: '0.
|
20
|
-
- - ">="
|
21
|
-
- !ruby/object:Gem::Version
|
22
|
-
version: 0.31.1
|
19
|
+
version: '0.32'
|
23
20
|
type: :runtime
|
24
21
|
prerelease: false
|
25
22
|
version_requirements: !ruby/object:Gem::Requirement
|
26
23
|
requirements:
|
27
24
|
- - "~>"
|
28
25
|
- !ruby/object:Gem::Version
|
29
|
-
version: '0.
|
30
|
-
- - ">="
|
31
|
-
- !ruby/object:Gem::Version
|
32
|
-
version: 0.31.1
|
26
|
+
version: '0.32'
|
33
27
|
- !ruby/object:Gem::Dependency
|
34
28
|
name: thor
|
35
29
|
requirement: !ruby/object:Gem::Requirement
|
@@ -619,6 +613,7 @@ files:
|
|
619
613
|
- lib/resources/parse_config.rb
|
620
614
|
- lib/resources/passwd.rb
|
621
615
|
- lib/resources/pip.rb
|
616
|
+
- lib/resources/platform.rb
|
622
617
|
- lib/resources/port.rb
|
623
618
|
- lib/resources/postgres.rb
|
624
619
|
- lib/resources/postgres_conf.rb
|