dalek-cryptography / doppio Goto Github PK
View Code? Open in Web Editor NEWEmbedded curve over the Ristretto255 scalar field, for use in Bulletproofs
License: BSD 3-Clause "New" or "Revised" License
Embedded curve over the Ristretto255 scalar field, for use in Bulletproofs
License: BSD 3-Clause "New" or "Revised" License
Make an AllocatedPoint
type which has:
As seen on the code of field.rs
, inverse()
FieldElement function implementation remains unimplemented.
On dusk-network/dusk-zerocaf#12 we've just implemented the Kalinski's Montgomery Modular Inverse algorithm for the Doppio's FieldElement mod 2^252 + 27742317777372353535851937790883648493
(prime of the field).
So maybe I can make a PR with the implementation of the Inverse operation and the proper tests and doc comments if it's useful.
References:
B. S. Kaliski Jr. - The Montgomery inverse and its applica-tions.
IEEE Transactions on Computers, 44(8):1064–1065, August-1995.
Montgomery inversion - Erkay Sava ̧s & Çetin Kaya Koç
J Cryptogr Eng (2018) 8:201–210
https://doi.org/10.1007/s13389-017-0161-x
See curve25519 scalar field arithmetic for reference:
https://github.com/dalek-cryptography/curve25519-dalek/blob/master/src/backend/serial/u64/scalar.rs
Implement point operations over doppio points, which are represented as AllocatedPoint
s. Each operation will take the input AllocatedPoints
and the constraint system (if the AllocatedPoint
doesn't store a reference to a constraint system?), and allocate new constraints that enforce that the operation is valid. Also it would allocate new variables that represent the result of the operation, and make assignments to the variables.
Implement (doppio curve point) * (scalar)
Curve parameters given here: https://twitter.com/ebfull/status/1087571257057406976
Can use the addition and subtraction formulas (unoptimized) out of HWCD: https://eprint.iacr.org/2008/522
Probably makes sense to use projective coordinates, for machine (non-circuit) performance
Unsure if this is necessary (maybe it's enough to just do point operations over the doppio points, without a doppio scalar field?). Also unsure what this scalar field would look like.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.