Clean up unused AWS Network Firewall stateless rule groups by identifying those that contain no rules, deciding which should be deleted, and validating that only intentional exceptions remain. The plan walks through discovering all stateless rule groups across your chosen accounts and regions, guiding you through which empty groups to remove or retain, executing deletions where approved, and finally verifying and documenting the outcome for audit and future reference.
This phase builds a clear inventory of stateless rule groups and highlights those that are empty:
List Network Firewall stateless rule groups and capture rule counts
Enumerate Network Firewall rule groups across all in-scope accounts and regions, then narrow the working set to stateless rule groups only. For each group, capture key attributes such as name, ARN, ID, account, region, capacity, description, type, and any useful tags (for example Environment, Application, Owner, CostCenter). Inspect the rule group definition to determine how many stateless rules or entries it contains, and store all details in a structured dataset for analysis.
Identify stateless rule groups that contain no rules
Analyze the collected inventory to find stateless rule groups with a recorded rule count of zero. Flag these as empty candidates and compile their metadata (name, ARN, ID, account, region, capacity, description, tags) into a consolidated list for decision-making. If no empty groups are found, record that outcome so no cleanup actions are performed unnecessarily.
User: Confirm deletion for each empty stateless rule group
Present the list of empty stateless rule groups, including their metadata and tags, to help you understand their context and potential purpose. For each group, you decide whether it should be deleted or retained as an intentional exception (for example as a placeholder for future rules or due to policy). Your decisions, along with any justifications or notes, are captured in a structured decision record mapping each group to an action: “delete” or “retain as-is (exception).”
This phase applies the decisions you made by deleting only the approved empty stateless rule groups:
This phase confirms the environment now reflects your intended state and documents it for audit: