diff options
author | Martin Willi <martin@revosec.ch> | 2010-05-21 09:53:23 +0200 |
---|---|---|
committer | Martin Willi <martin@revosec.ch> | 2010-05-21 16:25:51 +0200 |
commit | aab861608a06353fe297da66f49957ce12529bc1 (patch) | |
tree | b48eb167dd5155db29d77f0845142982b7e5a742 /src/libstrongswan/plugins/pgp/pgp_cert.c | |
parent | 8029e5efd2a264ff9c5c20e81e4c092c11a643eb (diff) | |
download | strongswan-aab861608a06353fe297da66f49957ce12529bc1.tar.bz2 strongswan-aab861608a06353fe297da66f49957ce12529bc1.tar.xz |
Removed is_newer() from certificate_t, obsoleting all implementations
Diffstat (limited to 'src/libstrongswan/plugins/pgp/pgp_cert.c')
-rw-r--r-- | src/libstrongswan/plugins/pgp/pgp_cert.c | 18 |
1 files changed, 0 insertions, 18 deletions
diff --git a/src/libstrongswan/plugins/pgp/pgp_cert.c b/src/libstrongswan/plugins/pgp/pgp_cert.c index cd04f3d1a..c4bdff69d 100644 --- a/src/libstrongswan/plugins/pgp/pgp_cert.c +++ b/src/libstrongswan/plugins/pgp/pgp_cert.c @@ -188,23 +188,6 @@ static bool get_validity(private_pgp_cert_t *this, time_t *when, } /** - * Implementation of certificate_t.is_newer. - */ -static bool is_newer(certificate_t *this, certificate_t *that) -{ - time_t this_update, that_update, now = time(NULL); - bool new; - - this->get_validity(this, &now, &this_update, NULL); - that->get_validity(that, &now, &that_update, NULL); - new = this_update > that_update; - DBG1(DBG_LIB, " certificate from %T is %s - existing certificate" - " from %T %s", &this_update, FALSE, new ? "newer" : "not newer", - &that_update, FALSE, new ? "replaced" : "retained"); - return new; -} - -/** * Implementation of certificate_t.get_encoding. */ static chunk_t get_encoding(private_pgp_cert_t *this) @@ -276,7 +259,6 @@ private_pgp_cert_t *create_empty() this->public.interface.interface.issued_by = (bool (*) (certificate_t*, certificate_t*))issued_by; this->public.interface.interface.get_public_key = (public_key_t* (*) (certificate_t*))get_public_key; this->public.interface.interface.get_validity = (bool (*) (certificate_t*, time_t*, time_t*, time_t*))get_validity; - this->public.interface.interface.is_newer = (bool (*) (certificate_t*,certificate_t*))is_newer; this->public.interface.interface.get_encoding = (chunk_t (*) (certificate_t*))get_encoding; this->public.interface.interface.equals = (bool (*)(certificate_t*, certificate_t*))equals; this->public.interface.interface.get_ref = (certificate_t* (*)(certificate_t*))get_ref; |