Public/Private keys implement a has_fingerprint() method
This commit is contained in:
@@ -154,6 +154,14 @@ struct public_key_t {
|
||||
bool (*get_fingerprint)(public_key_t *this, key_encoding_type_t type,
|
||||
chunk_t *fp);
|
||||
|
||||
/**
|
||||
* Check if a key has a given fingerprint of any kind.
|
||||
*
|
||||
* @param fp fingerprint to check
|
||||
* @return TRUE if key has given fingerprint
|
||||
*/
|
||||
bool (*has_fingerprint)(public_key_t *this, chunk_t fp);
|
||||
|
||||
/**
|
||||
* Get the key in an encoded form as a chunk.
|
||||
*
|
||||
@@ -186,6 +194,15 @@ struct public_key_t {
|
||||
*/
|
||||
bool public_key_equals(public_key_t *this, public_key_t *other);
|
||||
|
||||
/**
|
||||
* Generic public key has_fingerprint() implementation, usable by implementors.
|
||||
*
|
||||
* @param this key to check fingerprint
|
||||
* @param fp fingerprint to check
|
||||
* @return TRUE if key has given fingerprint
|
||||
*/
|
||||
bool public_key_has_fingerprint(public_key_t *this, chunk_t fingerprint);
|
||||
|
||||
/**
|
||||
* Conversion of ASN.1 signature or hash OID to signature scheme.
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user