Skip to content
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

Add access permission to accounts #500

Merged
merged 28 commits into from
Jan 18, 2023
Merged

Conversation

mitschabaude
Copy link
Member

@mitschabaude mitschabaude commented Oct 20, 2022

* all other permissions combined. For normal accounts it can safely be set to `none`, but for token contracts this has to be more restrictive, to
* prevent unauthorized token interactions -- for example, it could be `proofOrSignature`.
*/
access: Permission;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Any thoughts on how we default this to non-none somehow when working with tokens? Happy path needs to be the secure one

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We could export a TokenContract which is SmartContract but with defaults changed to be secure for token contracts

And have all our examples and docs for tokens point to this

@mitschabaude mitschabaude changed the base branch from main to berkeley November 16, 2022 20:41
@mitschabaude mitschabaude marked this pull request as ready for review November 21, 2022 09:14
@mitschabaude
Copy link
Member Author

Not ready for merge yet! Still has tests failing, revealed by this manual run: https://github.com/o1-labs/snarkyjs/actions/runs/3524467107/jobs/5909909541

@mitschabaude
Copy link
Member Author

mitschabaude commented Jan 13, 2023

now that the Mina companion is merged, this needs updated bindings from develop, and to be merged

@mitschabaude mitschabaude merged commit d26e963 into berkeley Jan 18, 2023
@mitschabaude mitschabaude deleted the feature/add-access-permission branch January 18, 2023 18:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants