Skip to main content

More Info:

Enable transparent data encryption for all SQL databases.

Risk Level

Medium

Address

Reliability, Security

Compliance Standards

  • APRA CPS 234 (Australia)
  • BSI C5 (Germany)
  • Brazil LGPD
  • CCPA / CPRA (California)
  • CIS AZURE
  • CIS Critical Security Controls v8
  • CMMC 2.0
  • CSA Cloud Controls Matrix v4
  • Cloudanix Best Practice
  • DPDPA
  • Digital Operational Resilience Act (EU)
  • GDPR
  • HIPAA
  • HITRUST CSF
  • ISO 27001
  • ISO/IEC 27017
  • ISO/IEC 27018
  • ISO/IEC 27701
  • KSA PDPL
  • MAS Technology Risk Management (Singapore)
  • MITRE ATT&CK (Cloud)
  • NIS2 Directive
  • NIST
  • NIST CSF
  • NIST SP 800-171
  • NYDFS 23 NYCRR 500
  • PCI
  • SOC2
  • SWIFT Customer Security Controls Framework
  • Sarbanes-Oxley IT General Controls
  • Securities and Exchange Board of India (SEBI) - Cloud Security Adoption Framework
  • UK NCSC Cyber Assessment Framework

Triage and Remediation

Remediation

Using Console

To remediate the misconfiguration of Transparent Data Encryption Disabled for SQL Databases in Azure, you can follow the below steps using the Azure console:
  1. Log in to the Azure portal (https://portal.azure.com/).
  2. Navigate to the SQL databases section of the Azure portal.
  3. Select the SQL database for which you want to enable Transparent Data Encryption.
  4. Click on the “Transparent Data Encryption” option under the “Security” section in the left-hand menu.
  5. In the “Transparent Data Encryption” blade, toggle the “Status” switch to “On”.
  6. In the “Transparent Data Encryption” blade, select the “Service-managed key” option.
  7. Click on the “Save” button to enable Transparent Data Encryption for the selected SQL database.
After completing these steps, Transparent Data Encryption will be enabled for the selected SQL database in Azure.

To remediate the Transparent Data Encryption Disabled misconfiguration for SQL databases in AZURE using AZURE CLI, follow the below steps:Step 1: Connect to the Azure portal using the Azure CLI.Step 2: Run the below command to enable Transparent Data Encryption for an existing SQL database.
Note: Replace <database-name>, <resource-group-name>, and <server-name> with the actual names of the database, resource group, and server respectively.Step 3: Verify the status of the TDE encryption by running the below command.
This command will show the current status of the TDE encryption for the specified database.Step 4: Repeat Steps 2 and 3 for all the SQL databases in the Azure environment to ensure that Transparent Data Encryption is enabled for all the databases.By following the above steps, you can remediate the Transparent Data Encryption Disabled misconfiguration for SQL databases in AZURE using AZURE CLI.
To remediate the Transparent Data Encryption Disabled misconfiguration for SQL Databases in Azure using Python, you can use the Azure SDK for Python to enable TDE for all SQL databases in a given Azure SQL Server. Here are the step by step instructions:
  1. Install the Azure SDK for Python using pip:
  1. Authenticate with Azure using your Azure account credentials:
  1. Get a list of all the SQL Servers in your Azure subscription:
  1. For each SQL Server, get a list of all the SQL Databases and enable TDE for each database:
  1. Verify that TDE is now enabled for all SQL Databases:
These steps will enable TDE for all SQL Databases in all SQL Servers in your Azure subscription. You can run this Python script periodically to ensure that TDE is always enabled for all SQL Databases.
This change is in-place and does not force replacement of the database; Azure will enable TDE on the existing database.Verification: terraform plan should show transparent_data_encryption_enabled changing from false (or null/omitted) to true on the azurerm_mssql_database resource.