Skip to content

Commit 13c55c3

Browse files
committed
doc: clarify DiffieHellmanGroup class docs
Make it clearer in the docs that DiffieHellmanGroup does not support changing the keys after creation.
1 parent bc31dc0 commit 13c55c3

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

doc/api/crypto.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1114,8 +1114,10 @@ module):
11141114
added: v0.7.5
11151115
-->
11161116

1117-
The `DiffieHellmanGroup` class takes a well-known modp group as its argument but
1118-
otherwise works the same as `DiffieHellman`.
1117+
The `DiffieHellmanGroup` class takes a well-known modp group as its argument.
1118+
Works the same as `DiffieHellman`, except that it does not allow changing its
1119+
keys after creation - i.e. does not implement `setPublicKey` or `setPrivateKey`
1120+
methods.
11191121

11201122
```mjs
11211123
const { createDiffieHellmanGroup } = await import('crypto');

0 commit comments

Comments
 (0)