nrf9160

Set command

The set command reads the Transport Layer Security (TLS) certificate expiry information.

Syntax:

%CERTEXPIRY=<sec_tag>,<type>

Response syntax:

%CERTEXPIRY: <serial number>,<notBefore>,<notAfter>

The set command parameters and their defined values are the following:

<sec_tag>
Integer, 1–2147483647.
<type>
0 – Root CA certificate.
1 – Client certificate.
10 – Nordic identity root CA.
<serial number>
String in hexadecimal format. Certificate serial number.
<notBefore>
Certificate not valid before.
Format: yyyymmddhhmmssZ
yyyy – Four digits for the year.
mm – Two digits for the month.
dd – Two digits for the date.
hh – Two digits for hours.
mm – Two digits for minutes.
ss – Two digits for seconds.
Z – Time zone Zulu/UTC.
<NotAfter>
Certificate not valid after.
Format: yyyymmddhhmmssZ
+CME ERROR code
513 – Not found.
527 – Invalid content.

The following command example reads the expiry information of the root certificate stored in <sec_tag> 1:

%CERTEXPIRY=1,0

The following response example reads the expiry information of a certificate with serial number 00AEF87681FA968B61 that is valid from August 23, 2017 8:47:37 AM GMT to August 23, 2018 8:47:37 AM GMT:

%CERTEXPIRY: 00AEF87681FA968B61,20170823084737Z,20180823084737Z