Threat Alert Email To Owner

LOW
Source
Trivy
ID
AVD-AZU-0023

Security threat alerts go to subscription owners and co-administrators

Subscription owners should be notified when there are security alerts. By ensuring the administrators of the account have been notified they can quickly assist in any required remediation

Impact

Follow the appropriate remediation steps below to resolve the issue.

Enable email to subscription owners

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
resource "azurerm_sql_server" "example" {
  name                = "mysqlserver"
  resource_group_name = azurerm_resource_group.example.name
  location            = azurerm_resource_group.example.location
  version             = "12.0"
}

resource "azurerm_mssql_server_security_alert_policy" "good_example" {
  resource_group_name = azurerm_resource_group.example.name
  server_name         = azurerm_sql_server.example.name
  state               = "Enabled"

  email_account_admins = true
}