Skip to main content

Triage and Remediation

Remediation

Using Console

Sure, here are the steps to remediate the Azure Disk Encryption misconfiguration for boot disk volumes using the Azure console:
  1. Open the Azure portal and navigate to the virtual machine that you want to remediate.
  2. Click on the “Disks” option in the left-hand menu.
  3. Select the OS disk that you want to encrypt and click on “Disk encryption” in the top menu.
  4. Click on the “Enable” button to enable disk encryption.
  5. In the “Encryption settings” section, select “Azure managed key” and click on “Select existing” to select the key vault where the encryption key is stored.
  6. Select the key that you want to use for disk encryption and click on “Select”.
  7. Review the encryption settings and click on “Enable encryption” to start the encryption process.
  8. Wait for the encryption process to complete. This may take some time depending on the size of the disk.
  9. Once the encryption process is complete, restart the virtual machine to ensure that the encryption is applied to the boot disk.
That’s it! You have successfully remediated the Azure Disk Encryption misconfiguration for boot disk volumes using the Azure console.

Here are the step by step instructions to remediate Azure Disk Encryption for Boot Disk Volumes using Azure CLI:
  1. Check if the Azure Disk Encryption is enabled for the Boot Disk Volume of the Virtual Machine using the following command:
    If the output is true, then Azure Disk Encryption is enabled for the Boot Disk Volume.
  2. Disable the Azure Disk Encryption for the Boot Disk Volume of the Virtual Machine using the following command:
    This command will disable the Azure Disk Encryption for the Boot Disk Volume of the Virtual Machine.
  3. Verify if the Azure Disk Encryption is disabled for the Boot Disk Volume of the Virtual Machine using the following command:
    If the output is false, then Azure Disk Encryption is disabled for the Boot Disk Volume.
  4. Restart the Virtual Machine to complete the remediation process.
    This command will restart the Virtual Machine to complete the remediation process.
By following the above steps, you can remediate Azure Disk Encryption for Boot Disk Volumes using Azure CLI.
To remediate the misconfiguration “Azure Disk Encryption For Boot Disk Volumes”, you can use the following steps:
  1. Install the Azure PowerShell module using the following command:
  1. Connect to your Azure account using the following command:
  1. Retrieve the virtual machine that needs to be remediated using the following command:
  1. Check if the boot disk is already encrypted using the following command:
  1. If the boot disk is not encrypted, enable encryption for the boot disk using the following command:
Note: Replace <resource-group-name>, <vm-name>, <key-vault-name>, and <key-name> with the appropriate values.
  1. Verify that the boot disk is encrypted using the following command:
  1. Once you have verified that the boot disk is encrypted, you can disconnect from your Azure account using the following command:
This will remediate the misconfiguration “Azure Disk Encryption For Boot Disk Volumes” for your Azure virtual machine using Python.
Substitute:
  • VM_NAME, RG_NAME, NIC_NAME, VM_SIZE, ADMIN_USERNAME, ADMIN_PASSWORD, KV_NAME, ADE_KEY_NAME with your actual names/values.
Enabling Azure Disk Encryption via this extension will reboot the VM but does not force replacement of the VM resource itself; plan for downtime during initial encryption.To verify, terraform plan should show:
  • azurerm_windows_virtual_machine.VM_NAME either unchanged or updated only to add identity.
  • azurerm_key_vault.KV_NAME and azurerm_key_vault_key.ADE_KEY_NAME to be created (if new).
  • azurerm_virtual_machine_extension.ade to be created with publisher = "Microsoft.Azure.Security" and type = "AzureDiskEncryption".