Skip to content

Commit f80bdc5

Browse files
tniessenjuanarbol
authored andcommitted
doc: deprecate modp1, modp2, and modp5 groups
These MODP groups should not be used by new applications, and existing applications should attempt to migrate to stronger groups (or different key exchange mechanisms). Some applications still rely on these particular groups, so Node.js will likely maintain support, directly or indirectly, for the foreseeable future. Refs: #44539 PR-URL: #44588 Reviewed-By: Ben Noordhuis <[email protected]> Reviewed-By: Luigi Pinca <[email protected]> Reviewed-By: Rich Trott <[email protected]>
1 parent 9fac6dd commit f80bdc5

File tree

3 files changed

+29
-4
lines changed

3 files changed

+29
-4
lines changed

doc/api/crypto.md

+8-3
Original file line numberDiff line numberDiff line change
@@ -1185,15 +1185,20 @@ const dh = createDiffieHellmanGroup('modp16');
11851185

11861186
The following groups are supported:
11871187

1188-
* `'modp1'` (768 bits, [RFC 2409][] Section 6.1)
1189-
* `'modp2'` (1024 bits, [RFC 2409][] Section 6.2)
1190-
* `'modp5'` (1536 bits, [RFC 3526][] Section 2)
11911188
* `'modp14'` (2048 bits, [RFC 3526][] Section 3)
11921189
* `'modp15'` (3072 bits, [RFC 3526][] Section 4)
11931190
* `'modp16'` (4096 bits, [RFC 3526][] Section 5)
11941191
* `'modp17'` (6144 bits, [RFC 3526][] Section 6)
11951192
* `'modp18'` (8192 bits, [RFC 3526][] Section 7)
11961193

1194+
The following groups are still supported but deprecated (see [Caveats][]):
1195+
1196+
* `'modp1'` (768 bits, [RFC 2409][] Section 6.1) <span class="deprecated-inline"></span>
1197+
* `'modp2'` (1024 bits, [RFC 2409][] Section 6.2) <span class="deprecated-inline"></span>
1198+
* `'modp5'` (1536 bits, [RFC 3526][] Section 2) <span class="deprecated-inline"></span>
1199+
1200+
These deprecated groups might be removed in future versions of Node.js.
1201+
11971202
## Class: `ECDH`
11981203

11991204
<!-- YAML

doc/api/deprecations.md

+19
Original file line numberDiff line numberDiff line change
@@ -3147,9 +3147,28 @@ Type: Documentation-only
31473147

31483148
The [`--trace-atomics-wait`][] flag is deprecated.
31493149

3150+
### DEP0167: Weak `DiffieHellmanGroup` instances (`modp1`, `modp2`, `modp5`)
3151+
3152+
<!-- YAML
3153+
changes:
3154+
- version: REPLACEME
3155+
pr-url: https://github.com/nodejs/node/pull/44588
3156+
description: Documentation-only deprecation.
3157+
-->
3158+
3159+
Type: Documentation-only
3160+
3161+
The well-known MODP groups `modp1`, `modp2`, and `modp5` are deprecated because
3162+
they are not secure against practical attacks. See [RFC 8247 Section 2.4][] for
3163+
details.
3164+
3165+
These groups might be removed in future versions of Node.js. Applications that
3166+
rely on these groups should evaluate using stronger MODP groups instead.
3167+
31503168
[Legacy URL API]: url.md#legacy-url-api
31513169
[NIST SP 800-38D]: https://nvlpubs.nist.gov/nistpubs/Legacy/SP/nistspecialpublication800-38d.pdf
31523170
[RFC 6066]: https://tools.ietf.org/html/rfc6066#section-3
3171+
[RFC 8247 Section 2.4]: https://www.rfc-editor.org/rfc/rfc8247#section-2.4
31533172
[WHATWG URL API]: url.md#the-whatwg-url-api
31543173
[`"exports"` or `"main"` entry]: packages.md#main-entry-point-export
31553174
[`--pending-deprecation`]: cli.md#--pending-deprecation

doc/api_assets/style.css

+2-1
Original file line numberDiff line numberDiff line change
@@ -598,7 +598,8 @@ hr {
598598
padding-left: 5rem;
599599
}
600600

601-
#toc .stability_0::after {
601+
#toc .stability_0::after,
602+
.deprecated-inline::after {
602603
background-color: var(--red2);
603604
color: var(--white);
604605
content: "deprecated";

0 commit comments

Comments
 (0)