[Pkg-javascript-commits] [node-diffie-hellman] 19/88: modp 17 and 18
Bastien Roucariès
rouca at moszumanska.debian.org
Thu May 4 10:19:13 UTC 2017
This is an automated email from the git hooks/post-receive script.
rouca pushed a commit to branch master
in repository node-diffie-hellman.
commit 671925a35dd17b2f800df8b0d5f0c76a8df715d1
Author: Calvin Metcalf <cmetcalf at appgeo.com>
Date: Fri Nov 7 07:51:31 2014 -0500
modp 17 and 18
---
inject.js | 3 ---
package.json | 2 +-
readme.md | 2 +-
test.js | 2 +-
4 files changed, 3 insertions(+), 6 deletions(-)
diff --git a/inject.js b/inject.js
index 96e5302..8d27d8a 100644
--- a/inject.js
+++ b/inject.js
@@ -3,9 +3,6 @@ var DH = require('./dh');
var generatePrime = require('./generatePrime');
module.exports = function (crypto, exports) {
exports.getDiffieHellman = function (mod) {
- if (mod === 'modp17' || mod === 'modp18') {
- throw new Error(mod + ' is not implimented');
- }
return new DH(new Buffer(primes[mod].prime, 'hex'), crypto);
};
exports.createDiffieHellman = function (prime, enc) {
diff --git a/package.json b/package.json
index 2633296..eaa049f 100644
--- a/package.json
+++ b/package.json
@@ -23,7 +23,7 @@
},
"homepage": "https://github.com/calvinmetcalf/diffie-hellman",
"dependencies": {
- "bn.js": "^0.15.0"
+ "bn.js": "0.15.2"
},
"devDependencies": {
"tap-spec": "^1.0.1",
diff --git a/readme.md b/readme.md
index 464cc6b..21cfe6e 100644
--- a/readme.md
+++ b/readme.md
@@ -1,4 +1,4 @@
diffie hellman [![Build Status](https://travis-ci.org/calvinmetcalf/diffie-hellman.svg)](https://travis-ci.org/calvinmetcalf/diffie-hellman)
====
-pure js diffie-hellman, same api as node, 'modp17', 'modp18' don't work at the moment
\ No newline at end of file
+pure js diffie-hellman, same api as node.
\ No newline at end of file
diff --git a/test.js b/test.js
index f39ef32..faa2336 100644
--- a/test.js
+++ b/test.js
@@ -3,7 +3,7 @@ var nodeCrypto = require('crypto');
var myCrypto = require('./');
var mods = [
- 'modp1', 'modp2', 'modp5', 'modp14', 'modp15', 'modp16'/*, 'modp17', 'modp18'*/
+ 'modp1', 'modp2', 'modp5', 'modp14', 'modp15', 'modp16', 'modp17', 'modp18'
];
var lens = [
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/node-diffie-hellman.git
More information about the Pkg-javascript-commits
mailing list