Skip to content
This repository has been archived by the owner on Apr 22, 2023. It is now read-only.

TLS Module: The default ecdhCurve, prime256v1 (aka NIST P-256) is not safe. #18205

Closed
mattcollier opened this issue Apr 21, 2015 · 6 comments
Closed
Assignees
Milestone

Comments

@mattcollier
Copy link

This document states that the default curve for the ecdhCurve parameter is prime256v1.
https://nodejs.org/api/tls.html#tls_tls_createserver_options_secureconnectionlistener

Appendix A of this document indicates that prime256v1 is also known as NIST P-256.
http://www.rfc-editor.org/rfc/rfc4492.txt

This site indicates that NIST P-256 is not secure.
http://safecurves.cr.yp.to/

I recommend that a safe alternative should be chosen as the default and unsafe curves should not be made available.

@jasnell
Copy link
Member

jasnell commented Apr 22, 2015

I was looking at this also. We may end up wanting to follow a similar path as the recent RC4/cipher-list issue and add a command line switch / environment variable combination for overriding the default curve in addition to selecting a more secure default.

/cc @misterdjules @mhdawson

@jasnell jasnell self-assigned this Apr 22, 2015
@misterdjules misterdjules added this to the 0.12.4 milestone Apr 22, 2015
@misterdjules
Copy link

@mattcollier Thank you! What safe curves would you recommend?

@misterdjules
Copy link

Added to the 0.12.4 milestone so that we at least consider that for the release after 0.12.3.

@mattcollier
Copy link
Author

The creators of the safe curves site (Daniel J. Bernstein and Tanja Lange) promote the use of curve25519 in this presentation given at the 31st Chaos Communication Congress on December 27th, 2014. According to the wikipedia article about curve25519, there are a number of notable projects that utilize this curve as a default.

A search in the openssl-dev mailing list archive does not turn up much in the way of recent activity towards implementing curve25519.

Bertstein and Lange are also contributors to the NaCl: Networking and Cryptography library

@misterdjules
Copy link

@mattcollier Thank you for the additional info, it is very much appreciated!

@misterdjules misterdjules modified the milestones: 0.12.4, 0.12.5 May 25, 2015
@misterdjules misterdjules modified the milestones: 0.12.5, 0.12.6 Jun 22, 2015
@misterdjules misterdjules modified the milestones: 0.12.6, 0.12.7, 0.12.8 Jul 6, 2015
@ChALkeR
Copy link
Member

ChALkeR commented Apr 6, 2016

This is reported to the current repo as nodejs/node#1495, no reason to keep a duplicate open here.

@ChALkeR ChALkeR closed this as completed Apr 6, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

4 participants