Skip to content

Commit

Permalink
Updating
Browse files Browse the repository at this point in the history
  • Loading branch information
jboucourt committed Aug 6, 2024
1 parent ce0aa2a commit 94819bc
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions gestalt/vault.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@

EXPIRATION_THRESHOLD_DAYS = 5


class Vault(Provider):
def __init__(
self,
Expand Down Expand Up @@ -81,7 +82,6 @@ def connect(self) -> None:

if self._role and self._jwt:
try:

hvac.api.auth_methods.Kubernetes(
self.vault_client.adapter).login(role=self._role,
jwt=self._jwt)
Expand Down Expand Up @@ -253,8 +253,7 @@ def _validate_token_expiration(self) -> None:
expire_time = None
if 'expire_time' not in token_details['data']:
print("Key 'expire_time' does not exist in token_details['data']")
return None

return None
# Validate expire_time is present
if expire_time is None:
print("Cannot parse expire_time, value is None")
Expand Down

0 comments on commit 94819bc

Please sign in to comment.