AWS services or capabilities described in AWS Documentation may vary by region/location. Click Getting Started with Amazon AWS to see specific differences applicable to the China (Beijing) Region.
Describes a security group rule.
Namespace: Amazon.EC2.Model
Assembly: AWSSDK.EC2.dll
Version: 3.x.y.z
public class SecurityGroupRule
The SecurityGroupRule type exposes the following members
Name | Description | |
---|---|---|
![]() |
SecurityGroupRule() |
Name | Type | Description | |
---|---|---|---|
![]() |
CidrIpv4 | System.String |
Gets and sets the property CidrIpv4. The IPv4 CIDR range. |
![]() |
CidrIpv6 | System.String |
Gets and sets the property CidrIpv6. The IPv6 CIDR range. |
![]() |
Description | System.String |
Gets and sets the property Description. The security group rule description. |
![]() |
FromPort | System.Int32 |
Gets and sets the property FromPort. If the protocol is TCP or UDP, this is the start of the port range. If the protocol is ICMP or ICMPv6, this is the type number. A value of -1 indicates all ICMP/ICMPv6 types. If you specify all ICMP/ICMPv6 types, you must specify all ICMP/ICMPv6 codes. |
![]() |
GroupId | System.String |
Gets and sets the property GroupId. The ID of the security group. |
![]() |
GroupOwnerId | System.String |
Gets and sets the property GroupOwnerId. The ID of the Amazon Web Services account that owns the security group. |
![]() |
IpProtocol | System.String |
Gets and sets the property IpProtocol.
The IP protocol name (
Use |
![]() |
IsEgress | System.Boolean |
Gets and sets the property IsEgress. Indicates whether the security group rule is an outbound rule. |
![]() |
PrefixListId | System.String |
Gets and sets the property PrefixListId. The ID of the prefix list. |
![]() |
ReferencedGroupInfo | Amazon.EC2.Model.ReferencedSecurityGroup |
Gets and sets the property ReferencedGroupInfo. Describes the security group that is referenced in the rule. |
![]() |
SecurityGroupRuleId | System.String |
Gets and sets the property SecurityGroupRuleId. The ID of the security group rule. |
![]() |
Tags | System.Collections.Generic.List<Amazon.EC2.Model.Tag> |
Gets and sets the property Tags. The tags applied to the security group rule. |
![]() |
ToPort | System.Int32 |
Gets and sets the property ToPort. If the protocol is TCP or UDP, this is the end of the port range. If the protocol is ICMP or ICMPv6, this is the type number. A value of -1 indicates all ICMP/ICMPv6 codes. If you specify all ICMP/ICMPv6 types, you must specify all ICMP/ICMPv6 codes. |
.NET Core App:
Supported in: 3.1
.NET Standard:
Supported in: 2.0
.NET Framework:
Supported in: 4.5, 4.0, 3.5