1. Packages
  2. HashiCorp Vault
  3. API Docs
  4. transit
  5. getEncrypt
HashiCorp Vault v6.1.0 published on Thursday, Apr 4, 2024 by Pulumi

vault.transit.getEncrypt

Explore with Pulumi AI

vault logo
HashiCorp Vault v6.1.0 published on Thursday, Apr 4, 2024 by Pulumi

    This is a data source which can be used to encrypt plaintext using a Vault Transit key.

    Using getEncrypt

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getEncrypt(args: GetEncryptArgs, opts?: InvokeOptions): Promise<GetEncryptResult>
    function getEncryptOutput(args: GetEncryptOutputArgs, opts?: InvokeOptions): Output<GetEncryptResult>
    def get_encrypt(backend: Optional[str] = None,
                    context: Optional[str] = None,
                    key: Optional[str] = None,
                    key_version: Optional[int] = None,
                    namespace: Optional[str] = None,
                    plaintext: Optional[str] = None,
                    opts: Optional[InvokeOptions] = None) -> GetEncryptResult
    def get_encrypt_output(backend: Optional[pulumi.Input[str]] = None,
                    context: Optional[pulumi.Input[str]] = None,
                    key: Optional[pulumi.Input[str]] = None,
                    key_version: Optional[pulumi.Input[int]] = None,
                    namespace: Optional[pulumi.Input[str]] = None,
                    plaintext: Optional[pulumi.Input[str]] = None,
                    opts: Optional[InvokeOptions] = None) -> Output[GetEncryptResult]
    func GetEncrypt(ctx *Context, args *GetEncryptArgs, opts ...InvokeOption) (*GetEncryptResult, error)
    func GetEncryptOutput(ctx *Context, args *GetEncryptOutputArgs, opts ...InvokeOption) GetEncryptResultOutput

    > Note: This function is named GetEncrypt in the Go SDK.

    public static class GetEncrypt 
    {
        public static Task<GetEncryptResult> InvokeAsync(GetEncryptArgs args, InvokeOptions? opts = null)
        public static Output<GetEncryptResult> Invoke(GetEncryptInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetEncryptResult> getEncrypt(GetEncryptArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: vault:transit/getEncrypt:getEncrypt
      arguments:
        # arguments dictionary

    The following arguments are supported:

    Backend string
    The path the transit secret backend is mounted at, with no leading or trailing /.
    Key string
    Specifies the name of the transit key to encrypt against.
    Plaintext string
    Plaintext to be encoded.
    Context string
    Context for key derivation. This is required if key derivation is enabled for this key.
    KeyVersion int
    The version of the key to use for encryption. If not set, uses the latest version. Must be greater than or equal to the key's min_encryption_version, if set.
    Namespace string
    Backend string
    The path the transit secret backend is mounted at, with no leading or trailing /.
    Key string
    Specifies the name of the transit key to encrypt against.
    Plaintext string
    Plaintext to be encoded.
    Context string
    Context for key derivation. This is required if key derivation is enabled for this key.
    KeyVersion int
    The version of the key to use for encryption. If not set, uses the latest version. Must be greater than or equal to the key's min_encryption_version, if set.
    Namespace string
    backend String
    The path the transit secret backend is mounted at, with no leading or trailing /.
    key String
    Specifies the name of the transit key to encrypt against.
    plaintext String
    Plaintext to be encoded.
    context String
    Context for key derivation. This is required if key derivation is enabled for this key.
    keyVersion Integer
    The version of the key to use for encryption. If not set, uses the latest version. Must be greater than or equal to the key's min_encryption_version, if set.
    namespace String
    backend string
    The path the transit secret backend is mounted at, with no leading or trailing /.
    key string
    Specifies the name of the transit key to encrypt against.
    plaintext string
    Plaintext to be encoded.
    context string
    Context for key derivation. This is required if key derivation is enabled for this key.
    keyVersion number
    The version of the key to use for encryption. If not set, uses the latest version. Must be greater than or equal to the key's min_encryption_version, if set.
    namespace string
    backend str
    The path the transit secret backend is mounted at, with no leading or trailing /.
    key str
    Specifies the name of the transit key to encrypt against.
    plaintext str
    Plaintext to be encoded.
    context str
    Context for key derivation. This is required if key derivation is enabled for this key.
    key_version int
    The version of the key to use for encryption. If not set, uses the latest version. Must be greater than or equal to the key's min_encryption_version, if set.
    namespace str
    backend String
    The path the transit secret backend is mounted at, with no leading or trailing /.
    key String
    Specifies the name of the transit key to encrypt against.
    plaintext String
    Plaintext to be encoded.
    context String
    Context for key derivation. This is required if key derivation is enabled for this key.
    keyVersion Number
    The version of the key to use for encryption. If not set, uses the latest version. Must be greater than or equal to the key's min_encryption_version, if set.
    namespace String

    getEncrypt Result

    The following output properties are available:

    Backend string
    Ciphertext string
    Encrypted ciphertext returned from Vault
    Id string
    The provider-assigned unique ID for this managed resource.
    Key string
    Plaintext string
    Context string
    KeyVersion int
    Namespace string
    Backend string
    Ciphertext string
    Encrypted ciphertext returned from Vault
    Id string
    The provider-assigned unique ID for this managed resource.
    Key string
    Plaintext string
    Context string
    KeyVersion int
    Namespace string
    backend String
    ciphertext String
    Encrypted ciphertext returned from Vault
    id String
    The provider-assigned unique ID for this managed resource.
    key String
    plaintext String
    context String
    keyVersion Integer
    namespace String
    backend string
    ciphertext string
    Encrypted ciphertext returned from Vault
    id string
    The provider-assigned unique ID for this managed resource.
    key string
    plaintext string
    context string
    keyVersion number
    namespace string
    backend str
    ciphertext str
    Encrypted ciphertext returned from Vault
    id str
    The provider-assigned unique ID for this managed resource.
    key str
    plaintext str
    context str
    key_version int
    namespace str
    backend String
    ciphertext String
    Encrypted ciphertext returned from Vault
    id String
    The provider-assigned unique ID for this managed resource.
    key String
    plaintext String
    context String
    keyVersion Number
    namespace String

    Package Details

    Repository
    Vault pulumi/pulumi-vault
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the vault Terraform Provider.
    vault logo
    HashiCorp Vault v6.1.0 published on Thursday, Apr 4, 2024 by Pulumi