From 4c67437c53aafdf8ec850fca82c1a7e9e7af1f48 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. PR-URL: https://github.com/nodejs/node/pull/38363 Reviewed-By: James M Snell Reviewed-By: Adrian Estrada --- 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 696fe4fc4e7907..99623e92eccddb 100644 --- a/doc/api/crypto.md +++ b/doc/api/crypto.md @@ -735,8 +735,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. +It works the same as `DiffieHellman`, except that it does not allow changing +its keys after creation. In other words, it does not implement `setPublicKey()` +or `setPrivateKey()` methods. ```js const name = 'modp1';