Creates a custom security policy for a TCP/SSL listener.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
nlb:CreateSecurityPolicy |
create |
*SecurityPolicy
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| TlsVersions |
array |
Yes |
The Transport Layer Security (TLS) versions supported by the security policy. Valid values: TLSv1.0, TLSv1.1, TLSv1.2, and TLSv1.3. |
|
|
string |
No |
A TLS version supported by the security policy. Valid values: TLSv1.0, TLSv1.1, TLSv1.2, and TLSv1.3. All four versions can be specified for a security policy. |
TLSv1.0 |
|
| SecurityPolicyName |
string |
No |
The name of the security policy. It must be 1 to 200 characters in length, and can contain letters, digits, periods (.), underscores (_), and hyphens (-). |
TLSCipherPolicy |
| ResourceGroupId |
string |
No |
The ID of the resource group to which the security policy belongs. |
rg-atstuj3rtop**** |
| Ciphers |
array |
Yes |
The cipher suites supported by the security policy. Valid values depend on the TlsVersions parameter. You can specify up to 32 cipher suites. TLSv1.0 and TLSv1.1 support the following cipher suites:
TLSv1.2 supports the following cipher suites:
TLSv1.3 supports the following cipher suites:
|
|
|
string |
No |
The cipher suites supported by the security policy. Valid values depend on the TlsVersions parameter. You can specify up to 32 cipher suites. TLSv1.0 and TLSv1.1 support the following cipher suites:
TLSv1.2 supports the following cipher suites:
TLSv1.3 supports the following cipher suites:
|
ECDHE-ECDSA-AES128-SHA |
|
| DryRun |
boolean |
No |
Whether to perform a dry run. Valid values:
|
false |
| ClientToken |
string |
No |
The client token that ensures the idempotence of the request. You can use the client to generate the token, which must be unique across requests. Only ASCII characters are allowed. Note
If you do not set this parameter, the value of RequestId is used. The value of RequestId is different for each request. |
123e4567-e89b-12d3-a456-426655440000 |
| RegionId |
string |
No |
The ID of the region where the NLB instance is deployed. You can call the DescribeRegions operation to query available regions. |
cn-hangzhou |
| Tag |
array<object> |
No |
The tags. |
|
|
object |
No |
The tag. |
||
| Key |
string |
No |
The key of the tag. It must be 1 to 64 characters in length, cannot start with You can add up to 20 tags for the security policy in each call. |
KeyTest |
| Value |
string |
No |
The value of the tag. It must be 1 to 128 characters in length, cannot start with You can add up to 20 tags for the security policy in each call. |
ValueTest |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
RpcResponse |
||
| RequestId |
string |
The ID of the request. |
D7A8875F-373A-5F48-8484-25B07A61F2AF |
| SecurityPolicyId |
string |
The ID of the TLS security policy. |
tls-bp14bb1e7dll4f**** |
| JobId |
string |
The ID of the asynchronous task. |
72dcd26b-f12d-4c27-b3af-18f6aed5**** |
Examples
Success response
JSON format
{
"RequestId": "D7A8875F-373A-5F48-8484-25B07A61F2AF",
"SecurityPolicyId": "tls-bp14bb1e7dll4f****",
"JobId": "72dcd26b-f12d-4c27-b3af-18f6aed5****"
}
Error codes
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 400 | IllegalParam | The param of %s is illegal. | |
| 403 | Forbidden.NoPermission | Authentication is failed for NoPermission. | Authentication is failed for NoPermission. |
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.