How to list network security groups in AZURE Resource Group

The Azure CLI is used to create and manage Azure resources from the command line or in scripts.

Azure network security group contains security rules that allow or deny inbound network traffic to, or outbound network traffic from, several types of Azure resources. For each rule, you can specify source and destination, port, and protocol.

Following Azure CLI command lists network security groups in Azure resource group.

        
    
az network nsg list \
--resource-group "RESOURCE_GROUP_NAME" \
--query '[].name' \
--output tsv

        
    


Follow US on Twitter: