From 13c55c3b707f91f34ee180ca01b27e8076533ca5 Mon Sep 17 00:00:00 2001 From: Nitzan Uziely Date: Thu, 22 Apr 2021 23:28:19 +0300 Subject: [PATCH] doc: clarify DiffieHellmanGroup class docs Make it clearer in the docs that DiffieHellmanGroup does not support changing the keys after creation. --- doc/api/crypto.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/doc/api/crypto.md b/doc/api/crypto.md index 9b4559473ca7e5..ee474e67674035 100644 --- a/doc/api/crypto.md +++ b/doc/api/crypto.md @@ -1114,8 +1114,10 @@ module): added: v0.7.5 --> -The `DiffieHellmanGroup` class takes a well-known modp group as its argument but -otherwise works the same as `DiffieHellman`. +The `DiffieHellmanGroup` class takes a well-known modp group as its argument. +Works the same as `DiffieHellman`, except that it does not allow changing its +keys after creation - i.e. does not implement `setPublicKey` or `setPrivateKey` +methods. ```mjs const { createDiffieHellmanGroup } = await import('crypto');