What is the key size that RSA and Diffie-Hellman are using now that can guarantee secure communication over Internet and will not be able to break by the best available algorithms (NFS & FFS or any others) in feasible time?


2 Answers 2


Currently (as of 2017-05-11) 2048-bit keys are most popular for use with RSA, and 2048 bit keys should also be used with classic Diffie-Hellman. These offer about the same security as a symmetric encryption algorithm with 112 bits of security.

Also in common use as of this date are 256 bit Elliptic Curve keys (mostly NIST P-256 and Curve25519) for ECDH/ECDSA/EdDSA which offer the same security as a 128-bit symmetric algorithm.

A good primer on the reasons for these key size differences can be found here.


A good overview on that matter can always be found on https://keylength.com, which summarises many publications with recommendations for key lengths. Especially NIST SP-800-38 yields good data for your question.

For 112 bit security (which is about the minimum you should use for not extremely important things) you currently (2016) have to use RSA-2048 keys, 2048 bit DH groups or 224 bit elliptic curves.

  • 2
    $\begingroup$ This should be the accepted answer as it is more future proof $\endgroup$ Commented May 12, 2017 at 6:11
  • $\begingroup$ I don't know about future-proof, the author seems to be 6 months in the past! (I'm joking, but "currently" is not 2016...) $\endgroup$
    – IMSoP
    Commented May 12, 2017 at 10:17
  • 3
    $\begingroup$ "Currently" as in "according to the current NIST specification which dates from 2016". Those recommendation do not always get updated every year. $\endgroup$
    – mat
    Commented May 12, 2017 at 10:49

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.