dusk-network / dusk-pki Goto Github PK
View Code? Open in Web Editor NEWDusk Public Key Infrastructure
License: Mozilla Public License 2.0
Dusk Public Key Infrastructure
License: Mozilla Public License 2.0
Dusk PKI should be the central place that handles Public and Secret Keys; currently the structure are split among this repo and schnorr repo.
The Secret / Public Keys of schnorr should be moved here, and schnorr should relies on dusk-pki to handle the keys โ except for PublicKeyPair
.
Will be possible once dusk-network/Poseidon252#155 is implemented and will allow us to have much less trouble in our circuits when we need to demonstrate that some of our keys are consistently built correctly.
Describe what you want implemented
rkyv
related traits should be implemented for at least StealthAddress
to allow for passing them through the host/VM boundary.
Describe "Why" this is needed
This is necessary to be able to pass these structures to a smart contract running on the virtual machine.
Describe alternatives you've considered
N/A
Additional context
The job of serialization and de-serialization used to be performed by canonical. Due to the increased costs it entailed, we decided to architect the new VM to allow rkyv
able used as transaction arguments.
Describe what you want implemented
Implement constant functions to allow the user to create public keys and stealth addresses as constants
Describe "Why" this is needed
We have some special use-cases for constant one-time keys in Rusk where we need to pad zeroed outputs to transactions in order to satisfy the ZK circuit.
Describe alternatives you've considered
Using runtime calculation for objects that should be constants is cryptic and inefficient
Currently we lack a method to generate both pairs (SecretKey
/ PublicKey
and SecretSpendKey
/ PublicSpendKey
) in one call, as pair.
N/A
N/A
Due to a change in the versions, the tag needs to be changed. This ought to be a minor bump.
Due to large changes in the versions, all dependant imports on BLS and JubJub need to be altered.
Describe what you want implemented
Currently we use Poseidon to compute the hashes involved in the generation of the note keys (stealth address). As these operations always happen out of the circuit, replacing Poseidon by a more efficient hash function (not intended to be computed in-circuit) like Blake2b, would be a better solution.
Describe what you want implemented
Update dusk-poseidon
dependency to 0.23
.
Describe "Why" this is needed
dusk-plonk
0.9
was released with major API improvements and general bug fixes. It is desirable to have these improvements available. dusk-poseidon
0.23
contemplates these features.
Describe alternatives you've considered
N/A
Additional context
N/A
It's starting to be painful and verbose to derive Default
for structures that contain dusk-pki
structs such as StealthAddress
.
So it would be really nice to implement them.
Citadel
requires it for handling the License
struct.
We want to do a rename of the PublicKey
and SecretKey
structures to NotePublicKey
and NoteSecretKey
, respectively, as well as rename the PublicSpendKey
and SecretSpendKey
to PublicKey
and SecretKey
, respectively.
This is to better reflect their usage in our transaction model, and avoid any confusion when comparing documentation with this code.
N/A
The ideal situation would be that this repository would be independent of phoenix
. This is, however, already not the case, since we use words like "Spend" and offer functionality such as SecretSpendKey::sk_r
, which are clearly designed for use by phoenix
.
For Citadel, we need StealthAddress to derive Default.
dusk-pki
is importing jubjub
without default-features=false
. This cause the dependencies of pki
to break for no-std
environments
As result of the first day of Zedger Work Week we agreed on deprecate this repository in favor of Make dusk-schnorr
the equivalent of bls12_381-sign for Jubjub curve and Add Phoenix protocol's related keys.
See the links above.
We first split the keys in two domain based on the curve field: Jubjub
and bls12_381
. Then we notice that where the bls12_381-sign contains both the keys definition, and the signature's algorithm, for the Jubjub
field that was split in two: dusk-pki, that contains the keys definition, and dusk-schnorr that contains the signature's algorithm.
Therefore we decided to move the "Jubjub keys" together with the algorithm (see []). At that point the only keys left here were related to phoenix, so we decided to move them there: at this point this repo become obsolete and should be deprecated.
subtle
should use flag default-features=false
to not break no-std
dependencies
This library should be included in the wallet add-on and therefore we should be able to compile it as WASM.
The README.md shouldn't be empty and probably we should have a more descriptive docs as well
Add a badge that marks this repository as deprecated
on crates.io
All keys moved into either dusk-schnorr
or phoenix-core
:
Key | new location |
---|---|
SecretKey |
dusk_schnorr::NoteSecretKey |
PublicKey |
dusk_schnorr::NotePublicKey |
SecretSpendKey |
phoenix_core::SecretKey |
PublicSpendKey |
phoenix_core::PublicKey |
StealthAddress |
phoenix_core::StealthAddress |
ViewKey |
phoenix_core::ViewKey |
We need to fix the master
branch since it's not compiling and that's a dependency for a lot of repos that is causing failures.
Since we've been mainly focused on have the contracts working with PoseidonTrees inside, we have left appart the repos that were not taking part in the contract. And one of them is dusk-pki.
Therefore, we need to update it's dependencies. We also need to enable a no_std compilation for the main structures exported and finally check that the canon features adapt nicely to that.
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.