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

bug: (Rollup example) Hash function used in multiple locations but not Reset properly #1018

Open
Engeloid opened this issue Jan 22, 2024 · 0 comments

Comments

@Engeloid
Copy link

Below it can be seen, that hfunc is used in the Sign() and Verify() function in transfer.go from the rollup example.

sigBin, err := priv.Sign(msg, hFunc)

Now this hash function is defined and initialized in operator.go, where it is being used for different kind of things, i.e., once you want to handle multiple transaction, where you sign/verify multiple transactions while also updating the state (e.g. in a loop where you create a transaction sign it and then update the state), the hash function will have input from previous (operator) operations and throw errors.

My workaround

I fixed this issue by defining another hash function in transfer.go and using that instead of hfunc.

Or was hfunc being used there for a reason? If so, please do enlighten me.

@Engeloid Engeloid changed the title (Rollup example) Hash function used in multiple locations but not Reset properly bug: (Rollup example) Hash function used in multiple locations but not Reset properly Jan 22, 2024
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

No branches or pull requests

1 participant