Crate phoenix_core

Source
Expand description

Phoenix’s Core library types and behaviors

Modules§

aes
AES symmetric cipher

Structs§

Note
Phoenix Note struct
PublicKey
Public pair of a·G and b·G defining a PublicKey
SecretKey
Secret pair of a and b defining a SecretKey
StealthAddress
To obfuscate the identity of the participants, we utilizes a Stealth Address system. A StealthAddress is composed by a one-time note-public-key (the actual address) and a random point R.
TxSkeleton
Transaction Skeleton used by the phoenix transaction model A phoenix transaction, referred to as tx-skeleton in the specs.
ViewKey
Pair of a secret a and public b·G

Enums§

Error
All possible errors for Phoenix’s Core
NoteType
The types of a Note
Sender
The sender of the Note. This can be either the encrypted sender’s PublicKey, if the Note was created as an output note of a phoenix-transaction, or some contract-data if the Note was created in another way, e.g. by withdrawing from a contract.

Constants§

NOTE_VAL_ENC_SIZE
Size of the Phoenix notes value_enc
OUTPUT_NOTES
The number of output notes in a transaction

Functions§

hash
Hashes a JubJub’s ExtendedPoint into a JubJub’s Scalar using the JubJub’s hash to scalar function
transparent_value_commitment
Use the pedersen commitment scheme to compute a transparent value commitment.
value_commitment
Use the pedersen commitment scheme to compute a value commitment using a blinding-factor.