&gt; 1. The web crypto api was indeed made to secure communications, such as stated by the W3C on <a href="http:&#x2F;&#x2F;www.w3.org&#x2F;TR&#x2F;WebCryptoAPI&#x2F;" rel="nofollow">http:&#x2F;&#x2F;www.w3.org&#x2F;TR&#x2F;WebCryptoAPI&#x2F;</a> (...) &quot;Uses for this API range from user or service authentication, document or code signing, and the confidentiality and integrity of communications. &quot;<p>So they say. You&#x27;d be hard-pressed to find a cryptographer that <i>likes</i> Web Crypto.<p>&gt; 2. Yes, you are definetly right, an detailed audit of the protocol is necessary by more than one expert.<p>Shameless plug: <a href="https:&#x2F;&#x2F;paragonie.com&#x2F;service&#x2F;code-review" rel="nofollow">https:&#x2F;&#x2F;paragonie.com&#x2F;service&#x2F;code-review</a><p>&gt; So at sign up, the client software now generates a (RSA) public key pair and some symmetric keys used for (AES) encryption and integrity protection locally and encrypts it with a passphrase. The passphrase is only known by the user, but not by the server. The encrypted string is also integrity protected. It is sent to the server, stored there, and decrypted with the passphrase at login again. This way we ensure only the client software can see secrets, such as the private key, but not the server software.<p>Are you going to build it in, say, Electron? That&#x27;s pretty neat.<p>What padding mode are you going to use for RSA? What hash function for MGF1?<p>Are you going to also employ digital signatures? Will you use the same RSA keypair for signatures?<p>What about your other parameters? (There are attacks for e=3 RSA signatures, for example.)<p>What cipher mode are you going to use for AES? What key size? Are you going to MAC then Encrypt, Encrypt and MAC, or Encrypt then MAC? I&#x27;m assuming the third option.<p>How are keys going to be authenticated to the clients? How will they detect&#x2F;prevent the server from substituting a user&#x27;s RSA (eww) key for one of their own choosing?<p>How are you going to derive your encryption keys from the password?<p>Why not save a lot of time and frustration and just use node-sodium (assuming Electron of course)?<p><pre><code>    - Transport: crypto_sign() + crypto_sign_open()
    - Encryption: crypto_box() + crypto_box_open()
    - Key derivation: crypto_pwhash() + crypto_box_seed_keypair()
      + crypto_sign_seed_keypair()
    - Salts, keys, nonces, etc: randombytes_buf()
</code></pre>
Life is easier with sodium. <a href="https:&#x2F;&#x2F;paragonie.com&#x2F;blog&#x2F;2015&#x2F;09&#x2F;how-to-safely-implement-cryptography-in-any-application" rel="nofollow">https:&#x2F;&#x2F;paragonie.com&#x2F;blog&#x2F;2015&#x2F;09&#x2F;how-to-safely-implement-c...</a>