4.9 RenewCertificate
int RenewCertificate(CertificateDetails certificate);
The RenewCertificate method requests a certificate renewal job for the given certificate. This follows the normal certificate renewal rules with the following additional rules:
-
The auto renewal status of the certificate is ignored. Any valid certificate is a candidate for renewal.
-
Revoked or partially issued certificates are not allowed to be renewed.
-
Expired certificates are allowed to be renewed only if the configuration flag Renew Expired Certs Via API (on the Certificates tab of the Operation Settings workflow) is set to Yes.
-
There is no minimum lifetime for the certificate before it can be renewed. This allows the renewal process to also be used for certificate re-issuance or migration.
-
Due to inconsistent behavior between CAs, it is unreliable to identify a certificate based on its serial number.
Note: If the certificate renewal process results in the creation of a card renewal job because the target device is due to expire soon, an exception will be thrown.
4.9.1 Inputs
Class |
Field |
Data Type |
Description |
Allow Null? |
---|---|---|---|---|
CertificateDetails |
|
|
|
No |
|
SerialNumber |
String |
The serial number of the device to which the certificate is to be issued. Maps to: Certificates.DeviceSerialNo |
No |
|
DeviceTypeName |
String |
The device type name of the device to which the certificate is to be issued. Maps to: Certificates.DeviceTypeName |
No |
|
Policy |
String |
The name for the certificate policy with which the certificate was issued. Maps to: Certificates.CertPolicy |
No |
The certificate that will be renewed will be the most recently issued certificate of the specified policy, on the specified device.
4.9.2 Output
The output is the job ID for the newly-created renewal job. Any failures to create this job will result in an exception being thrown. Possible error scenarios are:
-
Certificate Not Found
-
Certificate Revoked
-
Certificate Expired
-
Certificate Unsuitable
-
Device Renewal Job Created