Funzione CertStore_DeleteCertificateCertStore_DeleteCertificate function
Intestazione: #include <applibs/certstore.h>Header: #include <applibs/certstore.h>
Elimina un certificato.Deletes a certificate.
int CertStore_DeleteCertificate(const char *identifier);
ParametriParameters
identifier
ID del certificato da eliminare.identifier
The ID of the certificate to delete.
ErroriErrors
Restituisce-1 se viene rilevato un errore e imposta sul errno
valore di errore.Returns -1 if an error is encountered and sets errno
to the error value.
EACCES: l'operazione non è consentita perché la funzionalità CertStore non è impostata nel manifesto dell'applicazione.EACCES: the operation isn't allowed because CertStore capability isn't set in the application manifest.
EAGAIN: il sistema operativo non è pronto per le operazioni sui certificati.EAGAIN: the OS is not ready for certificate operations. Ripetere la richiesta in un secondo momento.Try the request again later.
EFAULT: il valore di
identifier
è NULL.EFAULT: theidentifier
is NULL.ENOENT: non è presente alcun certificato con l'ID specificato.ENOENT: there's no certificate with the specified ID.
È errno
possibile specificare anche qualsiasi altro tipo di errore. tali errori non sono deterministici e non vi è alcuna garanzia che lo stesso comportamento venga mantenuto tramite gli aggiornamenti del sistema.Any other errno
may also be specified; such errors aren't deterministic and there's no guarantee that the same behavior will be retained through system updates.
Valore restituitoReturn value
Restituisce 0 per l'esito positivo o-1 per l'esito negativo, nel qual caso errno
viene impostato sul valore di errore.Returns 0 for success, or -1 for failure, in which case errno
is set to the error value.
OsservazioniRemarks
I certificati vengono archiviati in base all'indice.Certificates are stored by index. L'eliminazione di un certificato causa la reindicizzazione dei certificati rimanenti, a partire da 0.Deleting a certificate causes the remaining certificates to be reindexed, starting at 0. Gestire i certificati in app di alto livello illustra come eliminare tutti i certificati presenti in un dispositivo.Manage certificates in high-level applications shows how to delete all the certificates on a device.
Requisiti del manifesto dell'applicazioneApplication manifest requirements
Il manifesto dell'applicazione deve includere la funzionalità CertStore.The application manifest must include the CertStore capability.