Setups involving multiple Load-Balancers, proxies or other network appliances can give rise to more than one redirections occurring.
There may be several HTTP-3xx type redirects in scenarios where the use of the Vault CLI then results in unexpected responses of EOF
or data from server response is empty
like for example:
vault status ;
# RESULTS IN: Error checking seal status: EOF
vault operator members ;
# RESULTS IN: EOF
vault operator key-status ;
# RESULTS IN: Error reading key status: data from server response is empty
vault operator raft autopilot state ;
# RESULTS IN: Error checking autopilot state: data from server response is empty
vault operator raft list-peers ;
# RESULTS IN: No raft cluster configuration found
vault secrets enable -path=test -version=2 kv ;
# RESULTS IN: Success! Enabled the kv2 secrets engine at: kv_test/ |
These undesirable responses are an expected behaviour that's only encountered when using the CLI. The fact that the Vault CLI client will only follow a single redirection is also detailed on the Vault CLI documentation.
Repeating any of the above commands via their respective API equivalents (curl -L ...
) will not encounter any issues since the additional redirects continue to be followed further than merely the first unlike the CLI.