Class VaultTransitKeyCreationRequest.VaultTransitKeyCreationRequestBuilder
java.lang.Object
org.springframework.vault.support.VaultTransitKeyCreationRequest.VaultTransitKeyCreationRequestBuilder
- Enclosing class:
- VaultTransitKeyCreationRequest
public static class VaultTransitKeyCreationRequest.VaultTransitKeyCreationRequestBuilder
extends Object
Builder for
VaultTransitKeyCreationRequest
.-
Method Summary
Modifier and TypeMethodDescriptionallowPlaintextBackup
(boolean allowPlaintextBackup) Configure if the key supports plaintext backups.build()
Build a newVaultTransitKeyCreationRequest
instance.convergentEncryption
(boolean convergentEncryption) Configure convergent encryption where the same plaintext creates the same ciphertext.derived
(boolean derived) Configure key derivation.exportable
(boolean exportable) Configure if the raw key is exportable.Configure the key type.
-
Method Details
-
type
Configure the key type.- Parameters:
type
- the type of key to create, must not be empty or null.- Returns:
this
VaultTransitKeyCreationRequest.VaultTransitKeyCreationRequestBuilder
.
-
derived
public VaultTransitKeyCreationRequest.VaultTransitKeyCreationRequestBuilder derived(boolean derived) Configure key derivation.- Parameters:
derived
- true if key derivation MUST be used. If enabled, all encrypt/decrypt requests to this named key must provide a context which is used for key derivation. Defaults to false.- Returns:
this
VaultTransitKeyCreationRequest.VaultTransitKeyCreationRequestBuilder
.
-
convergentEncryption
public VaultTransitKeyCreationRequest.VaultTransitKeyCreationRequestBuilder convergentEncryption(boolean convergentEncryption) Configure convergent encryption where the same plaintext creates the same ciphertext. Requiresderived(boolean)
to be true.- Parameters:
convergentEncryption
- true the same plaintext creates the same ciphertext. Defaults to false.- Returns:
this
VaultTransitKeyCreationRequest.VaultTransitKeyCreationRequestBuilder
.
-
exportable
public VaultTransitKeyCreationRequest.VaultTransitKeyCreationRequestBuilder exportable(boolean exportable) Configure if the raw key is exportable.- Parameters:
exportable
- true the raw key is exportable. Defaults to false.- Returns:
this
VaultTransitKeyCreationRequest.VaultTransitKeyCreationRequestBuilder
.
-
allowPlaintextBackup
public VaultTransitKeyCreationRequest.VaultTransitKeyCreationRequestBuilder allowPlaintextBackup(boolean allowPlaintextBackup) Configure if the key supports plaintext backups.- Parameters:
allowPlaintextBackup
- true the key supports plaintext backups. Defaults to false.- Returns:
this
VaultTransitKeyCreationRequest.VaultTransitKeyCreationRequestBuilder
.- Since:
- 3.0.3
-
build
Build a newVaultTransitKeyCreationRequest
instance. Requirestype(String)
to be configured.- Returns:
- a new
VaultTransitKeyCreationRequest
.
-