mirror of
https://github.com/fromchat-messenger/web.git
synced 2026-09-23 03:25:07 +03:00
Fix keys storage
This commit is contained in:
@@ -6,6 +6,8 @@ export interface X25519KeyPair {
|
||||
privateKey: Uint8Array;
|
||||
}
|
||||
|
||||
export type KeyPair = X25519KeyPair;
|
||||
|
||||
export function generateX25519KeyPair(): X25519KeyPair {
|
||||
const kp = nacl.box.keyPair();
|
||||
return { publicKey: kp.publicKey, privateKey: kp.secretKey };
|
||||
|
||||
Reference in New Issue
Block a user