public class Seal
extends java.lang.Object
The implementing class for operations on REST endpoints, under the "seal/unseal/seal-status" section of the Vault HTTP API docs (https://www.vaultproject.io/api/system/index.html).
This class is not intended to be constructed directly. Rather, it is meant to used by way of
Vault in a DSL-style builder pattern. See the Javadoc comments of each public
method for usage examples.
| Constructor and Description |
|---|
Seal(VaultConfig config) |
| Modifier and Type | Method and Description |
|---|---|
void |
seal()
Seal the Vault.
|
SealResponse |
sealStatus()
Check progress of unsealing the Vault.
|
SealResponse |
unseal(java.lang.String key)
Enter a single master key share to progress the unsealing of the Vault.
|
SealResponse |
unseal(java.lang.String key,
java.lang.Boolean reset)
Enter a single master key share to progress the unsealing of the Vault.
|
public Seal(VaultConfig config)
public void seal()
throws VaultException
Seal the Vault.
VaultException - If any error occurs, or unexpected response received from Vaultpublic SealResponse unseal(java.lang.String key) throws VaultException
Enter a single master key share to progress the unsealing of the Vault.
key - Single master key shareVaultException - If any error occurs, or unexpected response received from Vaultpublic SealResponse unseal(java.lang.String key, java.lang.Boolean reset) throws VaultException
Enter a single master key share to progress the unsealing of the Vault.
key - Single master key sharereset - Specifies if previously-provided unseal keys are discarded and the unseal process is resetVaultException - If any error occurs, or unexpected response received from Vaultpublic SealResponse sealStatus() throws VaultException
Check progress of unsealing the Vault.
VaultException - If any error occurs, or unexpected response received from Vault