Funzione CertStore_GetCertificateNotBeforeCertStore_GetCertificateNotBefore function
Intestazione: #include <applibs/certstore.h>Header: #include <applibs/certstore.h>
Ottiene i campi NotBefore da un certificato.Gets the NotBefore fields from a certificate. Questo campo specifica la data e l'ora in cui un certificato diventa valido.This field specifies the date and time at which the certificate becomes valid.
static int CertStore_GetCertificateNotBefore(const char *identifier, struct tm *outNotBefore);
ParametriParameters
identifier
ID del certificato.identifier
The ID of the certificate.outNotBefore
Puntatore a una strutturatm
che deve ricevere l'ora di NotBefore.outNotBefore
A pointer to atm
structure to receive the Not Before time. I campitm_wday
,tm_yday
etm_isdst
della struttura non saranno definiti.Thetm_wday
,tm_yday
, andtm_isdst
fields in the structure will be undefined.
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 the CertStore capability isn't set in the application manifest.
EAGAIN: il componente certstore del sistema operativo non è ancora pronto.EAGAIN: the OS certstore component isn't ready yet.
EFAULT: il valore di
identifier
è NULL.EFAULT: theidentifier
is NULL.EINVAL: il parametro
identifier
specifica un certificato non valido o danneggiato.EINVAL: theidentifier
parameter specifies an invalid or corrupted certificate.ENOENT: non è possibile trovare il certificato indicato da
identifier
.ENOENT: theidentifier
certificate cannot be found.
È 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.
Requisiti del manifesto dell'applicazioneApplication manifest requirements
Il manifesto dell'applicazione deve includere la funzionalità CertStore.The application manifest must include the CertStore capability.