Issues a client certificate based on a system-generated Certificate Signing Request (CSR).
Operation description
Before you call this operation, you must call CreateRootCACertificate to create a root CA certificate and CreateSubCACertificate to create a subordinate CA certificate. Only subordinate CA certificates can issue client certificates.
QPS limit
The queries per second (QPS) limit for this operation is 10 calls per second for each user. If you exceed the limit, API calls are throttled. This may affect your business. Plan your calls accordingly.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
yundun-cert:CreateClientCertificate |
create |
*All Resource
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| SanType |
integer |
No |
The type of Subject Alternative Name (SAN) extension for the client certificate. Valid values:
|
1 |
| SanValue |
string |
No |
The content of the SAN extension. To specify multiple SANs, separate them with commas (,). |
somebody@example.com |
| Organization |
string |
No |
The name of the organization. The default value is Alibaba Inc. |
阿里云 |
| OrganizationUnit |
string |
No |
The name of the department. The default value is Aliyun CDN. |
IT |
| Country |
string |
No |
The country code. The default value is CN. |
CN |
| CommonName |
string |
No |
The name of the certificate user. The user of a client authentication (ClientAuth) certificate is typically a person, company, organization, or an application. Enter the common name of the user, such as John Doe, Alibaba, Alibaba Cloud Cryptography Platform, or Tmall Genie. |
aliyun |
| State |
string |
No |
The name of the province or state where the organization is located. Chinese characters and letters are supported. By default, this parameter is set to the province or state of the organization that is associated with the issuing subordinate CA certificate. |
Zhejiang |
| Locality |
string |
No |
The name of the city where the organization is located. Chinese characters and letters are supported. By default, this parameter is set to the city of the organization that is associated with the issuing subordinate CA certificate. |
杭州市 |
| Algorithm |
string |
No |
The key algorithm of the client certificate. The algorithm is in the
The encryption algorithm of the client certificate must be the same as the encryption algorithm of the subordinate CA certificate, but the key length can be different. For example, if the key algorithm of the subordinate CA certificate is RSA_2048, the key algorithm of the client certificate must be RSA_1024, RSA_2048, or RSA_4096. Note
You can call DescribeCACertificate to query the key algorithm of the subordinate CA certificate. |
RSA_2048 |
| ParentIdentifier |
string |
No |
The unique identifier of the subordinate CA certificate that issues this certificate. Note
You can call [DescribeCACertificateList] to query the unique identifiers of subordinate CA certificates. |
273ae6bb538d538c70c01f81jh2**** |
| Years |
integer |
No |
The validity period of the certificate. Unit: years. |
5 |
| Months |
integer |
No |
The validity period of the certificate. Unit: months. |
1 |
| Days |
integer |
No |
The validity period of the client certificate in days. The Days, BeforeTime, and AfterTime parameters cannot all be empty. The BeforeTime and AfterTime parameters must be specified together or both left empty. The following rules apply:
Note
|
365 |
| BeforeTime |
integer |
No |
The issuance time of the client certificate. This is a UNIX timestamp. The default value is the time when you call this operation. Unit: seconds. Note
The BeforeTime and AfterTime parameters must be specified together or both left empty. |
1634283958 |
| AfterTime |
integer |
No |
The expiration time of the client certificate. This is a UNIX timestamp. Unit: seconds. Note
The BeforeTime and AfterTime parameters must be specified together or both left empty. |
1665819958 |
| Immediately |
integer |
No |
Specifies whether to immediately return the digital certificate.
|
1 |
| EnableCrl |
integer |
No |
Specifies whether to include the Certificate Revocation List (CRL) address. 0 - No 1 - Yes |
1 |
| Tags |
array<object> |
No |
A list of tags. |
|
|
object |
No |
A list of tags. |
||
| Key |
string |
No |
The tag key. |
account |
| Value |
string |
No |
The tag value. |
1 |
| ResourceGroupId |
string |
No |
The ID of the resource group. |
rg-aek****wia |
In addition to the parameters described in this topic, you must also include the common request parameters of Alibaba Cloud APIs. For the request format, see the request example in the Examples section.
For the API request format, see the request example in the Examples section of this topic.
Response elements
|
Element |
Type |
Description |
Example |
|
object |
CreateCertificateResponse<CertificateIdentifierWithParentDto> |
||
| X509Certificate |
string |
The content of the client certificate. |
-----BEGIN CERTIFICATE-----\n......\n-----END CERTIFICATE----- |
| CertificateChain |
string |
The CA certificate chain. |
-----BEGIN CERTIFICATE-----\n......\n-----END CERTIFICATE-----\n-----BEGIN CERTIFICATE-----\n......\n-----END CERTIFICATE-----\n |
| Identifier |
string |
The unique identifier of the client certificate. |
190ae6bb538d538c70c01f81dcf2**** |
| SerialNumber |
string |
The certificate serial number. |
084bde9cd233f0ddae33adc438cfbbbd**** |
| RequestId |
string |
The ID of the request. This ID is generated by Alibaba Cloud and is unique for each request. You can use this ID to troubleshoot issues. |
8C467B38-3910-447D-87BC-AC049166F216 |
Examples
Success response
JSON format
{
"X509Certificate": "-----BEGIN CERTIFICATE-----\\n......\\n-----END CERTIFICATE-----",
"CertificateChain": "-----BEGIN CERTIFICATE-----\\n......\\n-----END CERTIFICATE-----\\n-----BEGIN CERTIFICATE-----\\n......\\n-----END CERTIFICATE-----\\n",
"Identifier": "190ae6bb538d538c70c01f81dcf2****",
"SerialNumber": "084bde9cd233f0ddae33adc438cfbbbd****",
"RequestId": "8C467B38-3910-447D-87BC-AC049166F216"
}
Error codes
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.