-
Notifications
You must be signed in to change notification settings - Fork 474
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Feature] Authorized Proving for Public Transfers #775
base: mainnet
Are you sure you want to change the base?
[Feature] Authorized Proving for Public Transfers #775
Conversation
6b78875
to
f5481a7
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, except for a minor nitpick about serde.
} | ||
} | ||
|
||
impl Serialize for Authorized { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Instead of manually implementing Serialize/Deserialize, it would be better to use attributes to control the serialization:
#[derive(Serialize, Deserialize)]
pub(crate) struct Authorized {
/// The authorization for the main function execution.
function: AuthorizationNative,
/// The authorization for the fee execution.
#[serde(default)]
#[serde(skip_serializing_if = "Option::is_none")]
fee: Option<AuthorizationNative>,
/// Whether to broadcast the transaction.
broadcast: bool,
}
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yep you're %100 right
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Replace "delegate" -> "authorize"
Co-authored-by: Collin Chin <[email protected]> Signed-off-by: Mike Turner <[email protected]>
Co-authored-by: Collin Chin <[email protected]> Signed-off-by: Mike Turner <[email protected]>
Is it possible to extend this PR to support proof delegation for arbitrary function calls with public inputs? |
Motivation
This PR adds the ability to authorize public transfers and delegate the proving to the Aleo Network. This extremely short client-side proving times by enabling delegation of compute-heavy proof computations to the Aleo Network. This is only enabled for public transfers as all information in public transfers is posted as public knowledge on the Aleo blockchain.
Note: This does not integrate this functionality into Aleo.tools. This requires a proper UI design and will be worked in later.
Test Plan