Class VaultTransitContext.VaultTransitRequestBuilder
java.lang.Object
org.springframework.vault.support.VaultTransitContext.VaultTransitRequestBuilder
- Enclosing class:
- VaultTransitContext
Builder for
VaultTransitContext.-
Method Summary
Modifier and TypeMethodDescriptionbuild()Build a newVaultTransitContextinstance.context(byte[] context) Configure a key derivation context for thetransitoperation.keyVersion(int keyVersion) Configure the key version to use.nonce(byte[] nonce) Configure the nonce value for atransitoperation.
-
Method Details
-
context
Configure a key derivation context for thetransitoperation.- Parameters:
context- key derivation context, provided as a binary data. Must be provided if derivation is enabled.- Returns:
thisVaultTransitContext.VaultTransitRequestBuilder.
-
nonce
Configure the nonce value for atransitoperation. Must be provided if convergent encryption is enabled for this key and the key was generated with Vault 0.6.1. Not required for keys created in 0.6.2+.- Parameters:
nonce- value must be exactly 96 bits (12 bytes) long and the user must ensure that for any given context (and thus, any given encryption key) this nonce value is never reused- Returns:
thisVaultTransitContext.VaultTransitRequestBuilder.
-
keyVersion
Configure the key version to use. Must be greater than or equal to the key'smin_encryption_version. The key version is not used if not set.- Parameters:
keyVersion- the key version to be used, must be greater than or equal to the key'smin_encryption_version- Returns:
thisVaultTransitContext.VaultTransitRequestBuilder.- Since:
- 3.0.3
-
build
Build a newVaultTransitContextinstance.- Returns:
- a new
VaultTransitContext.
-