diff --git a/docs/content/en/docs/Recommendations/_index.md b/docs/content/en/docs/Recommendations/_index.md index 42f58e5d..b7f280b2 100644 --- a/docs/content/en/docs/Recommendations/_index.md +++ b/docs/content/en/docs/Recommendations/_index.md @@ -49,7 +49,7 @@ Azure Quick Review checks the following recommendations for Azure resources. The 39 | Governance | Low | AKS Name should comply with naming conventions | [Learn](https://learn.microsoft.com/en-us/azure/cloud-adoption-framework/ready/azure-best-practices/resource-abbreviations) 40 | Security | Medium | AKS should integrate authentication with AAD (Managed) | [Learn](https://learn.microsoft.com/en-us/azure/aks/managed-azure-ad) 41 | Security | Medium | AKS should be RBAC enabled. | [Learn](https://learn.microsoft.com/azure/aks/manage-azure-rbac) -42 | Security | Medium | AKS should have local accounts disabled | [Learn](https://learn.microsoft.com/azure/aks/managed-aad#disable-local-accounts) +42 | Security | Medium | AKS should have local accounts disabled | [Learn](https://learn.microsoft.com/en-us/azure/aks/manage-local-accounts-managed-azure-ad#disable-local-accounts) 43 | Security | Medium | AKS should have httpApplicationRouting disabled | [Learn](https://learn.microsoft.com/azure/aks/http-application-routing) 44 | Monitoring and Alerting | High | AKS should have Container Insights enabled | [Learn](https://learn.microsoft.com/azure/azure-monitor/insights/container-insights-overview) 45 | Security | High | AKS should have outbound type set to user defined routing | [Learn](https://learn.microsoft.com/azure/aks/limit-egress-traffic) @@ -272,60 +272,59 @@ Azure Quick Review checks the following recommendations for Azure resources. The 262 | Governance | Low | SQL Name should comply with naming conventions | [Learn](https://learn.microsoft.com/en-us/azure/cloud-adoption-framework/ready/azure-best-practices/resource-abbreviations) 263 | Governance | Low | SQL should have tags | [Learn](https://learn.microsoft.com/en-us/azure/azure-resource-manager/management/tag-resources?tabs=json) 264 | Security | Low | SQL should enforce TLS >= 1.2 | [Learn](https://learn.microsoft.com/en-us/azure/azure-sql/database/connectivity-settings?view=azuresql&tabs=azure-portal#minimal-tls-version) -265 | Monitoring and Alerting | Low | SQL Database should have diagnostic settings enabled | [Learn]() -266 | High Availability | High | SQL Database should have availability zones enabled | [Learn]() -267 | High Availability | High | SQL Database should have a SLA | [Learn]() -268 | High Availability | High | SQL Database SKU | [Learn](https://docs.microsoft.com/en-us/azure/azure-sql/database/service-tiers-vcore?tabs=azure-portal) -269 | Governance | Low | SQL Database Name should comply with naming conventions | [Learn](https://learn.microsoft.com/en-us/azure/cloud-adoption-framework/ready/azure-best-practices/resource-abbreviations) -270 | Governance | Low | SQL Database should have tags | [Learn](https://learn.microsoft.com/en-us/azure/azure-resource-manager/management/tag-resources?tabs=json) -271 | Monitoring and Alerting | Low | Traffic Manager should have diagnostic settings enabled | [Learn](https://learn.microsoft.com/en-us/azure/traffic-manager/traffic-manager-diagnostic-logs) -272 | High Availability | High | Traffic Manager should have availability zones enabled | [Learn](https://learn.microsoft.com/en-us/azure/architecture/high-availability/reference-architecture-traffic-manager-application-gateway) -273 | High Availability | High | Traffic Manager should have a SLA | [Learn](https://www.azure.cn/en-us/support/sla/traffic-manager/) -274 | Governance | Low | Traffic Manager Name should comply with naming conventions | [Learn](https://learn.microsoft.com/en-us/azure/cloud-adoption-framework/ready/azure-best-practices/resource-abbreviations) -275 | Governance | Low | Traffic Manager should have tags | [Learn](https://learn.microsoft.com/en-us/azure/azure-resource-manager/management/tag-resources?tabs=json) -276 | High Availability | High | Traffic Manager should use at least 2 endpoints | [Learn](https://learn.microsoft.com/en-us/azure/traffic-manager/traffic-manager-endpoint-types) -277 | Security | High | Traffic Manager: HTTP endpoints should be monitored using HTTPS | [Learn](https://learn.microsoft.com/en-us/azure/traffic-manager/traffic-manager-monitoring) -278 | Monitoring and Alerting | Low | Storage should have diagnostic settings enabled | [Learn](https://learn.microsoft.com/en-us/azure/storage/blobs/monitor-blob-storage) -279 | High Availability | High | Storage should have availability zones enabled | [Learn](https://learn.microsoft.com/EN-US/azure/reliability/migrate-storage) -280 | High Availability | High | Storage should have a SLA | [Learn](https://www.azure.cn/en-us/support/sla/storage/) -281 | Security | High | Storage should have private endpoints enabled | [Learn](https://learn.microsoft.com/en-us/azure/storage/common/storage-private-endpoints) -282 | High Availability | High | Storage SKU | [Learn](https://learn.microsoft.com/en-us/rest/api/storagerp/srp_sku_types) -283 | Governance | Low | Storage Name should comply with naming conventions | [Learn](https://learn.microsoft.com/en-us/azure/cloud-adoption-framework/ready/azure-best-practices/resource-abbreviations) -284 | Security | High | Storage Account should use HTTPS only | [Learn](https://learn.microsoft.com/en-us/azure/storage/common/storage-require-secure-transfer) -285 | Governance | Low | Storage Account should have tags | [Learn](https://learn.microsoft.com/en-us/azure/azure-resource-manager/management/tag-resources?tabs=json) -286 | Security | Low | Storage Account should enforce TLS >= 1.2 | [Learn](https://learn.microsoft.com/en-us/azure/storage/common/transport-layer-security-configure-minimum-version?tabs=portal) -287 | Disaster Recovery | Low | Storage Account should have inmutable storage versioning enabled | [Learn](https://learn.microsoft.com/en-us/azure/well-architected/service-guides/storage-accounts/reliability) -288 | Disaster Recovery | Medium | Storage Account should have soft delete enabled | [Learn](https://learn.microsoft.com/en-us/azure/well-architected/service-guides/storage-accounts/reliability) -289 | Monitoring and Alerting | Low | Virtual Machine should have diagnostic settings enabled | [Learn](https://learn.microsoft.com/en-us/azure/azure-monitor/agents/diagnostics-extension-windows-install) -290 | High Availability | High | Virtual Machine should have availability zones enabled | [Learn](https://learn.microsoft.com/en-us/azure/virtual-machines/availability#availability-zones) -291 | High Availability | High | Virtual Machine should have a SLA | [Learn](https://www.microsoft.com/licensing/docs/view/Service-Level-Agreements-SLA-for-Online-Services?lang=1) -292 | Governance | Low | Virtual Machine Name should comply with naming conventions | [Learn](https://learn.microsoft.com/en-us/azure/cloud-adoption-framework/ready/azure-best-practices/resource-abbreviations) -293 | Governance | Low | Virtual Machine should have tags | [Learn](https://learn.microsoft.com/en-us/azure/azure-resource-manager/management/tag-resources?tabs=json) -294 | High Availability | High | Virtual Machine should use managed disks | [Learn](https://learn.microsoft.com/en-us/azure/architecture/checklist/resiliency-per-service#virtual-machines) -295 | Scalability | Low | Virtual Machine should host application or database data on a data disk | [Learn](https://learn.microsoft.com/azure/virtual-machines/managed-disks-overview#data-disk) -296 | Monitoring and Alerting | Low | Virtual Network should have diagnostic settings enabled | [Learn](https://learn.microsoft.com/en-us/azure/virtual-network/monitor-virtual-network#collection-and-routing) -297 | High Availability | High | Virtual Network should have availability zones enabled | [Learn](https://learn.microsoft.com/en-us/azure/virtual-network/virtual-networks-overview#virtual-networks-and-availability-zones) -298 | Governance | Low | Virtual Network Name should comply with naming conventions | [Learn](https://learn.microsoft.com/en-us/azure/cloud-adoption-framework/ready/azure-best-practices/resource-abbreviations) -299 | Governance | Low | Virtual Network should have tags | [Learn](https://learn.microsoft.com/en-us/azure/azure-resource-manager/management/tag-resources?tabs=json) -300 | Security | High | Virtual Network: All Subnets should have a Network Security Group associated | [Learn](https://learn.microsoft.com/azure/virtual-network/concepts-and-best-practices) -301 | High Availability | High | Virtual Network should have at least two DNS servers assigned | [Learn](https://learn.microsoft.com/en-us/azure/virtual-network/virtual-networks-name-resolution-for-vms-and-role-instances?tabs=redhat#specify-dns-servers) -302 | Monitoring and Alerting | Low | Web Pub Sub should have diagnostic settings enabled | [Learn](https://learn.microsoft.com/en-us/azure/azure-web-pubsub/howto-troubleshoot-resource-logs) -303 | High Availability | High | Web Pub Sub should have availability zones enabled | [Learn](https://learn.microsoft.com/en-us/azure/azure-web-pubsub/concept-availability-zones) -304 | High Availability | High | Web Pub Sub should have a SLA | [Learn](https://azure.microsoft.com/en-gb/support/legal/sla/web-pubsub/) -305 | Security | High | Web Pub Sub should have private endpoints enabled | [Learn](https://learn.microsoft.com/en-us/azure/azure-web-pubsub/howto-secure-private-endpoints) -306 | High Availability | High | Web Pub Sub SKU | [Learn](https://azure.microsoft.com/en-us/pricing/details/web-pubsub/) -307 | Governance | Low | Web Pub Sub Name should comply with naming conventions | [Learn](https://learn.microsoft.com/en-us/azure/cloud-adoption-framework/ready/azure-best-practices/resource-abbreviations) -308 | Governance | Low | Web Pub Sub should have tags | [Learn](https://learn.microsoft.com/en-us/azure/azure-resource-manager/management/tag-resources?tabs=json) -309 | Monitoring and Alerting | Low | Azure Synapse Workspace should have diagnostic settings enabled | [Learn](https://learn.microsoft.com/en-us/azure/synapse-analytics/monitor-synapse-analytics) -310 | Security | High | Azure Synapse Workspace should have private endpoints enabled | [Learn](https://learn.microsoft.com/en-us/azure/synapse-analytics/security/synapse-workspace-managed-private-endpoints) -311 | High Availability | High | Azure Synapse Workspace SLA | [Learn](https://www.microsoft.com/licensing/docs/view/Service-Level-Agreements-SLA-for-Online-Services) -312 | Governance | Low | Azure Synapse Workspace Name should comply with naming conventions | [Learn](https://learn.microsoft.com/en-us/azure/cloud-adoption-framework/ready/azure-best-practices/resource-abbreviations) -313 | Governance | Low | Azure Synapse Workspace should have tags | [Learn](https://learn.microsoft.com/en-us/azure/azure-resource-manager/management/tag-resources?tabs=json) -312 | Security | High | Azure Synapse Workspace should establish network segmentation boundaries | [Learn](https://learn.microsoft.com/en-us/security/benchmark/azure/baselines/azure-synapse-analytics-security-baseline?toc=%2Fazure%2Fsynapse-analytics%2Ftoc.json) -313 | Security | High | Azure Synapse Workspace should disable public network access | [Learn](https://learn.microsoft.com/en-us/security/benchmark/azure/baselines/azure-synapse-analytics-security-baseline?toc=%2Fazure%2Fsynapse-analytics%2Ftoc.json) -314 | High Availability | High | Azure Synapse Spark Pool SLA | [Learn](https://www.microsoft.com/licensing/docs/view/Service-Level-Agreements-SLA-for-Online-Services) -315 | Governance | Low | Azure Synapse Spark Pool Name should comply with naming conventions | [Learn](https://learn.microsoft.com/en-us/azure/cloud-adoption-framework/ready/azure-best-practices/resource-abbreviations) -316 | Governance | Low | Azure Synapse Spark Pool should have tags | [Learn](https://learn.microsoft.com/en-us/azure/azure-resource-manager/management/tag-resources?tabs=json) -317 | High Availability | High | Azure Synapse Dedicated SQL Pool SLA | [Learn](https://www.microsoft.com/licensing/docs/view/Service-Level-Agreements-SLA-for-Online-Services) -318 | Governance | Low | Azure Synapse Dedicated SQL Pool Name should comply with naming conventions | [Learn](https://learn.microsoft.com/en-us/azure/cloud-adoption-framework/ready/azure-best-practices/resource-abbreviations) -319 | Governance | Low | Azure Synapse Dedicated SQL Pool should have tags | [Learn](https://learn.microsoft.com/en-us/azure/azure-resource-manager/management/tag-resources?tabs=json) \ No newline at end of file +265 | High Availability | High | SQL Database should have availability zones enabled | [Learn]() +266 | High Availability | High | SQL Database should have a SLA | [Learn]() +267 | High Availability | High | SQL Database SKU | [Learn](https://docs.microsoft.com/en-us/azure/azure-sql/database/service-tiers-vcore?tabs=azure-portal) +268 | Governance | Low | SQL Database Name should comply with naming conventions | [Learn](https://learn.microsoft.com/en-us/azure/cloud-adoption-framework/ready/azure-best-practices/resource-abbreviations) +269 | Governance | Low | SQL Database should have tags | [Learn](https://learn.microsoft.com/en-us/azure/azure-resource-manager/management/tag-resources?tabs=json) +270 | Governance | Low | Azure Synapse Dedicated SQL Pool Name should comply with naming conventions | [Learn](https://learn.microsoft.com/en-us/azure/cloud-adoption-framework/ready/azure-best-practices/resource-abbreviations) +271 | High Availability | High | Azure Synapse Dedicated SQL Pool SLA | [Learn](https://www.microsoft.com/licensing/docs/view/Service-Level-Agreements-SLA-for-Online-Services) +272 | Governance | Low | Azure Synapse Dedicated SQL Pool should have tags | [Learn](https://learn.microsoft.com/en-us/azure/azure-resource-manager/management/tag-resources?tabs=json) +273 | Governance | Low | Azure Synapse Spark Pool Name should comply with naming conventions | [Learn](https://learn.microsoft.com/en-us/azure/cloud-adoption-framework/ready/azure-best-practices/resource-abbreviations) +274 | High Availability | High | Azure Synapse Spark Pool SLA | [Learn](https://www.microsoft.com/licensing/docs/view/Service-Level-Agreements-SLA-for-Online-Services) +275 | Governance | Low | Azure Synapse Spark Pool should have tags | [Learn](https://learn.microsoft.com/en-us/azure/azure-resource-manager/management/tag-resources?tabs=json) +276 | Monitoring and Alerting | Low | Azure Synapse Workspace should have diagnostic settings enabled | [Learn](https://learn.microsoft.com/en-us/azure/data-factory/monitor-configure-diagnostics) +277 | Security | High | Azure Synapse Workspace should have private endpoints enabled | [Learn](https://learn.microsoft.com/en-us/azure/synapse-analytics/security/synapse-workspace-managed-private-endpoints) +278 | High Availability | High | Azure Synapse Workspace SLA | [Learn](https://www.microsoft.com/licensing/docs/view/Service-Level-Agreements-SLA-for-Online-Services) +279 | Governance | Low | Azure Synapse Workspace Name should comply with naming conventions | [Learn](https://learn.microsoft.com/en-us/azure/cloud-adoption-framework/ready/azure-best-practices/resource-abbreviations) +280 | Governance | Low | Azure Synapse Workspace should have tags | [Learn](https://learn.microsoft.com/en-us/azure/azure-resource-manager/management/tag-resources?tabs=json) +281 | Security | High | Azure Synapse Workspace should establish network segmentation boundaries | [Learn](https://learn.microsoft.com/en-us/security/benchmark/azure/baselines/azure-synapse-analytics-security-baseline?toc=%2Fazure%2Fsynapse-analytics%2Ftoc.json) +282 | Security | High | Azure Synapse Workspace should disable public network access | [Learn](https://learn.microsoft.com/en-us/security/benchmark/azure/baselines/azure-synapse-analytics-security-baseline?toc=%2Fazure%2Fsynapse-analytics%2Ftoc.json) +283 | Monitoring and Alerting | Low | Traffic Manager should have diagnostic settings enabled | [Learn](https://learn.microsoft.com/en-us/azure/traffic-manager/traffic-manager-diagnostic-logs) +284 | High Availability | High | Traffic Manager should have availability zones enabled | [Learn](https://learn.microsoft.com/en-us/azure/architecture/high-availability/reference-architecture-traffic-manager-application-gateway) +285 | High Availability | High | Traffic Manager should have a SLA | [Learn](https://www.azure.cn/en-us/support/sla/traffic-manager/) +286 | Governance | Low | Traffic Manager Name should comply with naming conventions | [Learn](https://learn.microsoft.com/en-us/azure/cloud-adoption-framework/ready/azure-best-practices/resource-abbreviations) +287 | Governance | Low | Traffic Manager should have tags | [Learn](https://learn.microsoft.com/en-us/azure/azure-resource-manager/management/tag-resources?tabs=json) +288 | High Availability | High | Traffic Manager should use at least 2 endpoints | [Learn](https://learn.microsoft.com/en-us/azure/traffic-manager/traffic-manager-endpoint-types) +289 | Security | High | Traffic Manager: HTTP endpoints should be monitored using HTTPS | [Learn](https://learn.microsoft.com/en-us/azure/traffic-manager/traffic-manager-monitoring) +290 | Monitoring and Alerting | Low | Storage should have diagnostic settings enabled | [Learn](https://learn.microsoft.com/en-us/azure/storage/blobs/monitor-blob-storage) +291 | High Availability | High | Storage should have availability zones enabled | [Learn](https://learn.microsoft.com/EN-US/azure/reliability/migrate-storage) +292 | High Availability | High | Storage should have a SLA | [Learn](https://www.azure.cn/en-us/support/sla/storage/) +293 | Security | High | Storage should have private endpoints enabled | [Learn](https://learn.microsoft.com/en-us/azure/storage/common/storage-private-endpoints) +294 | High Availability | High | Storage SKU | [Learn](https://learn.microsoft.com/en-us/rest/api/storagerp/srp_sku_types) +295 | Governance | Low | Storage Name should comply with naming conventions | [Learn](https://learn.microsoft.com/en-us/azure/cloud-adoption-framework/ready/azure-best-practices/resource-abbreviations) +296 | Security | High | Storage Account should use HTTPS only | [Learn](https://learn.microsoft.com/en-us/azure/storage/common/storage-require-secure-transfer) +297 | Governance | Low | Storage Account should have tags | [Learn](https://learn.microsoft.com/en-us/azure/azure-resource-manager/management/tag-resources?tabs=json) +298 | Security | Low | Storage Account should enforce TLS >= 1.2 | [Learn](https://learn.microsoft.com/en-us/azure/storage/common/transport-layer-security-configure-minimum-version?tabs=portal) +299 | Disaster Recovery | Low | Storage Account should have inmutable storage versioning enabled | [Learn](https://learn.microsoft.com/en-us/azure/well-architected/service-guides/storage-accounts/reliability) +300 | Disaster Recovery | Medium | Storage Account should have soft delete enabled | [Learn](https://learn.microsoft.com/en-us/azure/well-architected/service-guides/storage-accounts/reliability) +301 | Monitoring and Alerting | Low | Virtual Machine should have diagnostic settings enabled | [Learn](https://learn.microsoft.com/en-us/azure/azure-monitor/agents/diagnostics-extension-windows-install) +302 | High Availability | High | Virtual Machine should have availability zones enabled | [Learn](https://learn.microsoft.com/en-us/azure/virtual-machines/availability#availability-zones) +303 | High Availability | High | Virtual Machine should have a SLA | [Learn](https://www.microsoft.com/licensing/docs/view/Service-Level-Agreements-SLA-for-Online-Services?lang=1) +304 | Governance | Low | Virtual Machine Name should comply with naming conventions | [Learn](https://learn.microsoft.com/en-us/azure/cloud-adoption-framework/ready/azure-best-practices/resource-abbreviations) +305 | Governance | Low | Virtual Machine should have tags | [Learn](https://learn.microsoft.com/en-us/azure/azure-resource-manager/management/tag-resources?tabs=json) +306 | High Availability | High | Virtual Machine should use managed disks | [Learn](https://learn.microsoft.com/en-us/azure/architecture/checklist/resiliency-per-service#virtual-machines) +307 | Scalability | Low | Virtual Machine should host application or database data on a data disk | [Learn](https://learn.microsoft.com/azure/virtual-machines/managed-disks-overview#data-disk) +308 | Monitoring and Alerting | Low | Virtual Network should have diagnostic settings enabled | [Learn](https://learn.microsoft.com/en-us/azure/virtual-network/monitor-virtual-network#collection-and-routing) +309 | High Availability | High | Virtual Network should have availability zones enabled | [Learn](https://learn.microsoft.com/en-us/azure/virtual-network/virtual-networks-overview#virtual-networks-and-availability-zones) +310 | Governance | Low | Virtual Network Name should comply with naming conventions | [Learn](https://learn.microsoft.com/en-us/azure/cloud-adoption-framework/ready/azure-best-practices/resource-abbreviations) +311 | Governance | Low | Virtual Network should have tags | [Learn](https://learn.microsoft.com/en-us/azure/azure-resource-manager/management/tag-resources?tabs=json) +312 | Security | High | Virtual Network: All Subnets should have a Network Security Group associated | [Learn](https://learn.microsoft.com/azure/virtual-network/concepts-and-best-practices) +313 | High Availability | High | Virtual Network should have at least two DNS servers assigned | [Learn](https://learn.microsoft.com/en-us/azure/virtual-network/virtual-networks-name-resolution-for-vms-and-role-instances?tabs=redhat#specify-dns-servers) +314 | Monitoring and Alerting | Low | Web Pub Sub should have diagnostic settings enabled | [Learn](https://learn.microsoft.com/en-us/azure/azure-web-pubsub/howto-troubleshoot-resource-logs) +315 | High Availability | High | Web Pub Sub should have availability zones enabled | [Learn](https://learn.microsoft.com/en-us/azure/azure-web-pubsub/concept-availability-zones) +316 | High Availability | High | Web Pub Sub should have a SLA | [Learn](https://azure.microsoft.com/en-gb/support/legal/sla/web-pubsub/) +317 | Security | High | Web Pub Sub should have private endpoints enabled | [Learn](https://learn.microsoft.com/en-us/azure/azure-web-pubsub/howto-secure-private-endpoints) +318 | High Availability | High | Web Pub Sub SKU | [Learn](https://azure.microsoft.com/en-us/pricing/details/web-pubsub/) +319 | Governance | Low | Web Pub Sub Name should comply with naming conventions | [Learn](https://learn.microsoft.com/en-us/azure/cloud-adoption-framework/ready/azure-best-practices/resource-abbreviations) +320 | Governance | Low | Web Pub Sub should have tags | [Learn](https://learn.microsoft.com/en-us/azure/azure-resource-manager/management/tag-resources?tabs=json) diff --git a/internal/scanners/aks/rules.go b/internal/scanners/aks/rules.go index 2601bd2a..45bb9036 100644 --- a/internal/scanners/aks/rules.go +++ b/internal/scanners/aks/rules.go @@ -151,7 +151,7 @@ func (a *AKSScanner) GetRules() map[string]scanners.AzureRule { } return true, "" }, - Url: "https://learn.microsoft.com/azure/aks/managed-aad#disable-local-accounts", + Url: "https://learn.microsoft.com/en-us/azure/aks/manage-local-accounts-managed-azure-ad#disable-local-accounts", }, "aks-010": { Id: "aks-010", diff --git a/internal/scanners/appcs/rules.go b/internal/scanners/appcs/rules.go index d327548d..378c3f93 100644 --- a/internal/scanners/appcs/rules.go +++ b/internal/scanners/appcs/rules.go @@ -32,9 +32,9 @@ func (a *AppConfigurationScanner) GetRules() map[string]scanners.AzureRule { Impact: scanners.ImpactHigh, Eval: func(target interface{}, scanContext *scanners.ScanContext) (bool, string) { a := target.(*armappconfiguration.ConfigurationStore) - sku := *a.SKU.Name + sku := strings.ToLower(*a.SKU.Name) sla := "None" - if sku == "Standard" { + if sku == "standard" { sla = "99.9%" } diff --git a/internal/scanners/appcs/rules_test.go b/internal/scanners/appcs/rules_test.go index 35f1147e..9f1eaff4 100644 --- a/internal/scanners/appcs/rules_test.go +++ b/internal/scanners/appcs/rules_test.go @@ -51,7 +51,7 @@ func TestAppConfigurationScanner_Rules(t *testing.T) { rule: "appcs-003", target: &armappconfiguration.ConfigurationStore{ SKU: &armappconfiguration.SKU{ - Name: to.Ptr("Free"), + Name: to.Ptr("free"), }, }, scanContext: &scanners.ScanContext{}, diff --git a/internal/scanners/sql/rules.go b/internal/scanners/sql/rules.go index ad51c612..1cd9605c 100644 --- a/internal/scanners/sql/rules.go +++ b/internal/scanners/sql/rules.go @@ -82,17 +82,6 @@ func (a *SQLScanner) getServerRules() map[string]scanners.AzureRule { func (a *SQLScanner) getDatabaseRules() map[string]scanners.AzureRule { return map[string]scanners.AzureRule{ - "sqldb-001": { - Id: "sqldb-001", - Category: scanners.RulesCategoryMonitoringAndAlerting, - Recommendation: "SQL Database should have diagnostic settings enabled", - Impact: scanners.ImpactLow, - Eval: func(target interface{}, scanContext *scanners.ScanContext) (bool, string) { - service := target.(*armsql.Database) - _, ok := scanContext.DiagnosticsSettings[strings.ToLower(*service.ID)] - return !ok, "" - }, - }, "sqldb-002": { Id: "sqldb-002", Category: scanners.RulesCategoryHighAvailability, diff --git a/internal/scanners/sql/rules_test.go b/internal/scanners/sql/rules_test.go index 30f7d75e..67e27182 100644 --- a/internal/scanners/sql/rules_test.go +++ b/internal/scanners/sql/rules_test.go @@ -127,24 +127,6 @@ func TestSQLScanner_DatabaseRules(t *testing.T) { fields fields want want }{ - { - name: "SQLScanner DiagnosticSettings", - fields: fields{ - rule: "sqldb-001", - target: &armsql.Database{ - ID: to.Ptr("test"), - }, - scanContext: &scanners.ScanContext{ - DiagnosticsSettings: map[string]bool{ - "test": true, - }, - }, - }, - want: want{ - broken: false, - result: "", - }, - }, { name: "SQLScanner Availability Zones", fields: fields{