mirror of
https://github.com/meshcore-dev/MeshCore.git
synced 2026-04-20 22:13:47 +00:00
allow set prv.key from remote, validate new prv.key
This commit is contained in:
parent
988287bfd7
commit
96ef5e5efe
7 changed files with 73 additions and 20 deletions
|
|
@ -76,6 +76,13 @@ public:
|
|||
*/
|
||||
void calcSharedSecret(uint8_t* secret, const uint8_t* other_pub_key) const;
|
||||
|
||||
/**
|
||||
* \brief Validates that a given private key can be used for ECDH / shared-secret operations.
|
||||
* \param prv IN - the private key to validate (must be PRV_KEY_SIZE bytes)
|
||||
* \returns true, if the private key is valid for login.
|
||||
*/
|
||||
static bool validatePrivateKey(const uint8_t prv[64]);
|
||||
|
||||
bool readFrom(Stream& s);
|
||||
bool writeTo(Stream& s) const;
|
||||
void printTo(Stream& s) const;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue