chamber 2.10.0 → 2.10.1
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 +4 -4
- checksums.yaml.gz.sig +0 -0
- data.tar.gz.sig +0 -0
- data/lib/chamber/binary/runner.rb +5 -10
- data/lib/chamber/filters/insecure_filter.rb +4 -2
- data/lib/chamber/version.rb +1 -1
- metadata +2 -2
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 959b4b9e6ff23b68e96e341093f332e4c07cf6b1
|
4
|
+
data.tar.gz: 56bd90abf4fcee09212caf6baac48e4d8ef1875b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e1c28eba8eb36146d3b0ebe4c697b89509e467b42e5e5492020c02cf989543948bacfc23e6990f9e649759c7ee77d496c59f35b5610cdffdb4b545617f2c8f90
|
7
|
+
data.tar.gz: 618440410d762ae5a55d169ea452697eaf8433583e5c166706df2f5079051c7381181333e5608bfb0ac81ce91732a9d1fe7201a6894baa5dc9dc0d8d07a454b3
|
checksums.yaml.gz.sig
CHANGED
Binary file
|
data.tar.gz.sig
CHANGED
Binary file
|
@@ -56,11 +56,6 @@ class Runner < Thor
|
|
56
56
|
desc: 'The path to or contents of the public key associated with ' \
|
57
57
|
'the project (typically .chamber.pub.pem)'
|
58
58
|
|
59
|
-
class_option :shell,
|
60
|
-
default: new,
|
61
|
-
desc: 'The command runner. Can be overridden for specific logging ' \
|
62
|
-
'capabilities.'
|
63
|
-
|
64
59
|
desc 'travis SUBCOMMAND ...ARGS', 'For manipulating Travis CI environment variables'
|
65
60
|
subcommand 'travis', Chamber::Binary::Travis
|
66
61
|
|
@@ -84,12 +79,12 @@ class Runner < Thor
|
|
84
79
|
'Useful for debugging.'
|
85
80
|
|
86
81
|
def show
|
87
|
-
puts Commands::Show.call(options)
|
82
|
+
puts Commands::Show.call(options.merge(shell: self))
|
88
83
|
end
|
89
84
|
|
90
85
|
desc 'files', 'Lists the settings files which are parsed with the given options'
|
91
86
|
def files
|
92
|
-
puts Commands::Files.call(options)
|
87
|
+
puts Commands::Files.call(options.merge(shell: self))
|
93
88
|
end
|
94
89
|
|
95
90
|
desc 'compare', 'Displays the difference between what is currently stored in the ' \
|
@@ -112,7 +107,7 @@ class Runner < Thor
|
|
112
107
|
'of the comparison'
|
113
108
|
|
114
109
|
def compare
|
115
|
-
Commands::Compare.call(options)
|
110
|
+
Commands::Compare.call(options.merge(shell: self))
|
116
111
|
end
|
117
112
|
|
118
113
|
desc 'secure', 'Secures any values which appear to need to be encrypted in any of ' \
|
@@ -129,14 +124,14 @@ class Runner < Thor
|
|
129
124
|
'what values would be encrypted'
|
130
125
|
|
131
126
|
def secure
|
132
|
-
Commands::Secure.call(options)
|
127
|
+
Commands::Secure.call(options.merge(shell: self))
|
133
128
|
end
|
134
129
|
|
135
130
|
desc 'init', 'Sets Chamber up matching best practices for secure configuration ' \
|
136
131
|
'management'
|
137
132
|
|
138
133
|
def init
|
139
|
-
Commands::Initialize.call(options)
|
134
|
+
Commands::Initialize.call(options.merge(shell: self))
|
140
135
|
end
|
141
136
|
end
|
142
137
|
end
|
@@ -5,7 +5,8 @@ require 'chamber/filters/secure_filter'
|
|
5
5
|
module Chamber
|
6
6
|
module Filters
|
7
7
|
class InsecureFilter < SecureFilter
|
8
|
-
|
8
|
+
BASE64_STRING_PATTERN = %r{\A[A-Za-z0-9\+\/]{342}==\z}
|
9
|
+
LARGE_DATA_STRING_PATTERN = %r{\A([A-Za-z0-9\+\/#]*\={0,2})#([A-Za-z0-9\+\/#]*\={0,2})#([A-Za-z0-9\+\/#]*\={0,2})\z} # rubocop:disable Metrics/LineLength
|
9
10
|
|
10
11
|
protected
|
11
12
|
|
@@ -17,7 +18,8 @@ class InsecureFilter < SecureFilter
|
|
17
18
|
value = if value.respond_to? :each_pair
|
18
19
|
execute(value)
|
19
20
|
elsif value.respond_to? :match
|
20
|
-
value unless value.match(
|
21
|
+
value unless value.match(BASE64_STRING_PATTERN) ||
|
22
|
+
value.match(LARGE_DATA_STRING_PATTERN)
|
21
23
|
end
|
22
24
|
|
23
25
|
settings[key] = value unless value.nil?
|
data/lib/chamber/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: chamber
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.10.
|
4
|
+
version: 2.10.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- thekompanee
|
@@ -34,7 +34,7 @@ cert_chain:
|
|
34
34
|
QwSfDGz6+zsImi5N3UT71+mk7YcviQSgvMRl3VkAv8MZ6wcJ5SQRpf9w0OeFH6Ln
|
35
35
|
nNbCoHiYeXX/lz/M6AIbxDIZZTwxcyvF7bdrQ2fbH5MsfQ==
|
36
36
|
-----END CERTIFICATE-----
|
37
|
-
date: 2017-02-
|
37
|
+
date: 2017-02-09 00:00:00.000000000 Z
|
38
38
|
dependencies:
|
39
39
|
- !ruby/object:Gem::Dependency
|
40
40
|
name: thor
|
metadata.gz.sig
CHANGED
Binary file
|