public static class AuthorizeSecurityGroupRequest.AuthorizeSecurityGroupRequestPermissions
extends com.aliyun.tea.TeaModel
限定符和类型 | 字段和说明 |
---|---|
String |
description
The description of the security group rule.
|
String |
destCidrIp
The destination IPv4 CIDR block.
|
String |
ipProtocol
The transport layer protocol.
|
String |
ipv6DestCidrIp
The destination IPv6 CIDR block.
|
String |
ipv6SourceCidrIp
The source IPv6 CIDR block for the security group rule.
|
String |
nicType
The network interface controller (NIC) type of the security group rule when the security group is in the classic network.
|
String |
policy
The authorization policy.
|
String |
portRange
The range of destination ports that correspond to the transport layer protocol for the security group rule.
|
String |
priority
The priority of the security group rule.
|
String |
sourceCidrIp
The source IPv4 CIDR block for the security group rule.
|
String |
sourceGroupId
The ID of the source security group.
|
String |
sourceGroupOwnerAccount
The Alibaba Cloud account that manages the source security group when you set a security group rule across accounts.
|
Long |
sourceGroupOwnerId
The ID of the Alibaba Cloud account that manages the source security group when you set a security group rule across accounts.
|
String |
sourcePortRange
The range of source ports that correspond to the transport layer protocol for the security group rule.
|
String |
sourcePrefixListId
The ID of the source prefix list.
|
构造器和说明 |
---|
AuthorizeSecurityGroupRequestPermissions() |
@NameInMap(value="Description") public String description
The description of the security group rule. The description must be 1 to 512 characters in length.
Valid values of N: 1 to 100.
@NameInMap(value="DestCidrIp") public String destCidrIp
The destination IPv4 CIDR block. CIDR blocks and IPv4 addresses are supported.
This parameter is specified to meet quintuple rules. For more information, see [Security group quintuple rules](~~97439~~).
Valid values of N: 1 to 100.
@NameInMap(value="IpProtocol") public String ipProtocol
The transport layer protocol. The value of this parameter is case-insensitive. Valid values:
* TCP
* UDP
* ICMP
* ICMPv6
* GRE
* ALL: All protocols are supported.
Valid values of N: 1 to 100.
@NameInMap(value="Ipv6DestCidrIp") public String ipv6DestCidrIp
The destination IPv6 CIDR block. CIDR blocks and IPv6 addresses are supported.
This parameter is specified to meet quintuple rules. For more information, see [Security group quintuple rules](~~97439~~).
Valid values of N: 1 to 100.
> The Permissions.N.Ipv6DestCidrIp parameter is valid only when the destination is ECS instances that reside in virtual private clouds (VPCs) and support IPv6 CIDR blocks. You cannot specify this parameter and the `DestCidrIp` parameter at the same time.
@NameInMap(value="Ipv6SourceCidrIp") public String ipv6SourceCidrIp
The source IPv6 CIDR block for the security group rule. CIDR blocks and IPv6 addresses are supported.
Valid values of N: 1 to 100.
> The Permissions.N.Ipv6SourceCidrIp parameter is valid only when the source is ECS instances that reside in VPCs and support IPv6 CIDR blocks. You cannot specify this parameter and the `SourceCidrIp` parameter at the same time.
@NameInMap(value="NicType") public String nicType
The network interface controller (NIC) type of the security group rule when the security group is in the classic network. Valid values:
* internet: public NIC
* intranet: internal NIC
If the security group is in a VPC, this parameter is set to intranet by default and cannot be changed.
If you specify only DestGroupId when you configure access between security groups, this parameter must be set to intranet.
Default value: internet.
Valid values of N: 1 to 100.
@NameInMap(value="Policy") public String policy
The authorization policy. Valid values:
* accept: allows access.
* drop: denies access and returns no responses. In this case, the request times out or the connection cannot be established.
Default value: accept.
Valid values of N: 1 to 100.
@NameInMap(value="PortRange") public String portRange
The range of destination ports that correspond to the transport layer protocol for the security group rule. Valid values:
* When the Permissions.N.IpProtocol parameter is set to TCP or UDP, the port number range is 1 to 65535. Separate the start port number and the end port number with a forward slash (/). Example: 1/200.
* When the Permissions.N.IpProtocol parameter is set to ICMP, the port number range is -1/-1, which indicates all ports.
* When the Permissions.N.IpProtocol parameter is set to GRE, the port number range is -1/-1, which indicates all ports.
* When the Permissions.N.IpProtocol parameter is set to ALL, the port number range is -1/-1, which indicates all ports.
For more information, see [Typical applications of commonly used ports](~~40724~~).
Valid values of N: 1 to 100.
@NameInMap(value="Priority") public String priority
The priority of the security group rule. A smaller value indicates a higher priority. Valid values: 1 to 100.
Default value: 1
Valid values of N: 1 to 100.
@NameInMap(value="SourceCidrIp") public String sourceCidrIp
The source IPv4 CIDR block for the security group rule. CIDR blocks and IPv4 addresses are supported.
Valid values of N: 1 to 100.
@NameInMap(value="SourceGroupId") public String sourceGroupId
The ID of the source security group.
* At least one of `SourceGroupId`, `SourceCidrIp`, `Ipv6SourceCidrIp`, and `SourcePrefixListId` must be specified.
* If `SourceGroupId` is specified but `SourceCidrIp` or `Ipv6SourceCidrIp` is not specified, `NicType` must be set to `intranet`.
* If both `SourceGroupId` and `SourceCidrIp` are specified, `SourceCidrIp` takes precedence.
Valid values of N: 1 to 100.
When you call this operation, take note of the following items:
* For advanced security groups, security groups cannot be used as authorization objects.
* For each basic security group, a maximum of 20 security groups can be used as authorization objects.
@NameInMap(value="SourceGroupOwnerAccount") public String sourceGroupOwnerAccount
The Alibaba Cloud account that manages the source security group when you set a security group rule across accounts.
* If both `SourceGroupOwnerAccount` and `SourceGroupOwnerId` are not specified, access permissions are configured for another security group managed by your account.
* If `SourceCidrIp` is specified, the `SourceGroupOwnerAccount` parameter is invalid.
Valid values of N: 1 to 100.
@NameInMap(value="SourceGroupOwnerId") public Long sourceGroupOwnerId
The ID of the Alibaba Cloud account that manages the source security group when you set a security group rule across accounts.
* If both `SourceGroupOwnerAccount` and `SourceGroupOwnerId` are not specified, access permissions are configured for another security group managed by your account.
* If `SourceCidrIp` is specified, the `SourceGroupOwnerAccount` parameter is invalid.
Valid values of N: 1 to 100.
@NameInMap(value="SourcePortRange") public String sourcePortRange
The range of source ports that correspond to the transport layer protocol for the security group rule. Valid values:
* When the Permissions.N.IpProtocol parameter is set to TCP or UDP, the port number range is 1 to 65535. Separate the start port number and the end port number with a forward slash (/). Example: 1/200.
* When the Permissions.N.IpProtocol parameter is set to ICMP, the port number range is -1/-1, which indicates all ports.
* When the Permissions.N.IpProtocol parameter is set to GRE, the port number range is -1/-1, which indicates all ports.
* When the Permissions.N.IpProtocol parameter is set to ALL, the port number range is -1/-1, which indicates all ports.
This parameter is specified to meet quintuple rules. For more information, see [Security group quintuple rules](~~97439~~).
Valid values of N: 1 to 100.
@NameInMap(value="SourcePrefixListId") public String sourcePrefixListId
The ID of the source prefix list. You can call the [DescribePrefixLists](~~205046~~) operation to query the IDs of available prefix lists.
Valid values of N: 1 to 100.
Note:
* If a security group is in the classic network, you cannot configure prefix lists in the security group rules. For information about the limits on security groups and prefix lists, see the "Security group limits" section in [Limits](~~25412#SecurityGroupQuota1~~).
* If you specify the `SourceCidrIp`, `Ipv6SourceCidrIp`, or `SourceGroupId` parameter, this parameter is ignored.
public static AuthorizeSecurityGroupRequest.AuthorizeSecurityGroupRequestPermissions build(Map<String,?> map) throws Exception
Exception
public AuthorizeSecurityGroupRequest.AuthorizeSecurityGroupRequestPermissions setDescription(String description)
public String getDescription()
public AuthorizeSecurityGroupRequest.AuthorizeSecurityGroupRequestPermissions setDestCidrIp(String destCidrIp)
public String getDestCidrIp()
public AuthorizeSecurityGroupRequest.AuthorizeSecurityGroupRequestPermissions setIpProtocol(String ipProtocol)
public String getIpProtocol()
public AuthorizeSecurityGroupRequest.AuthorizeSecurityGroupRequestPermissions setIpv6DestCidrIp(String ipv6DestCidrIp)
public String getIpv6DestCidrIp()
public AuthorizeSecurityGroupRequest.AuthorizeSecurityGroupRequestPermissions setIpv6SourceCidrIp(String ipv6SourceCidrIp)
public String getIpv6SourceCidrIp()
public AuthorizeSecurityGroupRequest.AuthorizeSecurityGroupRequestPermissions setNicType(String nicType)
public String getNicType()
public AuthorizeSecurityGroupRequest.AuthorizeSecurityGroupRequestPermissions setPolicy(String policy)
public String getPolicy()
public AuthorizeSecurityGroupRequest.AuthorizeSecurityGroupRequestPermissions setPortRange(String portRange)
public String getPortRange()
public AuthorizeSecurityGroupRequest.AuthorizeSecurityGroupRequestPermissions setPriority(String priority)
public String getPriority()
public AuthorizeSecurityGroupRequest.AuthorizeSecurityGroupRequestPermissions setSourceCidrIp(String sourceCidrIp)
public String getSourceCidrIp()
public AuthorizeSecurityGroupRequest.AuthorizeSecurityGroupRequestPermissions setSourceGroupId(String sourceGroupId)
public String getSourceGroupId()
public AuthorizeSecurityGroupRequest.AuthorizeSecurityGroupRequestPermissions setSourceGroupOwnerAccount(String sourceGroupOwnerAccount)
public String getSourceGroupOwnerAccount()
public AuthorizeSecurityGroupRequest.AuthorizeSecurityGroupRequestPermissions setSourceGroupOwnerId(Long sourceGroupOwnerId)
public Long getSourceGroupOwnerId()
public AuthorizeSecurityGroupRequest.AuthorizeSecurityGroupRequestPermissions setSourcePortRange(String sourcePortRange)
public String getSourcePortRange()
public AuthorizeSecurityGroupRequest.AuthorizeSecurityGroupRequestPermissions setSourcePrefixListId(String sourcePrefixListId)
public String getSourcePrefixListId()
Copyright © 2023. All rights reserved.