RevokeSecurityGroupIngress
In this article:
RevokeSecurityGroupIngress#
Description#
Removes one or more inbound rules from a security group.
Request Parameters#
GroupId — The ID of the security group.
Type: String
Required: Yes
IpPermissions.n.Groups.n.UserId — The ID of the account.
Type: String
Required: Yes
Constraints: Can’t be used with IpPermissions.n.IpRanges.n.CidrIp and IpPermissions.n.Ipv6Ranges.n.CidrIpv6
IpPermissions.n.Groups.n.GroupId — The ID of the security group.
Type: String
Required: No
Constraints: Can’t be used with IpPermissions.n.IpRanges.n.CidrIp and IpPermissions.n.Ipv6Ranges.n.CidrIpv6
IpPermissions.n.Groups.n.Description — The description of the security group rule.
Type: String
Required: No
IpPermissions.n.IpRanges.n.CidrIp — The IPv4 address in CIDR notation.
Required: No
Type: String
Required: No
Constraints: Can’t be used with IpPermissions.n.Groups and IpPermissions.n.Ipv6Ranges.n.CidrIpv6
IpPermissions.n.IpRanges.n.Description — The description of the security group rule.
Type: String
Required: No
IpPermissions.n.Ipv6Ranges.n.CidrIpv6 — The IPv6 address in CIDR notation.
Type: String
Required: No
Constraints: Can’t be used with IpPermissions.n.Groups and IpPermissions.n.IpRanges.n.CidrIp
IpPermissions.n.Ipv6Ranges.n.Description — The description of the security group rule.
Type: String
Required: No
Response Elements#
requestId — The request ID
Type: String
return —
True
is returned if the request succeeds, and an error otherwiseType: Boolean
Examples#
c2-ec2 RevokeSecurityGroupIngress GroupId <group_id> IpPermissions.1.IpProtocol 6 IpPermissions.1.FromPort 650 IpPermissions.1.ToPort 650 IpPermissions.1.Ipv6Ranges.1.CidrIpv6 ::/128
c2-ec2 RevokeSecurityGroupIngress GroupId <group_id> IpPermissions.1.IpProtocol udp IpPermissions.1.FromPort 650 IpPermissions.1.ToPort 700 IpPermissions.1.Groups.1.GroupId <group_id_2>