-
Notifications
You must be signed in to change notification settings - Fork 136
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
Security and zkApps #921
Security and zkApps #921
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
1 Ignored Deployment
|
@@ -43,7 +43,7 @@ function knowsPreimage(preimage: Field) { | |||
} | |||
|
|||
const expectedHash = | |||
Field(0x1d444102d9e8da6d566467defcc446e8c1c3a3616d059facadbfd674afbc37ecn); | |||
0x1d444102d9e8da6d566467defcc446e8c1c3a3616d059facadbfd674afbc37ecn; |
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.
0x1d444102d9e8da6d566467defcc446e8c1c3a3616d059facadbfd674afbc37ecn; | |
'0x1d444102d9e8da6d566467defcc446e8c1c3a3616d059facadbfd674afbc37ecn'; |
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.
Should this be a string?
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.
no, bigint literal!
docs/zkapps/secure-zkapps.mdx
Outdated
|
||
### Creating an insecure contract | ||
|
||
We need to use either `assertCanMint()` or `assertCanBurn()`, but how do we know which one? Well, let's just add a parameter to the method that tells us whether this is a mint or a burn. Then let's call the appropriate method based on that parameter. Github Copilot fills this out nicely for us: |
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.
"Github Copilot fills this out nicely" - LOL
Otherwise, LGTM |
This adds a new section under "Creating zkApps", called "Security and zkApps".
Topics covered:
I didn't get to write a final section on considerations in low-level circuit writing. This is its whole own can of worms and will need some work to present well.
In addition, this adds a small section on the o1js intro page to host our internal audit and future audits of o1js.