question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Encrypt/decrypt local file with key vault

See original GitHub issue

Is your feature request related to a problem? Please describe. No, it is not.

Describe the solution you’d like I would like to be able to encrypt sensitive files with Azure Key Vault keys same way as for example google cloud cli does:

gcloud kms encrypt \
  --location=[LOCATION]  \
  --keyring=[KEY_RING] \
  --key=[KEY] \
  --plaintext-file=[FILEPATH_AND_FILENAME_TO_ENCRYPT] \
  --ciphertext-file=[FILEPATH_AND_FILENAME].enc

It would be very convinient and useful in daily work.

Example expected functionality behaviour:

az keyvault encrypt/decrypt
    --key-id
    --plaintext-file
    --ciphertext-file

Describe alternatives you’ve considered Google kms, hashicorp vault, ansible vault. I would like to have such feature in azure cli so my organization can be fully integrated with your services.

Additional context There is such a behaviour in your service API covered: https://docs.microsoft.com/en-us/rest/api/keyvault/encrypt

Issue Analytics

  • State:open
  • Created 4 years ago
  • Reactions:7
  • Comments:14 (7 by maintainers)

github_iconTop GitHub Comments

4reactions
naimadswdncommented, Aug 12, 2021

Hi, Any progress with encryption/decryption of local files using KV key? Actually I am extremely surprised that Azure CLI do not support it yet!

1reaction
bim-msftcommented, Aug 25, 2020

@BrandonE It works well on Dedicated HSM instances, for HSM-backed Vault it has not been supported yet.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Tutorial: Encrypt and decrypt blobs using Azure Key Vault
In this tutorial, you learn how to use client-side encryption to encrypt and decrypt blobs using a key stored with Azure Key Vault....
Read more >
Decryption with Azure Key Vault - OdeToCode
First, notice the EncryptAsync method fetches an RSA key from Key Vault and executes an encryption algorithm locally. Key Vault can encrypt data ......
Read more >
Using Key by Azure Key Vault to Encrypt and Decrypt text
I'm trying to use this to encrypt and decrypt cookies from a web API. So, I need to encrypt and decrypt my values...
Read more >
Using Azure Key Vault for Encryption in C# - A Simple Tutorial
Azure Key Vault is used to protect encryption keys and secrets. These keys and secrets can be used to access encrypted data and...
Read more >
How to use Azure key vault with PowerShell to encrypt data
Introduction · Create a resource group in Azure. · Create an Azure Key Vault and configure it with access policies. · Create an...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found