keycardai-oauth 0.15.0 → 0.15.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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 2270af78d15b4eaffa12e3f66d5f7ad750705a4b9e09c38a0473a49b358f7271
4
- data.tar.gz: d036adb9c1c73b34e7ad1a30c03603781a2a55ea32cdc2606dd6c059b407d6d9
3
+ metadata.gz: a7400d25827d149ad7a740292601c57eb0b65c2774129f3e1611641ae137dbba
4
+ data.tar.gz: 529c41f9789e2def9c3891d107c76cb22a97614d2a1e3dc9ff86e1464606a345
5
5
  SHA512:
6
- metadata.gz: 9f3c50b35c045bbada1c713da736e9746d1b4d720b0cbb9ba3c8c498952617e1b1b6d91d7aca4710d0f58fd2fb7b1c83142eb46203ed09000a6c59886fd0a240
7
- data.tar.gz: b023b385d517a4a4155763e656b0cb6614e307ce6d0df3836704a33b1dced3f3a2dd5cfe63fab14a52fd52499b960ddf29583e8aa900321d44d289ae7caaaac3
6
+ metadata.gz: 4797054e9a97e1a39772e3b6fcc2afc9c211b21e11226073bab08d070576a67b5e36a2fe41e79b01bf13252d39e8dd95cf119ba4f0d875f4e6e8a1526e144def
7
+ data.tar.gz: 170c9f2e56942af0de2bd02827e36f396396b1bfbff8e62e3d1359327a23fcebe792c349244c4071e7dfafe0cf2ec988c0389df8333e68e5ae08e71c4d78824a
data/CHANGELOG.md CHANGED
@@ -15,6 +15,18 @@ the loopback flow (RFC 8252), JWT signing and verification with a caching JWKS
15
15
  keyring, the three application credentials (ClientSecret with multi-zone,
16
16
  WebIdentity, WorkloadIdentity with pluggable token sources), and AccessContext.
17
17
 
18
+ ## 0.15.1-keycardai-oauth (2026-11-26)
19
+
20
+
21
+ - fix(keycardai-oauth): classify workload identity file failures (#122)
22
+ - * fix(keycardai-oauth): classify workload identity file failures
23
+ - Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
24
+ - * fix(keycardai-oauth): classify token file encoding failures at construction
25
+ - Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
26
+ - ---------
27
+ - Co-authored-by: devin-ai-keycard <devin-ai@keycard.ai>
28
+ Co-authored-by: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
29
+
18
30
  ## 0.15.0-keycardai-oauth (2026-11-26)
19
31
 
20
32
 
@@ -36,11 +36,14 @@ module Keycardai
36
36
  # @raise [WorkloadIdentityRuntimeError] unreadable or empty file
37
37
  def identity_token
38
38
  token = File.read(@path).strip
39
- raise WorkloadIdentityRuntimeError.new("token file #{@path} is empty", source: "file") if token.empty?
39
+ if token.empty?
40
+ raise WorkloadIdentityRuntimeError.new("token file #{@path} is empty", source: "file", retryable: true)
41
+ end
40
42
 
41
43
  token
42
44
  rescue SystemCallError => e
43
- raise WorkloadIdentityRuntimeError.new("token file #{@path} is unreadable: #{e.message}", source: "file")
45
+ raise WorkloadIdentityRuntimeError.new("token file #{@path} is unreadable: #{e.message}",
46
+ source: "file", retryable: true)
44
47
  end
45
48
 
46
49
  def source_identifier
@@ -61,9 +64,11 @@ module Keycardai
61
64
  end
62
65
 
63
66
  def validate_file
64
- return if File.file?(@path) && !File.empty?(@path)
67
+ return if File.file?(@path) && !File.read(@path).strip.empty?
65
68
 
66
69
  raise WorkloadIdentityConfigurationError.new("token file #{@path} is missing or empty", source: "file")
70
+ rescue SystemCallError, ArgumentError, EncodingError => e
71
+ raise WorkloadIdentityConfigurationError.new("token file #{@path} is unreadable: #{e.message}", source: "file")
67
72
  end
68
73
  end
69
74
 
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Keycardai
4
4
  module OAuth
5
- VERSION = "0.15.0"
5
+ VERSION = "0.15.1"
6
6
  end
7
7
  end
@@ -62,7 +62,7 @@ module Keycardai
62
62
  raise
63
63
  rescue StandardError => e
64
64
  raise WorkloadIdentityRuntimeError.new("identity token source failed: #{e.message}",
65
- source: source_identifier_for(source))
65
+ source: "custom")
66
66
  end
67
67
 
68
68
  def self.source_identifier_for(source)
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: keycardai-oauth
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.15.0
4
+ version: 0.15.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Keycard