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

feat: Merkle tree length checks and other optimizations #372

Merged
merged 8 commits into from
Jan 31, 2023

Conversation

0xJurassicPunk
Copy link
Contributor

@0xJurassicPunk 0xJurassicPunk commented Jan 30, 2023

This PR adds:

  • gas optimizations for Merkle tree libraries
  • adds a length check for the Merkle tree calldata verification library (to prevent very large merkle trees signed by user)

@0xJurassicPunk 0xJurassicPunk self-assigned this Jan 30, 2023
@0xJurassicPunk 0xJurassicPunk changed the title perf: Gas optimization perf: Merkle tree optimization Jan 30, 2023
@0xJurassicPunk 0xJurassicPunk changed the title perf: Merkle tree optimization feat: Merkle tree length checks and other optimizations Jan 31, 2023
@0xJurassicPunk 0xJurassicPunk marked this pull request as ready for review January 31, 2023 01:48
@0xJurassicPunk
Copy link
Contributor Author

0xhiroshi I'll update the OrderValidatorV2A once this one is merged. #376

bytes memory signature = _signMerkleProof(merkleTree, makerUserPK);

// Verify validity
// TODO
Copy link
Collaborator

Choose a reason for hiding this comment

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

@0xJurassicPunk what is this supposed to be

OrderStructs.TakerBid memory takerBid = OrderStructs.TakerBid(
takerUser,
makerAsk.minPrice,
makerAsk.itemIds,
Copy link
Collaborator

Choose a reason for hiding this comment

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

There is going to be a merge conflict with the taker struct refactor

@0xJurassicPunk 0xJurassicPunk merged commit 8de425d into LooksRare:master Jan 31, 2023
@0xJurassicPunk 0xJurassicPunk deleted the updates-merkle-proof branch January 31, 2023 10:00
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.

2 participants