raiden
raiden copied to clipboard
Make sure that proxies have checks for all `assert()` and `require()` in TokenNetworkRegistry
This is a part of #4763.
The TokenNetworkRegistry version to go through is this: https://github.com/raiden-network/raiden-contracts/blob/7c1f1da47ae1b02c00f6388bb7be341c3fed3160/raiden_contracts/data/source/raiden/TokenNetworkRegistry.sol
Does the client ever call the constructor of TokenNetworkRegistry? Asked https://ethereum.stackexchange.com/questions/74800/does-the-raiden-client-ever-deploy-tokennetworkregistry.
createERC20TokenNetwork() has a modifier canCreateTokenNetwork.
https://github.com/raiden-network/raiden-contracts/blob/7c1f1da47ae1b02c00f6388bb7be341c3fed3160/raiden_contracts/data/source/raiden/TokenNetworkRegistry.sol#L76
Is this accounted in the proxy? No https://github.com/raiden-network/raiden/issues/4795
Suspended till I understand the norm. https://github.com/raiden-network/raiden/issues/4828
Also stuck on https://github.com/raiden-network/raiden/issues/4829
Also stuck on https://github.com/raiden-network/raiden/issues/4830
createERC20TokenNetwork() calls the constructor of TokenNetwork. The constructor has
- [ ] a check that the token address is not zero https://github.com/raiden-network/raiden/issues/4875
- [ ] a check that the secret registry address is not zero https://github.com/raiden-network/raiden/issues/4882
- [ ] a check that the deprecation executor address is not zero https://github.com/raiden-network/raiden/issues/4884
- [ ] a check that the chain_id is not zero #4886
- [ ] a check that the settlement_timeout_min is not zero https://github.com/raiden-network/raiden/issues/4888
- [ ] a check that the settlement_timeout_max is more than the settlement_timeout_min https://github.com/raiden-network/raiden/issues/4889
- [x] why cannot they be equal? https://github.com/raiden-network/raiden-contracts/issues/1225
- [ ] token address has nonempty code
- [ ] secret registry address has nonempty code
- [ ] channel_participant_deposit_limit is not zero
- [ ] token_network_deposit_limit is not zero
- [ ] token_network_deposit_limit is at least channel_participant_deposit_limit
- [ ] token.total_supply is not zero
I've unassigned myself because I have some bottleneck work in the smart contracts.
Now that we have revert error messages, I would prefer to rely on the errors from the contract call in most cases rather then relying on correctly duplicating the logic.