AWS EC2 Authorize Security Group Ingress VERSION 1


This handler uses the AWS REST API to Add a security group ingress rule to a security group. This handler implements a subset of the full AWS call (single rule submission only). Most of the inputs for this handler are conditionally required based on other input values. Source Security Group Name is required if a CIDR IP Address Name isn't specified and vice versa. Also, if a Source Security Group Name and/or Source Security Group Owner ID are provided, the IP Protocol, From Port, To Port, and CIDR IP Address Range must be left blank. This handler returns no results, so if no errors are caught and raised the rule has been successfully applied.

More specific information about these parameters can be found in the Amazon EC2 Ruby documentation (http://docs.aws.amazon.com/sdkforruby/api/Aws/EC2/Client.html#authorizesecuritygroupingress-instancemethod) and in the EC2 REST documentation (http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-security-group-ingress.html).

The Dry Run parameter validates user permissions and inputs. If it is set to true, an error will always be thrown by the handler before completing the handler action. Error response will be 'DryRunOperation' if the account has proper permissions and inputs; 'UnauthorizedOperation' if the account does not have proper permissions.


Parameters

NameDescription
Dry RunDry run validates user permissions and inputs without completing the EC2 action (true or false).
Group NameThe name of the security group. Normally used for the EC2-Classic or the default VPC security group.
Group IDThe ID of the security group. Required for a non-default VPC.
Source Security Group NameThe name of the source security group. For EC2-VPC, the source security group must be in the same VPC.
Source Security Group Owner IDTThe AWS account number for the source security group. For EC2-VPC, the source security group must be in the same VPC. Creates rules that grant full ICMP, UDP, and TCP access. To create a rule with a specific IP protocol and port range, use a set of IP permissions instead.
IP ProtocolThe IP protocol name (tcp, udp, icmp). (VPC only) Use -1 to specify all. You can't specify this parameter when specifying a source security group.
From PortThe start of port range for the TCP and UDP protocols, or an ICMP type number. For the ICMP type number, use -1 to specify all ICMP types. You can't specify this parameter when specifying a source security group.
To PortThe end of port range for the TCP and UDP protocols, or an ICMP code number. For the ICMP code number, use -1 to specify all ICMP codes for the ICMP type. You can't specify this parameter when specifying a source security group.
CIDR IP Address RangeThe CIDR IP address range. You can't specify this parameter when specifying a source security group.

Sample Configuration

NameDescription
Dry Runfalse
Group NameDevGroup
Group IDsg-94a22af0
Source Security Group Name
Source Security Group Owner ID
IP Protocoltcp
From Port22
To Port23
CIDR IP Address Range0.0.0.0/0

Results

This handler does not return any results.


Changelog

No Changelog Available.