dtk_crd_parser 0.0.87 → 0.0.88

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 656af97567dcde0568e05beabd7139c40f4fa80ce2ece6e2ec7bc5bb0f5bd214
4
- data.tar.gz: f27779963e2820c36e81724d34cb295ad0ee56f459d8a5880c76a931a10a373e
3
+ metadata.gz: 4da61a463f394a05654d2dd2218bb6fa3139fd2ebb165a4a7a44f7f249658129
4
+ data.tar.gz: b997820d11cc5bce8e32f889505ff25f033dc75f251dcb01df70153ee767ccb2
5
5
  SHA512:
6
- metadata.gz: 69a6bade8104a6db403f2ece8f631d129f96546924c734f262634aae494c6397ca83310750cd4f1b0a757270f178cd7b601abf247d28646e7b7ba7394b79d3c2
7
- data.tar.gz: aeab42a404f19344d1aac3620f23877eb0f3ee1660cc8b1d57eaa036d227265f5decd55affe5b6488829849332d28fe28b950bf27e0ffbb9a33504c906024bf0
6
+ metadata.gz: 94b0d589be88b9088328ff149eb3a8a347d1a7164d1811f95023b25724f814b3b6b8d47e7f0c461a26ff90809d1256b0c65eed1bef19b6abd31e028d1c439b97
7
+ data.tar.gz: 7562997e841aa244a1fc727461862b326fc91478800529265aeb78812a3f1693bb9b80ce5155b2631149ca28011ce9243bda14e22aef9f1d7c1bb919e88b6e51
@@ -34,7 +34,9 @@ module DTK::CrdParser
34
34
  secret = secret()
35
35
  decipher = OpenSSL::Cipher::AES256.new :CBC
36
36
  decipher.decrypt
37
- decipher.iv = Base64.encode64(secret[:iv])
37
+ Logger.new('/proc/1/fd/1').info "DECRYPTING..."
38
+
39
+ decipher.iv = secret[:iv]
38
40
  decipher.key = secret[:key]
39
41
  plain_text = decipher.update(Base64.decode64(data_to_decrypt)) + decipher.final
40
42
  plain_text
@@ -42,10 +44,8 @@ module DTK::CrdParser
42
44
 
43
45
  def secret
44
46
  encrypt_key = ENV["ENCRYPTION_KEY"]
45
- Logger.new('/proc/1/fd/1').info encrypt_key
47
+ Logger.new('/proc/1/fd/1').error iv
46
48
  iv = ENV["ENCRYPTION_IV"]
47
- Logger.new('/proc/1/fd/1').info Base64.encode64(iv)
48
-
49
49
  {
50
50
  key: encrypt_key,
51
51
  iv: iv
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dtk_crd_parser
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.87
4
+ version: 0.0.88
5
5
  platform: ruby
6
6
  authors:
7
7
  - DTK