mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-05-21 23:40:26 -04:00
added methods to check public/private keys for consistent fingerprint and content. Should be later used to check GXS keys when they arrive from neighbor nodes.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@8613 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
685ddbbf0a
commit
0873c0dfa2
2 changed files with 87 additions and 14 deletions
|
@ -112,7 +112,17 @@ class GxsSecurity
|
|||
* @param sign Signature for the data
|
||||
* @return true if signature checks
|
||||
*/
|
||||
static bool validateSignature(const char *data, uint32_t data_len, const RsTlvSecurityKey& pubKey, const RsTlvKeySignature& sign);
|
||||
static bool validateSignature(const char *data, uint32_t data_len, const RsTlvSecurityKey& pubKey, const RsTlvKeySignature& sign);
|
||||
|
||||
/*!
|
||||
* Checks that the public key has correct fingerprint and correct flags.
|
||||
* @brief checkPublicKey
|
||||
* @param key
|
||||
* @return false if the key is invalid.
|
||||
*/
|
||||
|
||||
static bool checkPublicKey(const RsTlvSecurityKey &key);
|
||||
static bool checkPrivateKey(const RsTlvSecurityKey &key);
|
||||
};
|
||||
|
||||
#endif // GXSSECURITY_H
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue