asherah 0.4.1-x86_64-darwin → 0.4.2-x86_64-darwin

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: 46a32c9a068ef3956cb3036adb9ac752b64f88ca07c062cb1c0e848b04756c26
4
- data.tar.gz: bc91b0fc80b0b0c90c08444d1d0cf9d440c5f8442a15e400d701e885972dea60
3
+ metadata.gz: e50cc49148c63059f24c4ab7660b21a9874768aec6fdec67effbe9d0fb6d279c
4
+ data.tar.gz: fc9c513d7e3a3b44a4f2b25706d9893f3709c78a5b780e216e2dbe0d8ce6b3ac
5
5
  SHA512:
6
- metadata.gz: 932371d7be7859d5fde6f72854e94d772d7a559317df7bcf6f92f7377edb079c90754335577c74f34f96d23b39290b934e4d32df16f23dd0cb68a40a9338b45a
7
- data.tar.gz: 9df70760f9606b0ee610f5d6242d5a1648b5b5807e37603fb502e4bdac9ec808ada47a767987775010f81e9511bf45ff5af58488e103c16b6fe897276cae0a74
6
+ metadata.gz: 70b04c51ec0ff3a94fd8bb723a75ddfe35498f235651176c2e922c8f2d9e29105a244bda155fe0daf65c59f7d9d0cb659edf98cbbae763f3d0c4ce33321bdd06
7
+ data.tar.gz: 06fd9065cec8aff58326129ff24643730941908b0b700247042dd6d7fd4c55997c470d3dd379c94cd9805b57d68c6ff67670401aa5aaa144af521832e1bc4bd7
data/.rubocop.yml CHANGED
@@ -32,3 +32,6 @@ Metrics/AbcSize:
32
32
 
33
33
  Style/GuardClause:
34
34
  Enabled: false
35
+
36
+ Naming/AccessorMethodName:
37
+ Enabled: false
data/CHANGELOG.md CHANGED
@@ -1,5 +1,10 @@
1
1
  ## [Unreleased]
2
2
 
3
+ ## [0.4.2] - 2022-07-25
4
+
5
+ - Upgrade to use asherah-cobhan v0.4.15
6
+ - Add `set_env` method to set environment variables for Asherah
7
+
3
8
  ## [0.4.1] - 2022-03-25
4
9
 
5
10
  - Build and release platform gems
@@ -1,5 +1,5 @@
1
- version: v0.4.11
2
- libasherah-arm64.so: bc044b74453fc8fceca564fb127c9f2748aeac107791bd24c680ced1fcb7b816
3
- libasherah-x64.so: 82f10505ef11fba2c8e027668d9b5c89584f73eb1e53a9f5ff21d5705ecffb3a
4
- libasherah-arm64.dylib: 0b843d002212722c442c990d84e6ceac73c78e1663260be8c3f759a9a283b14a
5
- libasherah-x64.dylib: fd0592ed4cdfbc7b3a2534b540c22301a9669c6c37dfb3d28f600ccc9ba975f8
1
+ version: v0.4.15
2
+ libasherah-arm64.so: 43122390d0f851ac67bb197d688dd040832292e79675e4a9c9268d4ef5d3aef7
3
+ libasherah-x64.so: 3d29f32f6560858c54dc3cc87fa59347f2981a0e206849f0f3ab9a905de02242
4
+ libasherah-arm64.dylib: e7d64c2857c120b065c1761445d797f6fd5f6696c26676857ce327a772d6c025
5
+ libasherah-x64.dylib: 331ea09b160de80a3e40aeeb737779da3c043e2476f7cbfe4b83cf55fccdf0c7
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Asherah
4
- VERSION = '0.4.1'
4
+ VERSION = '0.4.2'
5
5
  end
data/lib/asherah.rb CHANGED
@@ -11,6 +11,7 @@ module Asherah
11
11
 
12
12
  LIB_ROOT_PATH = File.expand_path('asherah/native', __dir__)
13
13
  load_library(LIB_ROOT_PATH, 'libasherah', [
14
+ [:SetEnv, [:pointer], :int32],
14
15
  [:SetupJson, [:pointer], :int32],
15
16
  [:EncryptToJson, [:pointer, :pointer, :pointer], :int32],
16
17
  [:DecryptFromJson, [:pointer, :pointer, :pointer], :int32],
@@ -22,6 +23,22 @@ module Asherah
22
23
  BASE64_OVERHEAD = 1.34
23
24
 
24
25
  class << self
26
+ # Set environment variables needed by Asherah dependencies for when
27
+ # Go os.Getenv() doesn't see variables set by C.setenv().
28
+ # References:
29
+ # https://github.com/golang/go/wiki/cgo#environmental-variables
30
+ # https://github.com/golang/go/issues/44108
31
+ #
32
+ # @yield [Config]
33
+ # @param env [Hash], Key-value pairs to set Asherah ENV
34
+ # @return [void]
35
+ def set_env(env = {})
36
+ env_buffer = string_to_cbuffer(env.to_json)
37
+
38
+ result = SetEnv(env_buffer)
39
+ Error.check_result!(result, 'SetEnv failed')
40
+ end
41
+
25
42
  # Configures Asherah
26
43
  #
27
44
  # @yield [Config]
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: asherah
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.1
4
+ version: 0.4.2
5
5
  platform: x86_64-darwin
6
6
  authors:
7
7
  - GoDaddy
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2022-03-25 00:00:00.000000000 Z
11
+ date: 2022-07-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: cobhan