Coder Social home page Coder Social logo

p256 about noble-secp256k1 HOT 13 CLOSED

paulmillr avatar paulmillr commented on May 21, 2024
p256

from noble-secp256k1.

Comments (13)

paulmillr avatar paulmillr commented on May 21, 2024

No.

Jacobian point (xyz) multiplication is specific to curve with a=0 (secp256k1). You will need to adjust JacobianPoint#double and #add methods.

See hyperelliptic.org for those formulas. They should be fairly straightforward to implement.

https://www.hyperelliptic.org/EFD/g1p/auto-shortw-jacobian.html

As soon as you adjust those, check if USE_ENDOMORPHISM is automatically set to false, because endomorphism is specific to koblitz curves. The code already supports no-endo case.

from noble-secp256k1.

sublimator avatar sublimator commented on May 21, 2024

Thanks, was looking like that might be the case.
Was thrown by this line: https://github.com/paulmillr/noble-secp256k1/blob/master/index.ts#L48
Nice article and lib! You thought of supporting some other curves for ecdsa ?

from noble-secp256k1.

paulmillr avatar paulmillr commented on May 21, 2024

Right now i’m finalizing bls12-381, a nice pairing-friendly curve. It allows to verify 1000 signatures at a cost of verifying one signature, so it’s awesome.

It would be great to implement ed448, but haven’t had time to do this yet.

As for nist curves, they are implemented almost everywhere natively, so not seeing personal need for those.

from noble-secp256k1.

sublimator avatar sublimator commented on May 21, 2024

they are implemented almost everywhere natively

Right, I was porting https://github.com/privacypass/challenge-bypass-extension from sjcl to elliptic/bn.js as a way of learning more about the privacypass protocol and ECC.

Web crypto ("native" in the browser context) doesn't seem to expose any of the scalar multiplication primitives, only signing/verifying operations etc.

not seeing personal need for those

Fair :)

from noble-secp256k1.

paulmillr avatar paulmillr commented on May 21, 2024

Nice! It’s very useful extension. I hate those captchas & cloudflare. What operations are required in privacypass? I guess, ECDH?

from noble-secp256k1.

sublimator avatar sublimator commented on May 21, 2024

from noble-secp256k1.

sublimator avatar sublimator commented on May 21, 2024

https://github.com/privacypass/challenge-bypass-extension/blob/master/docs/HASH_TO_CURVE.md#affine-sswu-method

from noble-secp256k1.

paulmillr avatar paulmillr commented on May 21, 2024

As for hash-to-curve, take a look at my bls12-381 repo. I have been working on applying the exact same standard to the curve for the last couple weeks. It can be reused for p256.

from noble-secp256k1.

sublimator avatar sublimator commented on May 21, 2024

from noble-secp256k1.

paulmillr avatar paulmillr commented on May 21, 2024

Do you have this working somewhere?

from noble-secp256k1.

sublimator avatar sublimator commented on May 21, 2024

No, I've moved onto other things for the moment. The existing sjcl impl is working so it's hard to justify the time just at the moment.

Do you have this working somewhere?

Do you ?? :)

from noble-secp256k1.

sublimator avatar sublimator commented on May 21, 2024

Elliptic seems too slow with p256 curve ops so it's either improve that or modify this. Both would need auditing by people more knowledgeable than me.

from noble-secp256k1.

paulmillr avatar paulmillr commented on May 21, 2024

p256 is available in https://github.com/paulmillr/noble-curves

from noble-secp256k1.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.