Mention CryptoSubtle for key storage/export

This commit is contained in:
Franck Royer 2021-08-27 14:40:46 +10:00
parent 6e5cbefc49
commit 659e167c06
No known key found for this signature in database
GPG Key ID: A82ED75A8DFC50A4
1 changed files with 4 additions and 1 deletions

View File

@ -23,7 +23,10 @@ This needs to be kept in mind for scalability and forward secrecy concerns:
By using Waku Message Version 1, you will need to provide a way to your users to generate and store keys in a secure manner.
Storing, backing up and recovering key is out of the scope of this guide.
<!-- TODO: Subtle Crypto link once it's back up https://github.com/mdn/content/issues/8314 -->
If key recovery is important for your dApp, then check out
[SubtleCrypto.wrapKey()(https://developer.mozilla.org/en-US/docs/Web/API/SubtleCrypto/wrapKey) which can be used to securely store or export private keys.
An example to save and load a key pair in local storage, protected with a password, can be found in [Eth-PM](https://github.com/status-im/js-waku/blob/main/examples/eth-pm/src/key_pair_handling/key_pair_storage.ts).
## Which encryption method do I need?