Update srp.ts

This commit is contained in:
Daniel Hougaard
2024-02-22 05:00:26 +01:00
parent f35f10558b
commit 3ea529d525
+3 -1
View File
@@ -33,7 +33,9 @@ export const srpCheckClientProof = async (
return server.checkClientProof(clientProof); return server.checkClientProof(clientProof);
}; };
// FOR GHOST USER STUFF // Ghost user related:
// This functionality is intended for ghost user logic. This happens on the frontend when a user is being created.
// We replicate the same functionality on the backend when creating a ghost user.
export const generateUserSrpKeys = async (email: string, password: string) => { export const generateUserSrpKeys = async (email: string, password: string) => {
const pair = nacl.box.keyPair(); const pair = nacl.box.keyPair();
const secretKeyUint8Array = pair.secretKey; const secretKeyUint8Array = pair.secretKey;