Built Info
Date
Nov 29, 2023, 17:16:48
Hash
67c93b6
SDK
v0.0.16
Cornerlation
v0.1.11
Pseudo Code
            // sign-in-ecdh

seed = ECDH({ curve: P-256 })





// sign-in

seed = stretch({ user: username, note: password })





// stretch

|--PBKDF2--------|
|           salt <-
|     passphrase <-
|  hash:  sha256 |
| round: 100_000 |
|----------------|

acc = seed || cornerlation.namespace

uuid = uuid || cornerlation[slug].uuid

for (x of [ salt?, note?, user?, uuid ]) {

    acc = PBKDF2({ salt: acc, passphrase: x || acc })

}





// application

entropy = acc

password = sha512(entropy).map(n => lookup_table[n])

mnemonic = bip39(sha256(entropy))

{ enc, dec } = aes256gcm({ key_iv: sha512(entropy) })