Creates a new security group. Group names must be unique per account.
Every instance is launched in a security group. If no security group is specified during
launch, the instances are launched in the default security group. Instances within the same
security group have unrestricted network access to each other. Instances will reject network
access attempts from other instances in a different security group. As the owner of instances
you can grant or revoke specific permissions using the AuthorizeSecurityGroupIngress and RevokeSecurityGroupIngress operations.
| Name | Description | Required |
|---|---|---|
|
|
Name of the security group. Type: String Default: None Constraints: Accepts alphanumeric characters, spaces, dashes, and underscores. |
Yes |
|
|
Description of the group. This is informational only. If the description contains spaces, you must enclose it in single quotes (') or URL-encode it. Type: String Default: None Constraints: Accepts alphanumeric characters, spaces, dashes, and underscores. |
Yes |
| Name | Description |
|---|---|
|
|
Type: CreateSecurityGroupResponseType Ancestor: None Children: |
|
|
The ID of the request. Type: xsd:string Ancestor: Children: None |
|
|
Returns true if creation succeeded. Otherwise, returns an error. Type: xsd:boolean Ancestor: Children: None |
This example creates the websrv security group.
https://ec2.amazonaws.com/?Action=CreateSecurityGroup&GroupName=websrv&GroupDescription='Web Servers'&AuthParams
<CreateSecurityGroupResponse xmlns="http://ec2.amazonaws.com/doc/2009-11-30/"> <return>true</return> </CreateSecurityGroupResponse>