Skip to content
This repository has been archived by the owner on Jul 1, 2024. It is now read-only.

kms-vault: Support HTTP redirect for Vault requests. #52

Open
chris-giblin opened this issue Aug 29, 2022 · 0 comments
Open

kms-vault: Support HTTP redirect for Vault requests. #52

chris-giblin opened this issue Aug 29, 2022 · 0 comments
Labels
enhancement New feature or request kms vault

Comments

@chris-giblin
Copy link
Contributor

As discussed in PR #51 (comment), HTTP redirect responses (3xx) are not currently supported but need to be. The goal of this issue is to implement redirects as required by Vault.

Background information.

  • HTTP redirects are legitimately used when Vault is deployed in a High Availability configuration.
  • Current Vault KMS provider makes explicit, precise check for HTTP status 200 on Vault responses (see PR discussion linked above).
  • The HTTP client currently is not created with a redirect policy. As a result, redirects will not be followed. Because of the previous point, the redirect status code will be compared against 200 and be treated as an error.
  • Consider supporting a KMS provider-specific configuration parameter such as follow-redirects with values true|false, corresponding to the HTTP client Always|Never settings in the HttpRedirect policy, so that redirection can be enabled or disabled.
  • Using the HttpRequest.Builder, create the HTTP client under consideration of the configured redirect policy.
@chris-giblin chris-giblin mentioned this issue Aug 29, 2022
@chris-giblin chris-giblin added enhancement New feature or request vault kms labels Aug 29, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request kms vault
Projects
None yet
Development

No branches or pull requests

1 participant