Skip to main content

default_security_rules

Creates, updates, deletes, gets or lists a default_security_rules resource.

Overview

Namedefault_security_rules
TypeResource
Idazure.network.default_security_rules

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
idstringResource ID.
namestringName of the resource.
accessstringThe network traffic is allowed or denied. Required. Known values are: "Allow" and "Deny". (Allow, Deny)
descriptionstringA description for this rule. Restricted to 140 chars.
destinationAddressPrefixstringThe destination address prefix. CIDR or destination IP range. Asterisk '*' can also be used to match all source IPs. Default tags such as 'VirtualNetwork', 'AzureLoadBalancer' and 'Internet' can also be used.
destinationAddressPrefixesarrayThe destination address prefixes. CIDR or destination IP ranges.
destinationApplicationSecurityGroupsarrayThe application security group specified as destination.
destinationPortRangestringThe destination port or range. Integer or range between 0 and 65535. Asterisk '*' can also be used to match all ports.
destinationPortRangesarrayThe destination port ranges.
directionstringThe direction of the rule. The direction specifies if rule will be evaluated on incoming or outgoing traffic. Required. Known values are: "Inbound" and "Outbound". (Inbound, Outbound)
etagstringA unique read-only string that changes whenever the resource is updated.
priorityintegerThe priority of the rule. The value can be between 100 and 4096. The priority number must be unique for each rule in the collection. The lower the priority number, the higher the priority of the rule. Required.
protocolstringNetwork protocol this rule applies to. Required. Known values are: "Tcp", "Udp", "Icmp", "Esp", "*", and "Ah". (Tcp, Udp, Icmp, Esp, *, Ah)
provisioningStatestringThe provisioning state of the security rule resource. Known values are: "Failed", "Succeeded", "Canceled", "Creating", "Updating", and "Deleting". (Failed, Succeeded, Canceled, Creating, Updating, Deleting)
sourceAddressPrefixstringThe CIDR or source IP range. Asterisk '*' can also be used to match all source IPs. Default tags such as 'VirtualNetwork', 'AzureLoadBalancer' and 'Internet' can also be used. If this is an ingress rule, specifies where network traffic originates from.
sourceAddressPrefixesarrayThe CIDR or source IP ranges.
sourceApplicationSecurityGroupsarrayThe application security group specified as source.
sourcePortRangestringThe source port or range. Integer or range between 0 and 65535. Asterisk '*' can also be used to match all ports.
sourcePortRangesarrayThe source port ranges.
typestringResource type.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectresource_group_name, network_security_group_name, default_security_rule_name, subscription_idGet the specified default network security rule.
listselectresource_group_name, network_security_group_name, subscription_idGets all default security rules in a network security group.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
default_security_rule_namestringThe name of the default security rule. Required.
network_security_group_namestringThe name of the network security group. Required.
resource_group_namestringThe name of the resource group. The name is case insensitive. Required.
subscription_idstring

SELECT examples

Get the specified default network security rule.

SELECT
id,
name,
access,
description,
destinationAddressPrefix,
destinationAddressPrefixes,
destinationApplicationSecurityGroups,
destinationPortRange,
destinationPortRanges,
direction,
etag,
priority,
protocol,
provisioningState,
sourceAddressPrefix,
sourceAddressPrefixes,
sourceApplicationSecurityGroups,
sourcePortRange,
sourcePortRanges,
type
FROM azure.network.default_security_rules
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND network_security_group_name = '{{ network_security_group_name }}' -- required
AND default_security_rule_name = '{{ default_security_rule_name }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;