Benchmark: 4.1 SQL Server - Auditing
Overview
Auditing for Azure SQL Servers and SQL Databases tracks database events and writes them to an audit log Azure storage account, Log Analytics workspace or Event Hubs. Auditing helps to maintain regulatory compliance, understand database activity, and gain insight into discrepancies and anomalies that could indicate business concerns or suspected security violations. Auditing enables and facilitates adherence to compliance standards, although it doesn't guarantee compliance.
The Default SQL Server Auditing profile set for SQL server is inherited by all the SQL Databases which are part of the SQL server.
Usage
Install the mod:
mkdir dashboardscd dashboardspowerpipe mod initpowerpipe mod install github.com/turbot/steampipe-mod-azure-compliance
Start the Powerpipe server:
steampipe service startpowerpipe server
Open http://localhost:9033 in your browser and select 4.1 SQL Server - Auditing.
Run this benchmark in your terminal:
powerpipe benchmark run azure_compliance.benchmark.cis_v210_4_1
Snapshot and share results via Turbot Pipes:
powerpipe benchmark run azure_compliance.benchmark.cis_v210_4_1 --share
Controls
- 4.1.1 Ensure that 'Auditing' is set to 'On'
- 4.1.2 Ensure no Azure SQL Databases allow ingress from 0.0.0.0/0 (ANY IP)
- 4.1.3 Ensure SQL server's Transparent Data Encryption (TDE) protector is encrypted with Customer-managed key
- 4.1.4 Ensure that Microsoft Entra authentication is Configured for SQL Servers
- 4.1.5 Ensure that 'Data encryption' is set to 'On' on a SQL Database
- 4.1.6 Ensure that 'Auditing' Retention is 'greater than 90 days'