{"action":"created","comment":{"url":"https://api.github.com/repos/nodejs/io.js/pulls/comments/31307619","id":31307619,"diff_hunk":"@@ -878,6 +921,8 @@ void TLSWrap::Initialize(Handle<Object> target,\n   env->SetProtoMethod(t, \"setServername\", SetServername);\n #endif  // SSL_CRT_SET_TLSEXT_SERVERNAME_CB\n \n+  env->SetProtoMethod(t, \"getEphemeralKeyInfo\", GetEphemeralKeyInfo);","path":"src/tls_wrap.cc","position":54,"original_position":54,"commit_id":"484262e49a99f842bb4b60cb581408f9dfcc131a","original_commit_id":"484262e49a99f842bb4b60cb581408f9dfcc131a","user":{"login":"indutny","id":238531,"avatar_url":"https://avatars.githubusercontent.com/u/238531?v=3","gravatar_id":"","url":"https://api.github.com/users/indutny","html_url":"https://github.com/indutny","followers_url":"https://api.github.com/users/indutny/followers","following_url":"https://api.github.com/users/indutny/following{/other_user}","gists_url":"https://api.github.com/users/indutny/gists{/gist_id}","starred_url":"https://api.github.com/users/indutny/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/indutny/subscriptions","organizations_url":"https://api.github.com/users/indutny/orgs","repos_url":"https://api.github.com/users/indutny/repos","events_url":"https://api.github.com/users/indutny/events{/privacy}","received_events_url":"https://api.github.com/users/indutny/received_events","type":"User","site_admin":false},"body":"This should be moved to `node_crypto.cc` too.","created_at":"2015-05-29T08:37:20Z","updated_at":"2015-05-29T08:37:20Z","html_url":"https://github.com/nodejs/io.js/pull/1831#discussion_r31307619","pull_request_url":"https://api.github.com/repos/nodejs/io.js/pulls/1831","_links":{"self":{"href":"https://api.github.com/repos/nodejs/io.js/pulls/comments/31307619"},"html":{"href":"https://github.com/nodejs/io.js/pull/1831#discussion_r31307619"},"pull_request":{"href":"https://api.github.com/repos/nodejs/io.js/pulls/1831"}}},"pull_request":{"url":"https://api.github.com/repos/nodejs/io.js/pulls/1831","id":36480172,"html_url":"https://github.com/nodejs/io.js/pull/1831","diff_url":"https://github.com/nodejs/io.js/pull/1831.diff","patch_url":"https://github.com/nodejs/io.js/pull/1831.patch","issue_url":"https://api.github.com/repos/nodejs/io.js/issues/1831","number":1831,"state":"open","locked":false,"title":"Add a new option to limit DH key size in tls connect","user":{"login":"shigeki","id":782880,"avatar_url":"https://avatars.githubusercontent.com/u/782880?v=3","gravatar_id":"","url":"https://api.github.com/users/shigeki","html_url":"https://github.com/shigeki","followers_url":"https://api.github.com/users/shigeki/followers","following_url":"https://api.github.com/users/shigeki/following{/other_user}","gists_url":"https://api.github.com/users/shigeki/gists{/gist_id}","starred_url":"https://api.github.com/users/shigeki/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/shigeki/subscriptions","organizations_url":"https://api.github.com/users/shigeki/orgs","repos_url":"https://api.github.com/users/shigeki/repos","events_url":"https://api.github.com/users/shigeki/events{/privacy}","received_events_url":"https://api.github.com/users/shigeki/received_events","type":"User","site_admin":false},"body":"This is the fix of logjam attack for a TLS client. It disable connecting to the TLS server with less than DH key size specified by a new option of `minDHkeylen`. The default is 1024 bits.\r\n\r\nAnd it also introduces a new public API of  `TLSSocket.getEphemeralKeyInfo()` to show  the information of an ephemeral key type, name and length of TLS connection. I think it it good for users to know them. We should prepare future vulnerabilities not only DH but also ECDH. \r\nUnfortunately openssl provided `SSL_get_server_tmp_key()` on only client so that this API returns an empty object on the server.\r\n\r\nThe last one is my home work from @bnoordhuis  to output warning of setDHParams to console.trace(). \r\n\r\nHere is a list of logjam fix in openssl, Firefox and Chrome. I think iojs is also better to set minimum key length like this.\r\n\r\n- OpenSSL sets minimum key size 768 bits. iojs will follow this limit after upgrading forthcoming 1.0.2b even if minDHkeylen get less than this.\r\nhttps://www.openssl.org/blog/blog/2015/05/20/logjam-freak-upcoming-changes/\r\n\r\n- Firefox(NSS) does it to 1023 bits. (surprisingly there were 1023 bits key certs in the past)\r\nhttps://bugzilla.mozilla.org/show_bug.cgi?id=1138554\r\n\r\n- Chrome(BoringSSL) does it to 1024 bits.\r\nhttps://boringssl-review.googlesource.com/4813\r\n\r\nR= @bnoordhuis @indutny ","created_at":"2015-05-29T07:26:49Z","updated_at":"2015-05-29T08:37:20Z","closed_at":null,"merged_at":null,"merge_commit_sha":"774ff5161ef6a523e27549fbd51ca5c001105ca7","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/nodejs/io.js/pulls/1831/commits","review_comments_url":"https://api.github.com/repos/nodejs/io.js/pulls/1831/comments","review_comment_url":"https://api.github.com/repos/nodejs/io.js/pulls/comments{/number}","comments_url":"https://api.github.com/repos/nodejs/io.js/issues/1831/comments","statuses_url":"https://api.github.com/repos/nodejs/io.js/statuses/484262e49a99f842bb4b60cb581408f9dfcc131a","head":{"label":"shigeki:fix_LogjamAttack_client","ref":"fix_LogjamAttack_client","sha":"484262e49a99f842bb4b60cb581408f9dfcc131a","user":{"login":"shigeki","id":782880,"avatar_url":"https://avatars.githubusercontent.com/u/782880?v=3","gravatar_id":"","url":"https://api.github.com/users/shigeki","html_url":"https://github.com/shigeki","followers_url":"https://api.github.com/users/shigeki/followers","following_url":"https://api.github.com/users/shigeki/following{/other_user}","gists_url":"https://api.github.com/users/shigeki/gists{/gist_id}","starred_url":"https://api.github.com/users/shigeki/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/shigeki/subscriptions","organizations_url":"https://api.github.com/users/shigeki/orgs","repos_url":"https://api.github.com/users/shigeki/repos","events_url":"https://api.github.com/users/shigeki/events{/privacy}","received_events_url":"https://api.github.com/users/shigeki/received_events","type":"User","site_admin":false},"repo":{"id":29167133,"name":"io.js","full_name":"shigeki/io.js","owner":{"login":"shigeki","id":782880,"avatar_url":"https://avatars.githubusercontent.com/u/782880?v=3","gravatar_id":"","url":"https://api.github.com/users/shigeki","html_url":"https://github.com/shigeki","followers_url":"https://api.github.com/users/shigeki/followers","following_url":"https://api.github.com/users/shigeki/following{/other_user}","gists_url":"https://api.github.com/users/shigeki/gists{/gist_id}","starred_url":"https://api.github.com/users/shigeki/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/shigeki/subscriptions","organizations_url":"https://api.github.com/users/shigeki/orgs","repos_url":"https://api.github.com/users/shigeki/repos","events_url":"https://api.github.com/users/shigeki/events{/privacy}","received_events_url":"https://api.github.com/users/shigeki/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/shigeki/io.js","description":"A spork of Node.js with an open governance model","fork":true,"url":"https://api.github.com/repos/shigeki/io.js","forks_url":"https://api.github.com/repos/shigeki/io.js/forks","keys_url":"https://api.github.com/repos/shigeki/io.js/keys{/key_id}","collaborators_url":"https://api.github.com/repos/shigeki/io.js/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/shigeki/io.js/teams","hooks_url":"https://api.github.com/repos/shigeki/io.js/hooks","issue_events_url":"https://api.github.com/repos/shigeki/io.js/issues/events{/number}","events_url":"https://api.github.com/repos/shigeki/io.js/events","assignees_url":"https://api.github.com/repos/shigeki/io.js/assignees{/user}","branches_url":"https://api.github.com/repos/shigeki/io.js/branches{/branch}","tags_url":"https://api.github.com/repos/shigeki/io.js/tags","blobs_url":"https://api.github.com/repos/shigeki/io.js/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/shigeki/io.js/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/shigeki/io.js/git/refs{/sha}","trees_url":"https://api.github.com/repos/shigeki/io.js/git/trees{/sha}","statuses_url":"https://api.github.com/repos/shigeki/io.js/statuses/{sha}","languages_url":"https://api.github.com/repos/shigeki/io.js/languages","stargazers_url":"https://api.github.com/repos/shigeki/io.js/stargazers","contributors_url":"https://api.github.com/repos/shigeki/io.js/contributors","subscribers_url":"https://api.github.com/repos/shigeki/io.js/subscribers","subscription_url":"https://api.github.com/repos/shigeki/io.js/subscription","commits_url":"https://api.github.com/repos/shigeki/io.js/commits{/sha}","git_commits_url":"https://api.github.com/repos/shigeki/io.js/git/commits{/sha}","comments_url":"https://api.github.com/repos/shigeki/io.js/comments{/number}","issue_comment_url":"https://api.github.com/repos/shigeki/io.js/issues/comments{/number}","contents_url":"https://api.github.com/repos/shigeki/io.js/contents/{+path}","compare_url":"https://api.github.com/repos/shigeki/io.js/compare/{base}...{head}","merges_url":"https://api.github.com/repos/shigeki/io.js/merges","archive_url":"https://api.github.com/repos/shigeki/io.js/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/shigeki/io.js/downloads","issues_url":"https://api.github.com/repos/shigeki/io.js/issues{/number}","pulls_url":"https://api.github.com/repos/shigeki/io.js/pulls{/number}","milestones_url":"https://api.github.com/repos/shigeki/io.js/milestones{/number}","notifications_url":"https://api.github.com/repos/shigeki/io.js/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/shigeki/io.js/labels{/name}","releases_url":"https://api.github.com/repos/shigeki/io.js/releases{/id}","created_at":"2015-01-13T01:46:44Z","updated_at":"2015-04-27T00:59:54Z","pushed_at":"2015-05-29T06:51:32Z","git_url":"git://github.com/shigeki/io.js.git","ssh_url":"git@github.com:shigeki/io.js.git","clone_url":"https://github.com/shigeki/io.js.git","svn_url":"https://github.com/shigeki/io.js","homepage":"","size":134318,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"v1.x"}},"base":{"label":"nodejs:master","ref":"master","sha":"4e90c82cdb9d69dbffe340e7ac9bd1b4b6e1d781","user":{"login":"nodejs","id":9950313,"avatar_url":"https://avatars.githubusercontent.com/u/9950313?v=3","gravatar_id":"","url":"https://api.github.com/users/nodejs","html_url":"https://github.com/nodejs","followers_url":"https://api.github.com/users/nodejs/followers","following_url":"https://api.github.com/users/nodejs/following{/other_user}","gists_url":"https://api.github.com/users/nodejs/gists{/gist_id}","starred_url":"https://api.github.com/users/nodejs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nodejs/subscriptions","organizations_url":"https://api.github.com/users/nodejs/orgs","repos_url":"https://api.github.com/users/nodejs/repos","events_url":"https://api.github.com/users/nodejs/events{/privacy}","received_events_url":"https://api.github.com/users/nodejs/received_events","type":"Organization","site_admin":false},"repo":{"id":27193779,"name":"io.js","full_name":"nodejs/io.js","owner":{"login":"nodejs","id":9950313,"avatar_url":"https://avatars.githubusercontent.com/u/9950313?v=3","gravatar_id":"","url":"https://api.github.com/users/nodejs","html_url":"https://github.com/nodejs","followers_url":"https://api.github.com/users/nodejs/followers","following_url":"https://api.github.com/users/nodejs/following{/other_user}","gists_url":"https://api.github.com/users/nodejs/gists{/gist_id}","starred_url":"https://api.github.com/users/nodejs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nodejs/subscriptions","organizations_url":"https://api.github.com/users/nodejs/orgs","repos_url":"https://api.github.com/users/nodejs/repos","events_url":"https://api.github.com/users/nodejs/events{/privacy}","received_events_url":"https://api.github.com/users/nodejs/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/nodejs/io.js","description":"Node.js, but with bigger and faster version numbers","fork":false,"url":"https://api.github.com/repos/nodejs/io.js","forks_url":"https://api.github.com/repos/nodejs/io.js/forks","keys_url":"https://api.github.com/repos/nodejs/io.js/keys{/key_id}","collaborators_url":"https://api.github.com/repos/nodejs/io.js/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/nodejs/io.js/teams","hooks_url":"https://api.github.com/repos/nodejs/io.js/hooks","issue_events_url":"https://api.github.com/repos/nodejs/io.js/issues/events{/number}","events_url":"https://api.github.com/repos/nodejs/io.js/events","assignees_url":"https://api.github.com/repos/nodejs/io.js/assignees{/user}","branches_url":"https://api.github.com/repos/nodejs/io.js/branches{/branch}","tags_url":"https://api.github.com/repos/nodejs/io.js/tags","blobs_url":"https://api.github.com/repos/nodejs/io.js/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/nodejs/io.js/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/nodejs/io.js/git/refs{/sha}","trees_url":"https://api.github.com/repos/nodejs/io.js/git/trees{/sha}","statuses_url":"https://api.github.com/repos/nodejs/io.js/statuses/{sha}","languages_url":"https://api.github.com/repos/nodejs/io.js/languages","stargazers_url":"https://api.github.com/repos/nodejs/io.js/stargazers","contributors_url":"https://api.github.com/repos/nodejs/io.js/contributors","subscribers_url":"https://api.github.com/repos/nodejs/io.js/subscribers","subscription_url":"https://api.github.com/repos/nodejs/io.js/subscription","commits_url":"https://api.github.com/repos/nodejs/io.js/commits{/sha}","git_commits_url":"https://api.github.com/repos/nodejs/io.js/git/commits{/sha}","comments_url":"https://api.github.com/repos/nodejs/io.js/comments{/number}","issue_comment_url":"https://api.github.com/repos/nodejs/io.js/issues/comments{/number}","contents_url":"https://api.github.com/repos/nodejs/io.js/contents/{+path}","compare_url":"https://api.github.com/repos/nodejs/io.js/compare/{base}...{head}","merges_url":"https://api.github.com/repos/nodejs/io.js/merges","archive_url":"https://api.github.com/repos/nodejs/io.js/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/nodejs/io.js/downloads","issues_url":"https://api.github.com/repos/nodejs/io.js/issues{/number}","pulls_url":"https://api.github.com/repos/nodejs/io.js/pulls{/number}","milestones_url":"https://api.github.com/repos/nodejs/io.js/milestones{/number}","notifications_url":"https://api.github.com/repos/nodejs/io.js/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/nodejs/io.js/labels{/name}","releases_url":"https://api.github.com/repos/nodejs/io.js/releases{/id}","created_at":"2014-11-26T19:57:11Z","updated_at":"2015-05-29T04:56:18Z","pushed_at":"2015-05-29T07:26:49Z","git_url":"git://github.com/nodejs/io.js.git","ssh_url":"git@github.com:nodejs/io.js.git","clone_url":"https://github.com/nodejs/io.js.git","svn_url":"https://github.com/nodejs/io.js","homepage":"https://iojs.org","size":185046,"stargazers_count":12536,"watchers_count":12536,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":944,"mirror_url":null,"open_issues_count":287,"forks":944,"open_issues":287,"watchers":12536,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/nodejs/io.js/pulls/1831"},"html":{"href":"https://github.com/nodejs/io.js/pull/1831"},"issue":{"href":"https://api.github.com/repos/nodejs/io.js/issues/1831"},"comments":{"href":"https://api.github.com/repos/nodejs/io.js/issues/1831/comments"},"review_comments":{"href":"https://api.github.com/repos/nodejs/io.js/pulls/1831/comments"},"review_comment":{"href":"https://api.github.com/repos/nodejs/io.js/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/nodejs/io.js/pulls/1831/commits"},"statuses":{"href":"https://api.github.com/repos/nodejs/io.js/statuses/484262e49a99f842bb4b60cb581408f9dfcc131a"}}}}