-
Notifications
You must be signed in to change notification settings - Fork 42
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
More functions to simplify wawaka contract development #348
Conversation
…tion Two new classes of functions for the Wawaka common library: * Secrets -- simplify (and standardize) generating messages that can be shared between contracts; a message is encrypted with the contracts encryption key. * Attestation -- wrappers for the sgx report verification and processing functions Signed-off-by: Mic Bowman <[email protected]>
There are several methods that are common to many contracts. This update provides a base implementation for those methods in order to simplify contract development. Add common contracts methods for attestations Provides a wrapper for managing attested contract endpoints. Contract object provides an attestation package that is verified registering the encryption & verification keys for the contract. Useful for building contracts that share secrets. Signed-off-by: Mic Bowman <[email protected]>
Replace the code in the attestation test with calls packaged in the attestation common contract code. Complete the implementation of the send/recv secret. Complete testing of the new methods. Signed-off-by: Mic Bowman <[email protected]>
bc62e11
to
f5d3438
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.
I mostly have comments about naming functions to be a bit more precise/descriptive, but the implementation LGTM.
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.
Mostly some clarifying questions
Mostly added comments and adjusted permissions on some of the methods in the attestation contract. Changed the code metadata to return the code hash. In theory that change isn't necessary but it does make things easier for some contracts. Signed-off-by: Mic Bowman <[email protected]>
93119f2
to
e5f9ca0
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.
clear for me!
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
Two new classes of functions for the Wawaka common library:
Add library of common wawaka contract methods.
There are several methods that are common to many contracts. This update provides a base implementation for those methods in order to simplify contract development.
Add common contracts methods for attestations. Provides a wrapper for managing attested contract endpoints. Contract object provides an attestation package that is verified registering the encryption & verification keys for the contract. Useful for building contracts that share secrets.
Update attestation test to use the new helpers. Replace the code in the attestation test with calls packaged in the attestation common contract code. Complete the implementation of the send/recv secret. Complete testing of the new methods.