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

Feature/erc20 #13

Closed
wants to merge 7 commits into from
Closed

Conversation

davidp94
Copy link

Added ERC20 support instead of erc.

Contract is available in Miximus_ERC20.sol

miximusTrees[_erc20Address].instantiated = true;
}
require(miximusTrees[_erc20Address].ercInstance.transferFrom(msg.sender, address(this), 1));
insert(leaf);
Copy link
Author

Choose a reason for hiding this comment

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

@barryWhiteHat I don't know how I should modify that in order to have one MerkelTree per miximusTree

Copy link
Author

Choose a reason for hiding this comment

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

maybe putting the MTree structure into the miximusTree such as

struct MiximusTree {
        ERC20 ercInstance;
        bool instantiated;
        mapping (bytes32 => bool) roots;
        mapping (bytes32 => bool) nullifiers;
        Mtree mtree;
    }

?

Copy link
Owner

Choose a reason for hiding this comment

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

Yes i think that will work.

@HarryR
Copy link

HarryR commented Jul 9, 2018

Is it possible to split the proving & merkle code into a separate common library which is used by both the Ether and Token contracts?

@barryWhiteHat
Copy link
Owner

@HarryR I am not sure what you mean? Do you mean the reuse the zksnark witness generation for both? Or do you mean remove the getMerkelProof function from solidity and implement it in python ?

@davidp94
Copy link
Author

Moved to #29

@davidp94 davidp94 closed this Jul 16, 2018
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.

3 participants