Updated on 2023-02-16 GMT+08:00

AT+HMPKS

This command is used to set the server or client certificate.

Command

Parameter

Default Parameter Processing

AT Response

Example

AT+HMPKS

=type, para1,[para2]

type: The value 0 indicates the platform certificate. The certificate content is specified by para1.

type: The value 1 indicates the public key certificate of a device. The certificate content is specified by para1.

type: The value 2 indicates the private key certificate of a device. The certificate content is specified by para1, and the password is specified by para2.

para1 is used to store a certificate. If this parameter is left blank, the certificate is to be deleted.

para2 is used to store the password of a private key certificate. It is valid only when a private key certificate is set and the certificate (a PEM file) is transmitted in the character string format.

Custom

+HMPKS OK when success

+HMPKS ERR when failed

AT+HMPKS = 0,"SERVER_CA"

The certificate cannot contain ".