๐ก๏ธ Azure Network Security Group Flow Logs retention period is less than 90 days๐ข
- Contextual name: ๐ก๏ธ Security Group Flow Logs retention period is less than 90 days๐ข
- ID:
/ce/ca/azure/virtual-network/security-group-flow-logs-retention-period-over-90-days - Tags:
- ๐ข Policy with categories
- ๐ข Policy with type
- ๐ข Production policy
- Policy Type:
COMPLIANCE_POLICY - Policy Categories:
SECURITY
Logicโ
- ๐ง prod.logic.yaml๐ข
Similar Policiesโ
- Cloud Conformity: Check for NSG Flow Log Retention Period
- Internal:
dec-x-e5c05d3e
Similar Internal Rulesโ
| Rule | Policies | Flags |
|---|---|---|
| โ๏ธ dec-x-e5c05d3e | 1 |
Descriptionโ
Descriptionโ
Network Security Group Flow Logs should be enabled and the retention period set to greater than or equal to 90 days.
Retirement Notice On September 30, 2027, network security group (NSG) flow logs will be retired. Starting June 30, 2025, it will no longer be possible to create new NSG flow logs. Azure recommends migrating to virtual network flow logs. Review https://azure.microsoft.com/en-gb/updates?id=Azure-NSG-flow-logs-Retirement for more information. For virtual network flow logs, consider applying the recommendation
Ensure that virtual network flow log retention days is set to greater than or equal to 90in this section.Rationaleโ
Flow logs enable capturing information about IP traffic flowing in and out of network security groups. Logs can be used to check for anomalies and give insight into suspected breaches.
Impactโ
This will keep IP traffic logs for longer than 90 days. As a level 2, first determine your need to retain data, then apply your selection here. As this is data stored for longer, your monthly storage costs will increase depending on your data use.
... see more
Remediationโ
Remediationโ
From Azure Portalโ
- Go to
Network Watcher.- Select
NSG flow logsblade in the Logs section.- Select each Network Security Group from the list.
- Ensure
Statusis set toOn.- Ensure
Retention (days)settinggreater than 90 days.- Select your storage account in the
Storage accountfield.- Select
Save.From Azure CLIโ
Enable the
NSG flow logsand set theRetention (days)togreater than or equal to 90 days:az network watcher flow-log configure --nsg <NameorID of the Network Security Group> --enabled true --resource-group <resourceGroupName> --retention 91 --storage-account <NameorID of the storage account to save flow logs>