mirror of
https://github.com/logos-messaging/libchat.git
synced 2026-08-26 07:31:09 +00:00
feat: http server based key package registry (#124)
* feat: http server based key package registry * chore: instructions on running the registration service * chore: remove duplicate post param * chore: revert out sourced account id for multi devices support * feat: signature on account id and key packages * chore: include http registry in contact registry module * refactor: use device id for retrieve key package * chore: use string for device id * feat: server verification on the register * chore: doc the smoke test * chore: fix data folder non exist * chore: use payload for register and retrieve * chore: fix clippy
This commit is contained in:
@@ -68,6 +68,12 @@ impl Ed25519VerifyingKey {
|
||||
.verify_strict(msg, &ed25519_dalek::Signature::from_bytes(&inner_signature))
|
||||
.map_err(|_| SignatureVerificationError {})
|
||||
}
|
||||
|
||||
pub fn from_bytes(bytes: &[u8; 32]) -> Result<Self, SignatureVerificationError> {
|
||||
ed25519_dalek::VerifyingKey::from_bytes(bytes)
|
||||
.map(Self)
|
||||
.map_err(|_| SignatureVerificationError {})
|
||||
}
|
||||
}
|
||||
|
||||
impl From<ed25519_dalek::VerifyingKey> for Ed25519VerifyingKey {
|
||||
|
||||
Reference in New Issue
Block a user