Description
Node exposes various IKE MODP groups. It appears the list was chosen by exporting every group provided by OpenSSL:
https://github.com/nodejs/node/blob/main/src/crypto/crypto_dh.cc#L222-L229
https://nodejs.org/api/crypto.html#class-diffiehellmangroup
However, some of these groups are too small to be used. See RFC 8247, section 2.4:
Group 5 or the 1536-bit MODP Group has been downgraded from MAY in
RFC 4307 to SHOULD NOT. It was specified earlier, but is now
considered to be vulnerable to being broken within the next few years
by a nation-state-level attack, so its security margin is considered
too narrow.Group 2 or the 1024-bit MODP Group has been downgraded from MUST- in
RFC 4307 to SHOULD NOT. It is known to be weak against sufficiently
funded attackers using commercially available mass-computing
resources, so its security margin is considered too narrow. It is
expected in the near future to be downgraded to MUST NOT.Group 1 or the 768-bit MODP Group was not mentioned in RFC 4307 and
so its status was MAY. It can be broken within hours using cheap
off-the-shelf hardware. It provides no security whatsoever. It has,
therefore, been downgraded to MUST NOT.
These are all exposed by Node as "modp1", "modp2", and "modp5". The documentation should reflect their status and they should be deprecated and removed, especially modp1.