4.2 DeleteCertificate

The DeleteCertificate message is used to request the removal of a certificate from the charge point's certificate store. This operation is typically initiated by the central system when a certificate is no longer needed or has been revoked.

API Syntax

Description

Input Params

Return Value

SetDeleteCertificateStatus

This function sets the status of the certificate deletion operation.

DEL_CERT_STATUS_T status

void

Example:

  case DELETE_CERTIFICATE:
  {
    char* messageID = GetDeleteCertificateMessageID();
    SetDeleteCertificateStatus(DELETE_CERTIFICATE_ACCEPTED);
    SendDeleteCertificateResponse(messageID);
  }
  break;

API Syntax

Description

Input Params

Return Value

SendDeleteCertificateResponse

This function sends a response to a Delete Certificate request.

char *resUUID

DELETECERT_ERROR_T

Example:

  case DELETE_CERTIFICATE:
  {
    char* messageID = GetDeleteCertificateMessageID();
    SetDeleteCertificateStatus(DELETE_CERTIFICATE_ACCEPTED);
    SendDeleteCertificateResponse(messageID);
  }
  break;

API Syntax

Description

Input Params

Return Value

DeleteCertificateBasedOnHash

Function that deletes the installed certificate

const char *directory

void

Example:

  OCPPLogMessage(LOG_DEBUG, LOG_RECEIVED, "certificateHashData hashAlgorithm : %s issuerNameHash: %s issuerKeyHash: %s serialNumber: %s\n\r", HashAlgorithmENUMChar[rxDeleteCertificate.hashAlgorithm], rxDeleteCertificate.issuerNameHash, rxDeleteCertificate.issuerKeyHash, rxDeleteCertificate.serialNumber);
 DeleteCertificateBasedOnHash(".");