You should not use this constructor directly. Use one of:
UnlockedKeyBundle.newRandom(appData)UnlockedKeyBundle.fromLocked(encodedBytes)
WARNING: see class-level note about zeroing / secrets.the secret as a PrivSecretBuf.
Optional appData: objectoptional application data.
will throw an error if the secret is not an instance of PrivSecretBuf.
Private secretDerive a subkey / seed from this seed bundle seed. WARNING: see class-level note about zeroing / secrets.
the subkey ID for derivation.
Optional appData: objectoptional application data.
a new instance of UnlockedSeedBundle.
Encrypt this seed into seed bundle bytes with given seedCipherList - note, all seedCiphers will be zeroed. WARNING: see class-level note about zeroing / secrets.
an array of SeedCipher instances.
the encoded locked seed bundle as a Uint8Array.
will throw an error if the seedCipherList is not an array or contains invalid elements.
Static fromExtract the LockedSeedCipher list capable of decrypting an UnlockedSeedBundle from an encrypted SeedBundle. WARNING: see class-level note about zeroing / secrets.
the encoded bytes representing the locked seed bundle.
an array of LockedSeedCipher instances.
will throw an error if the encoded bytes are invalid.
Static newConstruct a new completely random root seed with given app / user data. WARNING: see class-level note about zeroing / secrets.
Optional appData: objectoptional application data.
a new instance of UnlockedSeedBundle.
Represents a seed bundle with access to secret seeds for derivation.
WARNING: Before forgetting about an UnlockedKeyBundle instance, you should probably call the
zerofunction to clear the internal secret data. HOWEVER, being javascript, there is no guarantee we haven't leaked secret data. You may want to consider using the rust library for seed generation and derivation.