Skip to content

Commit

Permalink
Merge branch 'master' into upgrade_azserect_client
Browse files Browse the repository at this point in the history
  • Loading branch information
jiuker authored Apr 3, 2024
2 parents ab3f9aa + f7a894a commit ff8a662
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion internal/keystore/fortanix/keystore.go
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ func (s *Store) Status(ctx context.Context) (kes.KeyStoreState, error) {
}

start := time.Now()
resp, err := http.DefaultClient.Do(req)
resp, err := s.client.Do(req)
if err != nil {
return kes.KeyStoreState{}, &keystore.ErrUnreachable{Err: err}
}
Expand Down
2 changes: 1 addition & 1 deletion internal/keystore/gemalto/key-secure.go
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ func (s *Store) Status(ctx context.Context) (kes.KeyStoreState, error) {
}

start := time.Now()
resp, err := http.DefaultClient.Do(req)
resp, err := s.client.Do(req)
if err != nil {
return kes.KeyStoreState{}, &keystore.ErrUnreachable{Err: err}
}
Expand Down
4 changes: 2 additions & 2 deletions internal/keystore/vault/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ func (c *client) AuthenticateWithAppRole(login *AppRole) authFunc {
"role_id": login.ID,
"secret_id": login.Secret,
})
if secret == nil {
if secret == nil && err == nil {
// The Vault SDK eventually returns no error but also no
// secret. In this case have to return a (not very helpful)
// error to signal that the authentication failed - for some
Expand All @@ -108,7 +108,7 @@ func (c *client) AuthenticateWithK8S(login *Kubernetes) authFunc {
"role": login.Role,
"jwt": login.JWT,
})
if secret == nil {
if secret == nil && err == nil {
// The Vault SDK eventually returns no error but also no
// secret. In this case have to return a (not very helpful)
// error to signal that the authentication failed - for some
Expand Down

0 comments on commit ff8a662

Please sign in to comment.