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

Switch to use secp256k1 native bindings for signing #100

Open
wants to merge 4 commits into
base: 1.0.0
Choose a base branch
from

Conversation

braydonf
Copy link
Contributor

@braydonf braydonf commented Sep 13, 2016

Switches to use libsecp256k1 for transactions signing, with secp256k1 as an optional dependency.

@braydonf braydonf added this to the 1.0.0 milestone Sep 13, 2016
@@ -10,6 +10,13 @@ var BufferUtil = require('../util/buffer');
var _ = require('lodash');
var $ = require('../util/preconditions');

var secp256k1 = null;
try {
secp256k1 = require('secp' + '256k1');
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

secp256k1 = require('secp256k1/bindings') should work also

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just tried running this with this build: https://travis-ci.org/bitpay/bitcore-lib/builds/160276007 and there still seems to be an issue with browserify.

@@ -124,7 +124,7 @@ describe('ECDSA', function() {
});

describe('#toPublicKey', function() {
it('should calculate the correct public key', function() {
it.skip('should calculate the correct public key', function() {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why are some tests skipped?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can't remember if the test wasn't passing because it was a case that wasn't able to test, or if there was an issue.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants