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 newVaultTransitContext
instance.context
(byte[] context) Configure a key derivation context for thetransit
operation.keyVersion
(int keyVersion) Configure the key version to use.nonce
(byte[] nonce) Configure the nonce value for atransit
operation.
-
Method Details
-
context
Configure a key derivation context for thetransit
operation.- Parameters:
context
- key derivation context, provided as a binary data. Must be provided if derivation is enabled.- Returns:
this
VaultTransitContext.VaultTransitRequestBuilder
.
-
nonce
Configure the nonce value for atransit
operation. 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:
this
VaultTransitContext.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:
this
VaultTransitContext.VaultTransitRequestBuilder
.- Since:
- 3.0.3
-
build
Build a newVaultTransitContext
instance.- Returns:
- a new
VaultTransitContext
.
-