elliptic icon indicating copy to clipboard operation
elliptic copied to clipboard

Fast Elliptic Curve Cryptography in plain javascript

Results 103 elliptic issues
Sort by recently updated
recently updated
newest added

Hello, thanks for a very nice library! I'm trying to get interop working with Java/Clojure but the Java side seems to think the public key point is off the curve....

1. elliptic uses [bn.js](https://github.com/indutny/bn.js). You can generate number with [crypto.randomBytes](https://nodejs.org/api/crypto.html#crypto_crypto_randombytes_size_callback) and then check interval (0, n). Or you can use `.getKeyPair()` 2. `new EC('curve25519').g.mul` 3. You're right. _Originally posted by...

Working with `ed25519` curve I've faced with strange behaviour: `decodePoint` doesn't fails on points out of field. ```js import elliptic from 'elliptic'; const ec = new elliptic.eddsa('ed25519'); const point =...

In addition to change in bn.js PR: https://github.com/indutny/bn.js/pull/267

Current implementation allows to decode any number even more `n` or even more than 32 bit number. https://github.com/indutny/elliptic/blob/43ac7f230069bd1575e1e4a58394a512303ba803/lib/elliptic/utils.js#L115-L117 Maybe method should fails or number be reduce by `n` by default?

Feature request: add `endian` (`le` or `be`) argument to bn.js `toString` method. Motivation: working with `ed25519` curve from `elliptic` module there is an inconvenience. Issue in bn.js repo: https://github.com/indutny/bn.js/issues/272

EDDSA `decodePoint` method doesn't support Buffer as argument. ```js import elliptic from 'elliptic'; const ec = new elliptic.eddsa('ed25519'); const point = ec.decodePoint(Buffer.from('bd85a61bae0c101d826cbed54b1290f941d26e70607a07fc6f0ad611eb8f70a6', 'hex)); // Throws error /node_modules/elliptic/lib/elliptic/eddsa/index.js:104 var normed =...

https://github.com/indutny/elliptic/issues/191 (`elliptic` need bump to 6.6.0) Also need `remove package-lock.json` OR `update package-lock.json`. Depends from: https://github.com/indutny/asn1.js/pull/118 https://github.com/crypto-browserify/browserify-rsa/pull/13 https://github.com/crypto-browserify/browserify-sign/pull/47 https://github.com/crypto-browserify/createECDH/pull/15 https://github.com/crypto-browserify/diffie-hellman/pull/32 https://github.com/indutny/miller-rabin/pull/11 https://github.com/crypto-browserify/publicEncrypt/pull/20

In short weierstrass curves, the member `curve.n` is missing `_move` from its prototype: ```javascript var BN = require('bn.js') var EC = require('elliptic') var curve = new EC.ec('secp256k1'); // e.g.---same problem...

Can I decrypt the signature to original message using this library? I use this for encryption: ``` var EC = require('elliptic').ec; var ec = new EC('secp256k1'); var msg = "hello";...