5101e31857
* Stub out initial health check command This command will be used to generate health check results for the PKI engine. Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com> * Start common health check implementation Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com> * Add common health check utilities These utilities will collect helpers not specific to PKI health checks, such as formatting longer durations more legibly. Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com> * Add PKI health check common utils Many health checks will need issuer and/or CRL information in order to execute. We've centrally located these helpers to avoid particular health checks from needing to reimplement them each time. Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com> * Adding ca_validity_period health check Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com> * Begin using health-checks in PKI command Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com> * Allow parsing raw requests afterwards This shifts the last of the logic difference between Read(...) and ReadRaw(...) to a new helper, allowing ReadRaw(...) requests to be parsed into the same response structure afterwards as Read(...); this allows API callers to fetch the raw secret and inspect the raw response object in case something went wrong (error code &c) -- and when the request succeeds, they can still get the api.Secret out. This will be used with the PKI health check functionality, making both LIST and READ operations use ReadRaw, and optionally parsing the secret afterwards. Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com> * Add crl_validity_period health check Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com> * Add tests for PKI health check Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com> * Fix bug in raw reading with contexts When reading raw objects, don't manually call the context cancellation: this causes timeouts and/or EOF errors when attempting to read or parse the response body. See message in client.RawRequestWithContext(...) for more information. This was causing the test suite to randomly fail, due to the context cancelling. The test suite's client usually had a default timeout, whereas the CLI didn't, and thus didn't exhibit the same issue. Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com> * Add changelog Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com> * Fix typo in permissions message Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com> * Move %v->%w for errs Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com> Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com> |
||
---|---|---|
.. | ||
auth | ||
test-fixtures | ||
api_test.go | ||
auth.go | ||
auth_test.go | ||
auth_token.go | ||
client.go | ||
client_test.go | ||
go.mod | ||
go.sum | ||
help.go | ||
kv.go | ||
kv_test.go | ||
kv_v1.go | ||
kv_v2.go | ||
lifetime_watcher.go | ||
logical.go | ||
output_policy.go | ||
output_string.go | ||
plugin_helpers.go | ||
plugin_helpers_test.go | ||
README.md | ||
renewer_test.go | ||
request.go | ||
request_test.go | ||
response.go | ||
secret.go | ||
ssh.go | ||
ssh_agent.go | ||
ssh_agent_test.go | ||
sys.go | ||
sys_audit.go | ||
sys_auth.go | ||
sys_capabilities.go | ||
sys_config_cors.go | ||
sys_generate_root.go | ||
sys_hastatus.go | ||
sys_health.go | ||
sys_init.go | ||
sys_leader.go | ||
sys_leases.go | ||
sys_mfa.go | ||
sys_monitor.go | ||
sys_mounts.go | ||
sys_mounts_test.go | ||
sys_plugins.go | ||
sys_plugins_test.go | ||
sys_policy.go | ||
sys_raft.go | ||
sys_rekey.go | ||
sys_rotate.go | ||
sys_seal.go | ||
sys_stepdown.go |
Vault API
This provides the github.com/hashicorp/vault/api
package which contains code useful for interacting with a Vault server.
For examples of how to use this module, see the vault-examples repo. For a step-by-step walkthrough on using these client libraries, see the developer quickstart.