implemented rereadcrls rereadcacerts

This commit is contained in:
Andreas Steffen
2006-06-20 06:08:33 +00:00
parent a8ed64c494
commit 76dafed7a7
8 changed files with 137 additions and 70 deletions
+10 -1
View File
@@ -331,6 +331,14 @@ static err_t is_valid(const private_crl_t *this, time_t *until, bool strict)
return NULL;
}
/**
* Implements crl_t.is_newer
*/
static bool is_newer(const private_crl_t *this, const private_crl_t *other)
{
return (this->nextUpdate > other->nextUpdate);
}
/**
* Implements crl_t.get_issuer
*/
@@ -435,7 +443,8 @@ crl_t *crl_create_from_chunk(chunk_t chunk)
this->public.is_valid = (err_t (*) (const crl_t*,time_t*))is_valid;
this->public.destroy = (void (*) (crl_t*))destroy;
this->public.get_issuer = (identification_t* (*) (const crl_t*))get_issuer;
this->public.equals_issuer = (bool (*) (const crl_t*, const crl_t*))equals_issuer;
this->public.equals_issuer = (bool (*) (const crl_t*,const crl_t*))equals_issuer;
this->public.is_newer = (bool (*) (const crl_t*,const crl_t*))is_newer;
this->public.log_crl = (void (*) (const crl_t*,logger_t*,bool,bool))log_crl;
/* we do not use a per-instance logger right now, since its not always accessible */
+11 -2
View File
@@ -77,13 +77,22 @@ struct crl_t {
/**
* @brief Checks the validity interval of the crl
*
* @param this certificate being examined
* @param this calling object
* @param until until = min(until, nextUpdate) if strict == TRUE
* @param strict nextUpdate restricts the validiat
* @param strict nextUpdate restricts the validity
* @return NULL if the crl is valid
*/
err_t (*is_valid) (const crl_t *this, time_t *until, bool strict);
/**
* @brief Checks if this crl is newer (thisUpdate) than the other crl
*
* @param this calling object
* @param other other crl object
* @return TRUE if this was issued more recently than other
*/
bool (*is_newer) (const crl_t *this, const crl_t *other);
/**
* @brief Check if a certificate has been revoked.
*
+1 -1
View File
@@ -665,7 +665,7 @@ static status_t get_last(private_linked_list_t *this, void **item)
/**
* Implementation of linked_list_t.create_iterator.
*/
static iterator_t *create_iterator (private_linked_list_t *linked_list,bool forward)
static iterator_t *create_iterator (private_linked_list_t *linked_list, bool forward)
{
private_iterator_t *this = malloc_thing(private_iterator_t);