wes-cloudkit 3.1.0 → 4.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/wes/cloudkit/app_config.rb +8 -11
- data/lib/wes/cloudkit/version.rb +1 -1
- data/wes-cloudkit.gemspec +1 -2
- metadata +9 -23
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ef951b4ce4416dc5b0c6fa33eb954bf98301f2f2
|
4
|
+
data.tar.gz: 6d2f52b3aa258ee6cbb2452c5b4c3a0d59a38491
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b59d6540575cf573f8cc795df315d982a780da7dcfc7a597c8ebaed9a1ac9a552dc1a2c3b950b0ad5ed1c91eeacfd2567e5ef2d443e2091311338fa350823061
|
7
|
+
data.tar.gz: b79bc22d727680b8f951ed8f260e4bf12869766a395a699f83adfbfdd28381229fd58af0e7cb7a543fb003b8ea16ce23be01582ee8417316b5c2dbfcd38ccf5d
|
@@ -1,5 +1,5 @@
|
|
1
|
-
require "gibberish"
|
2
1
|
require "wes/cloudkit/configuration"
|
2
|
+
require "base64"
|
3
3
|
|
4
4
|
module Wes
|
5
5
|
module Cloudkit
|
@@ -24,21 +24,18 @@ module Wes
|
|
24
24
|
configuration.aws_env
|
25
25
|
end
|
26
26
|
|
27
|
-
def
|
28
|
-
@
|
27
|
+
def kms_client
|
28
|
+
@kms_client ||= Aws::KMS::Client.new
|
29
29
|
end
|
30
30
|
|
31
31
|
def configuration
|
32
32
|
Configuration
|
33
33
|
end
|
34
34
|
|
35
|
-
def decrypt(
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
def encyption_key
|
40
|
-
return "batman" unless Configuration.env == "production"
|
41
|
-
ENV["CONFIG_ENCRYPTION_KEY"]
|
35
|
+
def decrypt(value)
|
36
|
+
kms_client.decrypt(
|
37
|
+
ciphertext_blob: Base64.decode64(value)
|
38
|
+
).plaintext
|
42
39
|
end
|
43
40
|
|
44
41
|
def path
|
@@ -53,7 +50,7 @@ module Wes
|
|
53
50
|
rj.keys.each do |node|
|
54
51
|
rj[node].keys.each do |key|
|
55
52
|
if rj[node][key]["secure"] == true
|
56
|
-
rj[node][key]["value"] = decrypt
|
53
|
+
rj[node][key]["value"] = decrypt(rj[node][key]["value"])
|
57
54
|
end
|
58
55
|
rj[node][key] = rj[node][key]["value"]
|
59
56
|
end
|
data/lib/wes/cloudkit/version.rb
CHANGED
data/wes-cloudkit.gemspec
CHANGED
@@ -20,9 +20,8 @@ Gem::Specification.new do |spec|
|
|
20
20
|
spec.add_development_dependency "bundler", "~> 1.11"
|
21
21
|
spec.add_development_dependency "rake", "~> 10.0"
|
22
22
|
spec.add_development_dependency "rspec", "~> 3.0"
|
23
|
+
spec.add_development_dependency "pry"
|
23
24
|
|
24
25
|
spec.add_dependency "aws-sdk", "~> 2"
|
25
|
-
spec.add_dependency "gibberish", "~> 2"
|
26
26
|
spec.add_dependency "json"
|
27
|
-
spec.add_dependency "pry"
|
28
27
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: wes-cloudkit
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 4.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- ''
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-08-23 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -53,21 +53,21 @@ dependencies:
|
|
53
53
|
- !ruby/object:Gem::Version
|
54
54
|
version: '3.0'
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
|
-
name:
|
56
|
+
name: pry
|
57
57
|
requirement: !ruby/object:Gem::Requirement
|
58
58
|
requirements:
|
59
|
-
- - "
|
59
|
+
- - ">="
|
60
60
|
- !ruby/object:Gem::Version
|
61
|
-
version: '
|
62
|
-
type: :
|
61
|
+
version: '0'
|
62
|
+
type: :development
|
63
63
|
prerelease: false
|
64
64
|
version_requirements: !ruby/object:Gem::Requirement
|
65
65
|
requirements:
|
66
|
-
- - "
|
66
|
+
- - ">="
|
67
67
|
- !ruby/object:Gem::Version
|
68
|
-
version: '
|
68
|
+
version: '0'
|
69
69
|
- !ruby/object:Gem::Dependency
|
70
|
-
name:
|
70
|
+
name: aws-sdk
|
71
71
|
requirement: !ruby/object:Gem::Requirement
|
72
72
|
requirements:
|
73
73
|
- - "~>"
|
@@ -94,20 +94,6 @@ dependencies:
|
|
94
94
|
- - ">="
|
95
95
|
- !ruby/object:Gem::Version
|
96
96
|
version: '0'
|
97
|
-
- !ruby/object:Gem::Dependency
|
98
|
-
name: pry
|
99
|
-
requirement: !ruby/object:Gem::Requirement
|
100
|
-
requirements:
|
101
|
-
- - ">="
|
102
|
-
- !ruby/object:Gem::Version
|
103
|
-
version: '0'
|
104
|
-
type: :runtime
|
105
|
-
prerelease: false
|
106
|
-
version_requirements: !ruby/object:Gem::Requirement
|
107
|
-
requirements:
|
108
|
-
- - ">="
|
109
|
-
- !ruby/object:Gem::Version
|
110
|
-
version: '0'
|
111
97
|
description:
|
112
98
|
email:
|
113
99
|
- ''
|