eth-address-index

signed metadata declarations for ethereum addresses
Log | Files | Refs

commit 4095c28221b64fe23fe67e0ba23562aa8d472f3e
parent 24a23e97b3ae8887a59cc5eebb1c8b7cfe274782
Author: nolash <dev@holbrook.no>
Date:   Sun, 21 Mar 2021 10:21:23 +0100

Rehabilitate token index

Diffstat:
Mpython/eth_address_declarator/data/AddressDeclarator.bin | 4++--
Mpython/eth_token_index/data/TokenUniqueSymbolIndex.bin | 4++--
Mpython/eth_token_index/data/TokenUniqueSymbolIndex.json | 2+-
Mpython/eth_token_index/index.py | 151+++++++++++++++++++++++++++++++++++++++++++++++++++++++++----------------------
Apython/requirements.txt | 1+
Mpython/setup.cfg | 3++-
Mpython/test_requirements.txt | 1+
Mpython/tests/test_tokenindex.py | 166++++++++++++++++++++++++++++++-------------------------------------------------
Msolidity/AddressDeclarator.bin | 4++--
Msolidity/TokenUniqueSymbolIndex.bin | 4++--
Msolidity/TokenUniqueSymbolIndex.json | 2+-
Msolidity/TokenUniqueSymbolIndex.sol | 5++---
12 files changed, 188 insertions(+), 159 deletions(-)

diff --git a/python/eth_address_declarator/data/AddressDeclarator.bin b/python/eth_address_declarator/data/AddressDeclarator.bin @@ -1 +1 @@ -60806040523480156200001157600080fd5b5060405162001d0b38038062001d0b8339818101604052810190620000379190620007a7565b6060336000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550600581908060018154018082558091505060019003906000526020600020016000909190919091509080519060200190620000b69291906200071f565b5060056001600580549050620000cd9190620008ce565b8154811062000105577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b90600052602060002001434090806001815401808255809150506001900390600052602060002001600090919091909150556200015233836200015b640100000000026401000000009004565b50505062000a5f565b600080606060006200017d3387620003c5640100000000026401000000009004565b92506002600084815260200190815260200160002054905060008114156200031e57600360008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020339080600181540180825580915050600190039060005260206000200160009091909190916101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506005829080600181540180825580915050600190039060005260206000200160009091909190915090805190602001906200027c9291906200071f565b50600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020869080600181540180825580915050600190039060005260206000200160009091909190916101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055505b6001600580549050620003329190620008ce565b90508060026000858152602001908152602001600020819055506005818154811062000387577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b906000526020600020018590806001815401808255809150506001900390600052602060002001600090919091909150556001935050505092915050565b6000806000602867ffffffffffffffff8111156200040c577f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040519080825280601f01601f1916602001820160405280156200043f5781602001600182028036833780820191505090505b50905060008560405160200162000457919062000825565b604051602081830303815290604052905060005b60148110156200057857818181518110620004af577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60200101517f010000000000000000000000000000000000000000000000000000000000000090047f01000000000000000000000000000000000000000000000000000000000000000283828151811062000533577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535080806200056f9062000987565b9150506200046b565b50846040516020016200058c919062000825565b604051602081830303815290604052905060005b6014811015620006bb57818181518110620005e4577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60200101517f010000000000000000000000000000000000000000000000000000000000000090047f010000000000000000000000000000000000000000000000000000000000000002836014836200063e919062000871565b8151811062000676577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053508080620006b29062000987565b915050620005a0565b50600282604051620006ce919062000842565b602060405180830381855afa158015620006ec573d6000803e3d6000fd5b5050506040513d601f19601f82011682018060405250810190620007119190620007a7565b925082935050505092915050565b8280548282559060005260206000209081019282156200075e579160200282015b828111156200075d57825182559160200191906001019062000740565b5b5090506200076d919062000771565b5090565b5b808211156200078c57600081600090555060010162000772565b5090565b600081519050620007a18162000a45565b92915050565b600060208284031215620007ba57600080fd5b6000620007ca8482850162000790565b91505092915050565b620007e8620007e28262000909565b620009d5565b82525050565b6000620007fb826200085b565b62000807818562000866565b93506200081981856020860162000951565b80840191505092915050565b6000620008338284620007d3565b60148201915081905092915050565b6000620008508284620007ee565b915081905092915050565b600081519050919050565b600081905092915050565b60006200087e8262000947565b91506200088b8362000947565b9250827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff03821115620008c357620008c2620009fd565b5b828201905092915050565b6000620008db8262000947565b9150620008e88362000947565b925082821015620008fe57620008fd620009fd565b5b828203905092915050565b6000620009168262000927565b9050919050565b6000819050919050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000819050919050565b60005b838110156200097157808201518184015260208101905062000954565b8381111562000981576000848401525b50505050565b6000620009948262000947565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff821415620009ca57620009c9620009fd565b5b600182019050919050565b6000620009e282620009e9565b9050919050565b6000620009f68262000a2c565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006c0100000000000000000000000082029050919050565b62000a50816200091d565b811462000a5c57600080fd5b50565b61129c8062000a6f6000396000f3fe608060405234801561001057600080fd5b50600436106100bb576000357c0100000000000000000000000000000000000000000000000000000000900480638c661b36116100835780638c661b361461018a5780638da5cb5b146101ba578063ae47ece0146101d8578063d0e95db114610208578063ff7496b414610238576100bb565b806301ffc9a7146100c057806322168e4f146100f057806350e0c6d3146101205780637d64bf1d14610150578063880ad0af14610180575b600080fd5b6100da60048036038101906100d59190610d2c565b610268565b6040516100e79190610f49565b60405180910390f35b61010a60048036038101906101059190610cc7565b61026f565b6040516101179190610f0c565b60405180910390f35b61013a60048036038101906101359190610c26565b61031b565b6040516101479190610f9f565b60405180910390f35b61016a60048036038101906101659190610cc7565b610367565b6040516101779190610f0c565b60405180910390f35b610188610413565b005b6101a4600480360381019061019f9190610c4f565b61044e565b6040516101b19190610f27565b60405180910390f35b6101c2610512565b6040516101cf9190610f0c565b60405180910390f35b6101f260048036038101906101ed9190610c8b565b610536565b6040516101ff9190610f49565b60405180910390f35b610222600480360381019061021d9190610c26565b610789565b60405161022f9190610f9f565b60405180910390f35b610252600480360381019061024d9190610d55565b6107d5565b60405161025f9190610f64565b60405180910390f35b6000919050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002082815481106102e8577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b9060005260206000200160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905092915050565b6000600160008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805490509050919050565b6000600360008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002082815481106103e0577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b9060005260206000200160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905092915050565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161044590610f7f565b60405180910390fd5b606060008061045d8585610812565b915060026000838152602001908152602001600020549050600581815481106104af577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b9060005260206000200180548060200260200160405190810160405280929190818152602001828054801561050357602002820191906000526020600020905b8154815260200190600101908083116104ef575b50505050509250505092915050565b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b600080606060006105473387610812565b92506002600084815260200190815260200160002054905060008114156106e557600360008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020339080600181540180825580915050600190039060005260206000200160009091909190916101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550600582908060018154018082558091505060019003906000526020600020016000909190919091509080519060200190610643929190610b53565b50600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020869080600181540180825580915050600190039060005260206000200160009091909190916101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055505b60016005805490506106f79190611070565b90508060026000858152602001908152602001600020819055506005818154811061074b577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b906000526020600020018590806001815401808255809150506001900390600052602060002001600090919091909150556001935050505092915050565b6000600360008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805490509050919050565b600582815481106107e557600080fd5b9060005260206000200181815481106107fd57600080fd5b90600052602060002001600091509150505481565b6000806000602867ffffffffffffffff811115610858577f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040519080825280601f01601f19166020018201604052801561088a5781602001600182028036833780820191505090505b5090506000856040516020016108a09190610eda565b604051602081830303815290604052905060005b60148110156109bb578181815181106108f6577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60200101517f010000000000000000000000000000000000000000000000000000000000000090047f010000000000000000000000000000000000000000000000000000000000000002838281518110610979577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535080806109b390611155565b9150506108b4565b50846040516020016109cd9190610eda565b604051602081830303815290604052905060005b6014811015610af457818181518110610a23577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60200101517f010000000000000000000000000000000000000000000000000000000000000090047f01000000000000000000000000000000000000000000000000000000000000000283601483610a7b919061101a565b81518110610ab2577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053508080610aec90611155565b9150506109e1565b50600282604051610b059190610ef5565b602060405180830381855afa158015610b22573d6000803e3d6000fd5b5050506040513d601f19601f82011682018060405250810190610b459190610d03565b925082935050505092915050565b828054828255906000526020600020908101928215610b8f579160200282015b82811115610b8e578251825591602001919060010190610b73565b5b509050610b9c9190610ba0565b5090565b5b80821115610bb9576000816000905550600101610ba1565b5090565b600081359050610bcc8161120a565b92915050565b600081359050610be181611221565b92915050565b600081519050610bf681611221565b92915050565b600081359050610c0b81611238565b92915050565b600081359050610c208161124f565b92915050565b600060208284031215610c3857600080fd5b6000610c4684828501610bbd565b91505092915050565b60008060408385031215610c6257600080fd5b6000610c7085828601610bbd565b9250506020610c8185828601610bbd565b9150509250929050565b60008060408385031215610c9e57600080fd5b6000610cac85828601610bbd565b9250506020610cbd85828601610bd2565b9150509250929050565b60008060408385031215610cda57600080fd5b6000610ce885828601610bbd565b9250506020610cf985828601610c11565b9150509250929050565b600060208284031215610d1557600080fd5b6000610d2384828501610be7565b91505092915050565b600060208284031215610d3e57600080fd5b6000610d4c84828501610bfc565b91505092915050565b60008060408385031215610d6857600080fd5b6000610d7685828601610c11565b9250506020610d8785828601610c11565b9150509250929050565b6000610d9d8383610e3c565b60208301905092915050565b610db2816110a4565b82525050565b610dc9610dc4826110a4565b61119e565b82525050565b6000610dda82610fca565b610de48185610fed565b9350610def83610fba565b8060005b83811015610e20578151610e078882610d91565b9750610e1283610fe0565b925050600181019050610df3565b5085935050505092915050565b610e36816110b6565b82525050565b610e45816110c2565b82525050565b610e54816110c2565b82525050565b6000610e6582610fd5565b610e6f8185610ffe565b9350610e7f818560208601611122565b80840191505092915050565b6000610e98601783611009565b91507f6f776e65722063616e6e6f74206265206368616e6765640000000000000000006000830152602082019050919050565b610ed481611118565b82525050565b6000610ee68284610db8565b60148201915081905092915050565b6000610f018284610e5a565b915081905092915050565b6000602082019050610f216000830184610da9565b92915050565b60006020820190508181036000830152610f418184610dcf565b905092915050565b6000602082019050610f5e6000830184610e2d565b92915050565b6000602082019050610f796000830184610e4b565b92915050565b60006020820190508181036000830152610f9881610e8b565b9050919050565b6000602082019050610fb46000830184610ecb565b92915050565b6000819050602082019050919050565b600081519050919050565b600081519050919050565b6000602082019050919050565b600082825260208201905092915050565b600081905092915050565b600082825260208201905092915050565b600061102582611118565b915061103083611118565b9250827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff03821115611065576110646111c2565b5b828201905092915050565b600061107b82611118565b915061108683611118565b925082821015611099576110986111c2565b5b828203905092915050565b60006110af826110f8565b9050919050565b60008115159050919050565b6000819050919050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000819050919050565b60005b83811015611140578082015181840152602081019050611125565b8381111561114f576000848401525b50505050565b600061116082611118565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff821415611193576111926111c2565b5b600182019050919050565b60006111a9826111b0565b9050919050565b60006111bb826111f1565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006c0100000000000000000000000082029050919050565b611213816110a4565b811461121e57600080fd5b50565b61122a816110c2565b811461123557600080fd5b50565b611241816110cc565b811461124c57600080fd5b50565b61125881611118565b811461126357600080fd5b5056fea2646970667358221220b195c41e2015a9efebdf328e034692ad6acccbfaf91d54c68ca396942282058664736f6c63430008000033 -\ No newline at end of file +60806040523480156200001157600080fd5b5060405162001d1738038062001d178339818101604052810190620000379190620007a7565b6060336000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550600581908060018154018082558091505060019003906000526020600020016000909190919091509080519060200190620000b69291906200071f565b5060056001600580549050620000cd9190620008ce565b8154811062000105577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b90600052602060002001434090806001815401808255809150506001900390600052602060002001600090919091909150556200015233836200015b640100000000026401000000009004565b50505062000a5f565b600080606060006200017d3387620003c5640100000000026401000000009004565b92506002600084815260200190815260200160002054905060008114156200031e57600360008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020339080600181540180825580915050600190039060005260206000200160009091909190916101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506005829080600181540180825580915050600190039060005260206000200160009091909190915090805190602001906200027c9291906200071f565b50600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020869080600181540180825580915050600190039060005260206000200160009091909190916101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055505b6001600580549050620003329190620008ce565b90508060026000858152602001908152602001600020819055506005818154811062000387577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b906000526020600020018590806001815401808255809150506001900390600052602060002001600090919091909150556001935050505092915050565b6000806000602867ffffffffffffffff8111156200040c577f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040519080825280601f01601f1916602001820160405280156200043f5781602001600182028036833780820191505090505b50905060008560405160200162000457919062000825565b604051602081830303815290604052905060005b60148110156200057857818181518110620004af577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60200101517f010000000000000000000000000000000000000000000000000000000000000090047f01000000000000000000000000000000000000000000000000000000000000000283828151811062000533577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535080806200056f9062000987565b9150506200046b565b50846040516020016200058c919062000825565b604051602081830303815290604052905060005b6014811015620006bb57818181518110620005e4577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60200101517f010000000000000000000000000000000000000000000000000000000000000090047f010000000000000000000000000000000000000000000000000000000000000002836014836200063e919062000871565b8151811062000676577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053508080620006b29062000987565b915050620005a0565b50600282604051620006ce919062000842565b602060405180830381855afa158015620006ec573d6000803e3d6000fd5b5050506040513d601f19601f82011682018060405250810190620007119190620007a7565b925082935050505092915050565b8280548282559060005260206000209081019282156200075e579160200282015b828111156200075d57825182559160200191906001019062000740565b5b5090506200076d919062000771565b5090565b5b808211156200078c57600081600090555060010162000772565b5090565b600081519050620007a18162000a45565b92915050565b600060208284031215620007ba57600080fd5b6000620007ca8482850162000790565b91505092915050565b620007e8620007e28262000909565b620009d5565b82525050565b6000620007fb826200085b565b62000807818562000866565b93506200081981856020860162000951565b80840191505092915050565b6000620008338284620007d3565b60148201915081905092915050565b6000620008508284620007ee565b915081905092915050565b600081519050919050565b600081905092915050565b60006200087e8262000947565b91506200088b8362000947565b9250827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff03821115620008c357620008c2620009fd565b5b828201905092915050565b6000620008db8262000947565b9150620008e88362000947565b925082821015620008fe57620008fd620009fd565b5b828203905092915050565b6000620009168262000927565b9050919050565b6000819050919050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000819050919050565b60005b838110156200097157808201518184015260208101905062000954565b8381111562000981576000848401525b50505050565b6000620009948262000947565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff821415620009ca57620009c9620009fd565b5b600182019050919050565b6000620009e282620009e9565b9050919050565b6000620009f68262000a2c565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006c0100000000000000000000000082029050919050565b62000a50816200091d565b811462000a5c57600080fd5b50565b6112a88062000a6f6000396000f3fe608060405234801561001057600080fd5b50600436106100bb576000357c0100000000000000000000000000000000000000000000000000000000900480638c661b36116100835780638c661b361461018a5780638da5cb5b146101ba578063ae47ece0146101d8578063d0e95db114610208578063ff7496b414610238576100bb565b806301ffc9a7146100c057806322168e4f146100f057806350e0c6d3146101205780637d64bf1d14610150578063880ad0af14610180575b600080fd5b6100da60048036038101906100d59190610d2c565b610268565b6040516100e79190610f2c565b60405180910390f35b61010a60048036038101906101059190610cc7565b61026f565b6040516101179190610eef565b60405180910390f35b61013a60048036038101906101359190610c26565b61031b565b6040516101479190610f82565b60405180910390f35b61016a60048036038101906101659190610cc7565b610367565b6040516101779190610eef565b60405180910390f35b610188610413565b005b6101a4600480360381019061019f9190610c4f565b61044e565b6040516101b19190610f0a565b60405180910390f35b6101c2610512565b6040516101cf9190610eef565b60405180910390f35b6101f260048036038101906101ed9190610c8b565b610536565b6040516101ff9190610f2c565b60405180910390f35b610222600480360381019061021d9190610c26565b610789565b60405161022f9190610f82565b60405180910390f35b610252600480360381019061024d9190610d55565b6107d5565b60405161025f9190610f47565b60405180910390f35b6000919050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002082815481106102e8577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b9060005260206000200160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905092915050565b6000600160008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805490509050919050565b6000600360008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002082815481106103e0577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b9060005260206000200160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905092915050565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161044590610f62565b60405180910390fd5b606060008061045d8585610812565b915060026000838152602001908152602001600020549050600581815481106104af577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b9060005260206000200180548060200260200160405190810160405280929190818152602001828054801561050357602002820191906000526020600020905b8154815260200190600101908083116104ef575b50505050509250505092915050565b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b600080606060006105473387610812565b92506002600084815260200190815260200160002054905060008114156106e557600360008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020339080600181540180825580915050600190039060005260206000200160009091909190916101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550600582908060018154018082558091505060019003906000526020600020016000909190919091509080519060200190610643929190610b53565b50600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020869080600181540180825580915050600190039060005260206000200160009091909190916101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055505b60016005805490506106f79190611053565b90508060026000858152602001908152602001600020819055506005818154811061074b577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b906000526020600020018590806001815401808255809150506001900390600052602060002001600090919091909150556001935050505092915050565b6000600360008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805490509050919050565b600582815481106107e557600080fd5b9060005260206000200181815481106107fd57600080fd5b90600052602060002001600091509150505481565b6000806000602867ffffffffffffffff811115610858577f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040519080825280601f01601f19166020018201604052801561088a5781602001600182028036833780820191505090505b5090506000856040516020016108a09190610ebd565b604051602081830303815290604052905060005b60148110156109bb578181815181106108f6577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60200101517f010000000000000000000000000000000000000000000000000000000000000090047f010000000000000000000000000000000000000000000000000000000000000002838281518110610979577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535080806109b390611138565b9150506108b4565b50846040516020016109cd9190610ebd565b604051602081830303815290604052905060005b6014811015610af457818181518110610a23577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60200101517f010000000000000000000000000000000000000000000000000000000000000090047f01000000000000000000000000000000000000000000000000000000000000000283601483610a7b9190610ffd565b81518110610ab2577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053508080610aec90611138565b9150506109e1565b50600282604051610b059190610ed8565b602060405180830381855afa158015610b22573d6000803e3d6000fd5b5050506040513d601f19601f82011682018060405250810190610b459190610d03565b925082935050505092915050565b828054828255906000526020600020908101928215610b8f579160200282015b82811115610b8e578251825591602001919060010190610b73565b5b509050610b9c9190610ba0565b5090565b5b80821115610bb9576000816000905550600101610ba1565b5090565b600081359050610bcc81611216565b92915050565b600081359050610be18161122d565b92915050565b600081519050610bf68161122d565b92915050565b600081359050610c0b81611244565b92915050565b600081359050610c208161125b565b92915050565b600060208284031215610c3857600080fd5b6000610c4684828501610bbd565b91505092915050565b60008060408385031215610c6257600080fd5b6000610c7085828601610bbd565b9250506020610c8185828601610bbd565b9150509250929050565b60008060408385031215610c9e57600080fd5b6000610cac85828601610bbd565b9250506020610cbd85828601610bd2565b9150509250929050565b60008060408385031215610cda57600080fd5b6000610ce885828601610bbd565b9250506020610cf985828601610c11565b9150509250929050565b600060208284031215610d1557600080fd5b6000610d2384828501610be7565b91505092915050565b600060208284031215610d3e57600080fd5b6000610d4c84828501610bfc565b91505092915050565b60008060408385031215610d6857600080fd5b6000610d7685828601610c11565b9250506020610d8785828601610c11565b9150509250929050565b6000610d9d8383610e3c565b60208301905092915050565b610db281611087565b82525050565b610dc9610dc482611087565b611181565b82525050565b6000610dda82610fad565b610de48185610fd0565b9350610def83610f9d565b8060005b83811015610e20578151610e078882610d91565b9750610e1283610fc3565b925050600181019050610df3565b5085935050505092915050565b610e3681611099565b82525050565b610e45816110a5565b82525050565b610e54816110a5565b82525050565b6000610e6582610fb8565b610e6f8185610fe1565b9350610e7f818560208601611105565b80840191505092915050565b6000610e98601783610fec565b9150610ea3826111ed565b602082019050919050565b610eb7816110fb565b82525050565b6000610ec98284610db8565b60148201915081905092915050565b6000610ee48284610e5a565b915081905092915050565b6000602082019050610f046000830184610da9565b92915050565b60006020820190508181036000830152610f248184610dcf565b905092915050565b6000602082019050610f416000830184610e2d565b92915050565b6000602082019050610f5c6000830184610e4b565b92915050565b60006020820190508181036000830152610f7b81610e8b565b9050919050565b6000602082019050610f976000830184610eae565b92915050565b6000819050602082019050919050565b600081519050919050565b600081519050919050565b6000602082019050919050565b600082825260208201905092915050565b600081905092915050565b600082825260208201905092915050565b6000611008826110fb565b9150611013836110fb565b9250827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff03821115611048576110476111a5565b5b828201905092915050565b600061105e826110fb565b9150611069836110fb565b92508282101561107c5761107b6111a5565b5b828203905092915050565b6000611092826110db565b9050919050565b60008115159050919050565b6000819050919050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000819050919050565b60005b83811015611123578082015181840152602081019050611108565b83811115611132576000848401525b50505050565b6000611143826110fb565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff821415611176576111756111a5565b5b600182019050919050565b600061118c82611193565b9050919050565b600061119e826111d4565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006c0100000000000000000000000082029050919050565b7f6f776e65722063616e6e6f74206265206368616e676564000000000000000000600082015250565b61121f81611087565b811461122a57600080fd5b50565b611236816110a5565b811461124157600080fd5b50565b61124d816110af565b811461125857600080fd5b50565b611264816110fb565b811461126f57600080fd5b5056fea26469706673582212202fc6a202a1e23325179dd0e3b6e9473cd6447e4bce6a6d74c8493a3786f4709b64736f6c63430008020033 +\ No newline at end of file diff --git a/python/eth_token_index/data/TokenUniqueSymbolIndex.bin b/python/eth_token_index/data/TokenUniqueSymbolIndex.bin @@ -1 +1 @@ -608060405234801561001057600080fd5b50336000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550600260009080600181540180825580915050600190039060005260206000200160009091909190916101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550610cac806100c46000396000f3fe608060405234801561001057600080fd5b50600436106100a5576000357c010000000000000000000000000000000000000000000000000000000090048063bb34534c11610078578063bb34534c14610132578063cbb8343414610162578063d22057a914610180578063e2095c07146101b0576100a5565b806301ffc9a7146100aa5780637ef50298146100da578063880ad0af1461010a5780638da5cb5b14610114575b600080fd5b6100c460048036038101906100bf9190610840565b6101e0565b6040516100d191906109a3565b60405180910390f35b6100f460048036038101906100ef91906107b2565b6102d0565b60405161010191906109de565b60405180910390f35b6101126102e8565b005b61011c610323565b6040516101299190610988565b60405180910390f35b61014c600480360381019061014791906107b2565b610347565b6040516101599190610988565b60405180910390f35b61016a6103cd565b60405161017791906109de565b60405180910390f35b61019a60048036038101906101959190610804565b6103e6565b6040516101a791906109a3565b60405180910390f35b6101ca60048036038101906101c591906108aa565b610667565b6040516101d79190610988565b60405180910390f35b600063325d15e27c0100000000000000000000000000000000000000000000000000000000027bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916141561025457600190506102cb565b6301ffc9a77c0100000000000000000000000000000000000000000000000000000000027bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614156102c657600190506102cb565b600090505b919050565b60016020528060005260406000206000915090505481565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161031a906109be565b60405180910390fd5b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b600080600160008481526020019081526020016000205490506002818154811061039a577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b9060005260206000200160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16915050919050565b600060016002805490506103e19190610ad7565b905090565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161461044157600080fd5b60606000806000808673ffffffffffffffffffffffffffffffffffffffff166040516024016040516020818303038152906040527f95d89b41000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff83818316178352505050506040516104f09190610971565b6000604051808303816000865af19150503d806000811461052d576040519150601f19603f3d011682016040523d82523d6000602084013e610532565b606091505b50915091508161054157600080fd5b808060200190518101906105559190610869565b94506002856040516105679190610971565b602060405180830381855afa158015610584573d6000803e3d6000fd5b5050506040513d601f19601f820116820180604052508101906105a791906107db565b93508388146105b557600080fd5b60016000858152602001908152602001600020549250600083146105d857600080fd5b60028054905060016000868152602001908152602001600020819055506002879080600181540180825580915050600190039060005260206000200160009091909190916101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060019550505050505092915050565b600060026001836106789190610a81565b815481106106af577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b9060005260206000200160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050919050565b60006106f46106ef84610a2a565b6109f9565b90508281526020810184848401111561070c57600080fd5b610717848285610b89565b509392505050565b60008135905061072e81610c1a565b92915050565b60008135905061074381610c31565b92915050565b60008151905061075881610c31565b92915050565b60008135905061076d81610c48565b92915050565b600082601f83011261078457600080fd5b81516107948482602086016106e1565b91505092915050565b6000813590506107ac81610c5f565b92915050565b6000602082840312156107c457600080fd5b60006107d284828501610734565b91505092915050565b6000602082840312156107ed57600080fd5b60006107fb84828501610749565b91505092915050565b6000806040838503121561081757600080fd5b600061082585828601610734565b92505060206108368582860161071f565b9150509250929050565b60006020828403121561085257600080fd5b60006108608482850161075e565b91505092915050565b60006020828403121561087b57600080fd5b600082015167ffffffffffffffff81111561089557600080fd5b6108a184828501610773565b91505092915050565b6000602082840312156108bc57600080fd5b60006108ca8482850161079d565b91505092915050565b6108dc81610b0b565b82525050565b6108eb81610b1d565b82525050565b60006108fc82610a5a565b6109068185610a65565b9350610916818560208601610b89565b80840191505092915050565b600061092f601783610a70565b91507f6f776e65722063616e6e6f74206265206368616e6765640000000000000000006000830152602082019050919050565b61096b81610b7f565b82525050565b600061097d82846108f1565b915081905092915050565b600060208201905061099d60008301846108d3565b92915050565b60006020820190506109b860008301846108e2565b92915050565b600060208201905081810360008301526109d781610922565b9050919050565b60006020820190506109f36000830184610962565b92915050565b6000604051905081810181811067ffffffffffffffff82111715610a2057610a1f610beb565b5b8060405250919050565b600067ffffffffffffffff821115610a4557610a44610beb565b5b601f19601f8301169050602081019050919050565b600081519050919050565b600081905092915050565b600082825260208201905092915050565b6000610a8c82610b7f565b9150610a9783610b7f565b9250827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff03821115610acc57610acb610bbc565b5b828201905092915050565b6000610ae282610b7f565b9150610aed83610b7f565b925082821015610b0057610aff610bbc565b5b828203905092915050565b6000610b1682610b5f565b9050919050565b60008115159050919050565b6000819050919050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000819050919050565b60005b83811015610ba7578082015181840152602081019050610b8c565b83811115610bb6576000848401525b50505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b610c2381610b0b565b8114610c2e57600080fd5b50565b610c3a81610b29565b8114610c4557600080fd5b50565b610c5181610b33565b8114610c5c57600080fd5b50565b610c6881610b7f565b8114610c7357600080fd5b5056fea2646970667358221220ed793e808a1b3d8da182de33941a4b54f28a143f42ff73df90a085bdbcde321364736f6c63430008000033 -\ No newline at end of file +608060405234801561001057600080fd5b50336000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550600260009080600181540180825580915050600190039060005260206000200160009091909190916101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550610ccf806100c46000396000f3fe608060405234801561001057600080fd5b50600436106100a5576000357c010000000000000000000000000000000000000000000000000000000090048063880ad0af11610078578063880ad0af146101585780638da5cb5b14610162578063bb34534c14610180578063e2095c07146101b0576100a5565b806301ffc9a7146100aa5780630cbb0f83146100da5780634420e486146100f85780637ef5029814610128575b600080fd5b6100c460048036038101906100bf9190610820565b6101e0565b6040516100d19190610966565b60405180910390f35b6100e26102d0565b6040516100ef91906109a1565b60405180910390f35b610112600480360381019061010d91906107a5565b6102e9565b60405161011f9190610966565b60405180910390f35b610142600480360381019061013d91906107ce565b61055d565b60405161014f91906109a1565b60405180910390f35b610160610575565b005b61016a6105b0565b604051610177919061094b565b60405180910390f35b61019a600480360381019061019591906107ce565b6105d4565b6040516101a7919061094b565b60405180910390f35b6101ca60048036038101906101c5919061088a565b61065a565b6040516101d7919061094b565b60405180910390f35b600063325d15e27c0100000000000000000000000000000000000000000000000000000000027bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916141561025457600190506102cb565b6301ffc9a77c0100000000000000000000000000000000000000000000000000000000027bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614156102c657600190506102cb565b600090505b919050565b600060016002805490506102e49190610a8f565b905090565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161461034457600080fd5b60606000806000808673ffffffffffffffffffffffffffffffffffffffff166040516024016040516020818303038152906040527f95d89b41000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff83818316178352505050506040516103f39190610934565b6000604051808303816000865af19150503d8060008114610430576040519150601f19603f3d011682016040523d82523d6000602084013e610435565b606091505b50915091508161044457600080fd5b808060200190518101906104589190610849565b945060028560405161046a9190610934565b602060405180830381855afa158015610487573d6000803e3d6000fd5b5050506040513d601f19601f820116820180604052508101906104aa91906107f7565b935060016000858152602001908152602001600020549250600083146104cf57600080fd5b60028054905060016000868152602001908152602001600020819055506002879080600181540180825580915050600190039060005260206000200160009091909190916101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550600195505050505050919050565b60016020528060005260406000206000915090505481565b6040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105a790610981565b60405180910390fd5b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b6000806001600084815260200190815260200160002054905060028181548110610627577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b9060005260206000200160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16915050919050565b6000600260018361066b9190610a39565b815481106106a2577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b9060005260206000200160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050919050565b60006106e76106e2846109e1565b6109bc565b9050828152602081018484840111156106ff57600080fd5b61070a848285610b41565b509392505050565b60008135905061072181610c3d565b92915050565b60008135905061073681610c54565b92915050565b60008151905061074b81610c54565b92915050565b60008135905061076081610c6b565b92915050565b600082601f83011261077757600080fd5b81516107878482602086016106d4565b91505092915050565b60008135905061079f81610c82565b92915050565b6000602082840312156107b757600080fd5b60006107c584828501610712565b91505092915050565b6000602082840312156107e057600080fd5b60006107ee84828501610727565b91505092915050565b60006020828403121561080957600080fd5b60006108178482850161073c565b91505092915050565b60006020828403121561083257600080fd5b600061084084828501610751565b91505092915050565b60006020828403121561085b57600080fd5b600082015167ffffffffffffffff81111561087557600080fd5b61088184828501610766565b91505092915050565b60006020828403121561089c57600080fd5b60006108aa84828501610790565b91505092915050565b6108bc81610ac3565b82525050565b6108cb81610ad5565b82525050565b60006108dc82610a12565b6108e68185610a1d565b93506108f6818560208601610b41565b80840191505092915050565b600061090f601783610a28565b915061091a82610c14565b602082019050919050565b61092e81610b37565b82525050565b600061094082846108d1565b915081905092915050565b600060208201905061096060008301846108b3565b92915050565b600060208201905061097b60008301846108c2565b92915050565b6000602082019050818103600083015261099a81610902565b9050919050565b60006020820190506109b66000830184610925565b92915050565b60006109c66109d7565b90506109d28282610b74565b919050565b6000604051905090565b600067ffffffffffffffff8211156109fc576109fb610bd4565b5b610a0582610c03565b9050602081019050919050565b600081519050919050565b600081905092915050565b600082825260208201905092915050565b6000610a4482610b37565b9150610a4f83610b37565b9250827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff03821115610a8457610a83610ba5565b5b828201905092915050565b6000610a9a82610b37565b9150610aa583610b37565b925082821015610ab857610ab7610ba5565b5b828203905092915050565b6000610ace82610b17565b9050919050565b60008115159050919050565b6000819050919050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000819050919050565b60005b83811015610b5f578082015181840152602081019050610b44565b83811115610b6e576000848401525b50505050565b610b7d82610c03565b810181811067ffffffffffffffff82111715610b9c57610b9b610bd4565b5b80604052505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6000601f19601f8301169050919050565b7f6f776e65722063616e6e6f74206265206368616e676564000000000000000000600082015250565b610c4681610ac3565b8114610c5157600080fd5b50565b610c5d81610ae1565b8114610c6857600080fd5b50565b610c7481610aeb565b8114610c7f57600080fd5b50565b610c8b81610b37565b8114610c9657600080fd5b5056fea2646970667358221220d95d8be242e45aeef1ba98f83ed7a80092bea8a4da0e29317cc9c3f401d0242564736f6c63430008020033 +\ No newline at end of file diff --git a/python/eth_token_index/data/TokenUniqueSymbolIndex.json b/python/eth_token_index/data/TokenUniqueSymbolIndex.json @@ -1 +1 @@ -[{"inputs":[],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"bytes32","name":"_key","type":"bytes32"}],"name":"addressOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_idx","type":"uint256"}],"name":"entry","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"_key","type":"bytes32"},{"internalType":"address","name":"_token","type":"address"}],"name":"register","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"name":"registry","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"registryCount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes4","name":"_interfaceCode","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"}] +[{"inputs":[],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"bytes32","name":"_key","type":"bytes32"}],"name":"addressOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_idx","type":"uint256"}],"name":"entry","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"entryCount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"}],"name":"register","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"name":"registry","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes4","name":"_interfaceCode","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"}] diff --git a/python/eth_token_index/index.py b/python/eth_token_index/index.py @@ -9,37 +9,41 @@ import json import os import hashlib +# external imports +from chainlib.eth.contract import ( + ABIContractEncoder, + ABIContractType, + abi_decode_single, + ) +from chainlib.eth.tx import ( + TxFactory, + TxFormat, + ) +from chainlib.jsonrpc import jsonrpc_template +from chainlib.eth.constant import ZERO_ADDRESS +from hexathon import ( + add_0x, + ) + logg = logging.getLogger(__name__) moddir = os.path.dirname(__file__) datadir = os.path.join(moddir, 'data') -class TokenUniqueSymbolIndex: +def to_identifier(s): + h = hashlib.new('sha256') + h.update(s.encode('utf-8')) + return h.digest().hex() + + +class TokenUniqueSymbolIndex(TxFactory): __abi = None __bytecode = None __address = None __erc20_abi = None - def __init__(self, w3, address, signer_address=None): - abi = TokenUniqueSymbolIndex.abi() - TokenUniqueSymbolIndex.bytecode() - self.__address = address - self.contract = w3.eth.contract(abi=abi, address=address) - self.w3 = w3 - if signer_address != None: - self.signer_address = signer_address - else: - if type(self.w3.eth.defaultAccount).__name__ == 'Empty': - self.w3.eth.defaultAccount = self.w3.eth.accounts[0] - self.signer_address = self.w3.eth.defaultAccount - - f = open(os.path.join(datadir, 'ERC20.json'), 'r') - TokenUniqueSymbolIndex.__erc20_abi = json.load(f) - f.close() - - @staticmethod def abi(): if TokenUniqueSymbolIndex.__abi == None: @@ -58,27 +62,90 @@ class TokenUniqueSymbolIndex: return TokenUniqueSymbolIndex.__bytecode - def add(self, address): - c = self.w3.eth.contract(abi=TokenUniqueSymbolIndex.__erc20_abi, address=address) - s = c.functions.symbol().call() - h = to_ref(s) - return self.contract.functions.register(h, address).transact({'from':self.signer_address}) - + def constructor(self, sender_address): + code = TokenUniqueSymbolIndex.bytecode() + tx = self.template(sender_address, None, use_nonce=True) + tx = self.set_code(tx, code) + return self.build(tx) + + + def register(self, contract_address, sender_address, address, tx_format=TxFormat.JSONRPC): + enc = ABIContractEncoder() + enc.method('register') + enc.typ(ABIContractType.ADDRESS) + enc.address(address) + data = enc.get() + tx = self.template(sender_address, contract_address, use_nonce=True) + tx = self.set_code(tx, data) + tx = self.finalize(tx, tx_format) + return tx + + + def address_of(self, contract_address, token_symbol, sender_address=ZERO_ADDRESS): + o = jsonrpc_template() + o['method'] = 'eth_call' + enc = ABIContractEncoder() + enc.method('addressOf') + enc.typ(ABIContractType.BYTES32) + token_symbol_digest = to_identifier(token_symbol) + enc.bytes32(token_symbol_digest) + data = add_0x(enc.get()) + tx = self.template(sender_address, contract_address) + tx = self.set_code(tx, data) + o['params'].append(self.normalize(tx)) + return o + + + def entry(self, contract_address, idx, sender_address=ZERO_ADDRESS): + o = jsonrpc_template() + o['method'] = 'eth_call' + enc = ABIContractEncoder() + enc.method('entry') + enc.typ(ABIContractType.UINT256) + enc.uint256(idx) + data = add_0x(enc.get()) + tx = self.template(sender_address, contract_address) + tx = self.set_code(tx, data) + o['params'].append(self.normalize(tx)) + return o + + + def entry_count(self, contract_address, sender_address=ZERO_ADDRESS): + o = jsonrpc_template() + o['method'] = 'eth_call' + enc = ABIContractEncoder() + enc.method('entryCount') + data = add_0x(enc.get()) + tx = self.template(sender_address, contract_address) + tx = self.set_code(tx, data) + o['params'].append(self.normalize(tx)) + return o + + + @classmethod + def parse_address_of(self, v): + return abi_decode_single(ABIContractType.ADDRESS, v) + + + @classmethod + def parse_entry(self, v): + return abi_decode_single(ABIContractType.ADDRESS, v) + + + @classmethod + def parse_entry_count(self, v): + return abi_decode_single(ABIContractType.UINT256, v) + + +# def count(self): +# return self.contract.functions.registryCount().call() +# +# +# def get_index(self, idx): +# return self.contract.functions.entry(idx).call() +# +# +# def get_token_by_symbol(self, symbol): +# ref = to_ref(symbol) +# return self.contract.functions.addressOf(symbol).call() - def count(self): - return self.contract.functions.registryCount().call() - - - def get_index(self, idx): - return self.contract.functions.entry(idx).call() - - - def get_token_by_symbol(self, symbol): - ref = to_ref(symbol) - return self.contract.functions.addressOf(symbol).call() - - -def to_ref(s): - h = hashlib.new('sha256') - h.update(s.encode('utf-8')) - return h.digest().hex() diff --git a/python/requirements.txt b/python/requirements.txt @@ -0,0 +1 @@ +chainlib==0.0.1a27 diff --git a/python/setup.cfg b/python/setup.cfg @@ -1,6 +1,6 @@ [metadata] name = eth-address-index -version = 0.1.0a11 +version = 0.1.0a13 description = Signed metadata declarations for ethereum addresses author = Louis Holbrook author_email = dev@holbrook.no @@ -57,3 +57,4 @@ console_scripts = eth-address-declarator-add = eth_address_declarator.runnable.add:main eth-token-index-deploy = eth_token_index.runnable.deploy:main eth-token-index-add = eth_token_index.runnable.add:main + eth-token-index-list = eth_token_index.runnable.list:main diff --git a/python/test_requirements.txt b/python/test_requirements.txt @@ -1,2 +1,3 @@ eth-tester==0.5.0b2 py-evm==0.3.0a20 +giftable-erc20-token==0.0.7b13 diff --git a/python/tests/test_tokenindex.py b/python/tests/test_tokenindex.py @@ -1,12 +1,20 @@ +# standard imports import os import unittest import json import logging import hashlib -import web3 -import eth_tester -import eth_abi +# external imports +from chainlib.eth.unittest.ethtester import EthTesterCase +from chainlib.eth.nonce import RPCNonceOracle +from chainlib.eth.tx import receipt +from giftable_erc20_token import GiftableToken +from chainlib.eth.tx import unpack +from hexathon import strip_0x + +# local imports +from eth_token_index import TokenUniqueSymbolIndex logging.basicConfig(level=logging.DEBUG) logg = logging.getLogger() @@ -17,108 +25,60 @@ logging.getLogger('eth.vm').setLevel(logging.WARNING) testdir = os.path.dirname(__file__) -class Test(unittest.TestCase): - - contract = None +class Test(EthTesterCase): def setUp(self): - eth_params = eth_tester.backends.pyevm.main.get_default_genesis_params({ - 'gas_limit': 9000000, - }) - - # create store of used accounts - #f = open(os.path.join(testdir, '../eth_token_index/data/TokenUniqueSymbolIndex.bin'), 'r') - f = open(os.path.join(testdir, '../eth_token_index/data/TokenUniqueSymbolIndex.bin'), 'r') - bytecode = f.read() - f.close() - - #f = open(os.path.join(testdir, '../eth_token_index/data/TokenUniqueSymbolIndex.json'), 'r') - f = open(os.path.join(testdir, '../eth_token_index/data/TokenUniqueSymbolIndex.json'), 'r') - self.abi = json.load(f) - f.close() - - - backend = eth_tester.PyEVMBackend(eth_params) - self.eth_tester = eth_tester.EthereumTester(backend) - provider = web3.Web3.EthereumTesterProvider(self.eth_tester) - self.w3 = web3.Web3(provider) - c = self.w3.eth.contract(abi=self.abi, bytecode=bytecode) - tx_hash = c.constructor().transact({'from': self.w3.eth.accounts[0]}) - - r = self.w3.eth.getTransactionReceipt(tx_hash) - - self.address = r.contractAddress - - - # create token - f = open(os.path.join(testdir, '../eth_token_index/data/GiftableToken.bin'), 'r') - bytecode = f.read() - f.close() - - f = open(os.path.join(testdir, '../eth_token_index/data/GiftableToken.json'), 'r') - self.abi_token = json.load(f) - f.close() - - t = self.w3.eth.contract(abi=self.abi_token, bytecode=bytecode) - tx_hash = t.constructor('Foo Token', 'FOO', 18).transact({'from': self.w3.eth.accounts[0]}) - - r = self.w3.eth.getTransactionReceipt(tx_hash) - - self.address_token_one = r.contractAddress - - t = self.w3.eth.contract(abi=self.abi_token, bytecode=bytecode) - tx_hash = t.constructor('Bar Token', 'BAR', 18).transact({'from': self.w3.eth.accounts[0]}) - - r = self.w3.eth.getTransactionReceipt(tx_hash) - - self.address_token_two = r.contractAddress - - t = self.w3.eth.contract(abi=self.abi_token, bytecode=bytecode) - tx_hash = t.constructor('Bar Token Duplicate', 'BAR', 18).transact({'from': self.w3.eth.accounts[0]}) - - r = self.w3.eth.getTransactionReceipt(tx_hash) - - self.address_token_three = r.contractAddress - - - def tearDown(self): - pass - - - def test_basic(self): - c = self.w3.eth.contract(abi=self.abi, address=self.address) - - h = hashlib.new('sha256') - h.update('FOO'.encode('utf-8')) - z = h.digest() - - # owner text - with self.assertRaises(Exception): - c.functions.register(z.hex(), self.address_token_one).transact({'from': self.w3.eth.accounts[1]}) - - logg.debug('using identifier {}'.format(z.hex())) - # Register FOO symbol - c.functions.register(z.hex(), self.address_token_one).transact({'from': self.w3.eth.accounts[0]}) - - # Raise on duplicate FOO symbol - with self.assertRaises(Exception): - c.functions.register(z.hex(), self.address_token_one).transact({'from': self.w3.eth.accounts[0]}) - - # Raise on mismatch between supplied symbol and token symbol reported by ERC20 - with self.assertRaises(Exception): - c.functions.register(z.hex(), self.address_token_two).transact({'from': self.w3.eth.accounts[0]}) - - h = hashlib.new('sha256') - h.update('BAR'.encode('utf-8')) - z = h.digest() - - # Register BAR symbol - c.functions.register(z.hex(), self.address_token_two).transact({'from': self.w3.eth.accounts[0]}) - - # Raise on duplicate BAR symbol (with different token contract address) - with self.assertRaises(Exception): - c.functions.register(z.hex(), self.address_token_three).transact({'from': self.w3.eth.accounts[0]}) - + super(Test, self).setUp() + nonce_oracle = RPCNonceOracle(self.accounts[0], self.rpc) + c = TokenUniqueSymbolIndex(signer=self.signer, nonce_oracle=nonce_oracle, chain_id=self.chain_spec.chain_id()) + (tx_hash_hex, o) = c.constructor(self.accounts[0]) + self.rpc.do(o) + + o = receipt(tx_hash_hex) + r = self.rpc.do(o) + self.assertEqual(r['status'], 1) + + self.address = r['contract_address'] + + c = GiftableToken(signer=self.signer, nonce_oracle=nonce_oracle, chain_id=self.chain_spec.chain_id()) + (tx_hash_hex, o) = c.constructor(self.accounts[0], 'FooToken', 'FOO', 6) + self.rpc.do(o) + + o = receipt(tx_hash_hex) + r = self.rpc.do(o) + self.assertEqual(r['status'], 1) + + self.token_address = r['contract_address'] + + + def test_register(self): + nonce_oracle = RPCNonceOracle(self.accounts[0], self.rpc) + c = TokenUniqueSymbolIndex(signer=self.signer, nonce_oracle=nonce_oracle, chain_id=self.chain_spec.chain_id()) + + (tx_hash_hex, o) = c.register(self.address, self.accounts[0], self.token_address) + self.rpc.do(o) + e = unpack(bytes.fromhex(strip_0x(o['params'][0])), chain_id=self.chain_spec.chain_id()) + logg.debug('e {}'.format(e)) + + o = receipt(tx_hash_hex) + r = self.rpc.do(o) + self.assertEqual(r['status'], 1) + + o = c.address_of(self.address, 'FOO', sender_address=self.accounts[0]) + r = self.rpc.do(o) + address = c.parse_address_of(r) + self.assertEqual(address, self.token_address) + + o = c.entry(self.address, 0, sender_address=self.accounts[0]) + r = self.rpc.do(o) + address = c.parse_entry(r) + self.assertEqual(address, self.token_address) + + o = c.entry_count(self.address, sender_address=self.accounts[0]) + r = self.rpc.do(o) + count = c.parse_entry_count(r) + self.assertEqual(count, 1) + if __name__ == '__main__': unittest.main() diff --git a/solidity/AddressDeclarator.bin b/solidity/AddressDeclarator.bin @@ -1 +1 @@ -60806040523480156200001157600080fd5b5060405162001d0b38038062001d0b8339818101604052810190620000379190620007a7565b6060336000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550600581908060018154018082558091505060019003906000526020600020016000909190919091509080519060200190620000b69291906200071f565b5060056001600580549050620000cd9190620008ce565b8154811062000105577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b90600052602060002001434090806001815401808255809150506001900390600052602060002001600090919091909150556200015233836200015b640100000000026401000000009004565b50505062000a5f565b600080606060006200017d3387620003c5640100000000026401000000009004565b92506002600084815260200190815260200160002054905060008114156200031e57600360008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020339080600181540180825580915050600190039060005260206000200160009091909190916101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506005829080600181540180825580915050600190039060005260206000200160009091909190915090805190602001906200027c9291906200071f565b50600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020869080600181540180825580915050600190039060005260206000200160009091909190916101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055505b6001600580549050620003329190620008ce565b90508060026000858152602001908152602001600020819055506005818154811062000387577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b906000526020600020018590806001815401808255809150506001900390600052602060002001600090919091909150556001935050505092915050565b6000806000602867ffffffffffffffff8111156200040c577f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040519080825280601f01601f1916602001820160405280156200043f5781602001600182028036833780820191505090505b50905060008560405160200162000457919062000825565b604051602081830303815290604052905060005b60148110156200057857818181518110620004af577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60200101517f010000000000000000000000000000000000000000000000000000000000000090047f01000000000000000000000000000000000000000000000000000000000000000283828151811062000533577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535080806200056f9062000987565b9150506200046b565b50846040516020016200058c919062000825565b604051602081830303815290604052905060005b6014811015620006bb57818181518110620005e4577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60200101517f010000000000000000000000000000000000000000000000000000000000000090047f010000000000000000000000000000000000000000000000000000000000000002836014836200063e919062000871565b8151811062000676577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053508080620006b29062000987565b915050620005a0565b50600282604051620006ce919062000842565b602060405180830381855afa158015620006ec573d6000803e3d6000fd5b5050506040513d601f19601f82011682018060405250810190620007119190620007a7565b925082935050505092915050565b8280548282559060005260206000209081019282156200075e579160200282015b828111156200075d57825182559160200191906001019062000740565b5b5090506200076d919062000771565b5090565b5b808211156200078c57600081600090555060010162000772565b5090565b600081519050620007a18162000a45565b92915050565b600060208284031215620007ba57600080fd5b6000620007ca8482850162000790565b91505092915050565b620007e8620007e28262000909565b620009d5565b82525050565b6000620007fb826200085b565b62000807818562000866565b93506200081981856020860162000951565b80840191505092915050565b6000620008338284620007d3565b60148201915081905092915050565b6000620008508284620007ee565b915081905092915050565b600081519050919050565b600081905092915050565b60006200087e8262000947565b91506200088b8362000947565b9250827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff03821115620008c357620008c2620009fd565b5b828201905092915050565b6000620008db8262000947565b9150620008e88362000947565b925082821015620008fe57620008fd620009fd565b5b828203905092915050565b6000620009168262000927565b9050919050565b6000819050919050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000819050919050565b60005b838110156200097157808201518184015260208101905062000954565b8381111562000981576000848401525b50505050565b6000620009948262000947565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff821415620009ca57620009c9620009fd565b5b600182019050919050565b6000620009e282620009e9565b9050919050565b6000620009f68262000a2c565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006c0100000000000000000000000082029050919050565b62000a50816200091d565b811462000a5c57600080fd5b50565b61129c8062000a6f6000396000f3fe608060405234801561001057600080fd5b50600436106100bb576000357c0100000000000000000000000000000000000000000000000000000000900480638c661b36116100835780638c661b361461018a5780638da5cb5b146101ba578063ae47ece0146101d8578063d0e95db114610208578063ff7496b414610238576100bb565b806301ffc9a7146100c057806322168e4f146100f057806350e0c6d3146101205780637d64bf1d14610150578063880ad0af14610180575b600080fd5b6100da60048036038101906100d59190610d2c565b610268565b6040516100e79190610f49565b60405180910390f35b61010a60048036038101906101059190610cc7565b61026f565b6040516101179190610f0c565b60405180910390f35b61013a60048036038101906101359190610c26565b61031b565b6040516101479190610f9f565b60405180910390f35b61016a60048036038101906101659190610cc7565b610367565b6040516101779190610f0c565b60405180910390f35b610188610413565b005b6101a4600480360381019061019f9190610c4f565b61044e565b6040516101b19190610f27565b60405180910390f35b6101c2610512565b6040516101cf9190610f0c565b60405180910390f35b6101f260048036038101906101ed9190610c8b565b610536565b6040516101ff9190610f49565b60405180910390f35b610222600480360381019061021d9190610c26565b610789565b60405161022f9190610f9f565b60405180910390f35b610252600480360381019061024d9190610d55565b6107d5565b60405161025f9190610f64565b60405180910390f35b6000919050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002082815481106102e8577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b9060005260206000200160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905092915050565b6000600160008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805490509050919050565b6000600360008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002082815481106103e0577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b9060005260206000200160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905092915050565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161044590610f7f565b60405180910390fd5b606060008061045d8585610812565b915060026000838152602001908152602001600020549050600581815481106104af577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b9060005260206000200180548060200260200160405190810160405280929190818152602001828054801561050357602002820191906000526020600020905b8154815260200190600101908083116104ef575b50505050509250505092915050565b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b600080606060006105473387610812565b92506002600084815260200190815260200160002054905060008114156106e557600360008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020339080600181540180825580915050600190039060005260206000200160009091909190916101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550600582908060018154018082558091505060019003906000526020600020016000909190919091509080519060200190610643929190610b53565b50600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020869080600181540180825580915050600190039060005260206000200160009091909190916101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055505b60016005805490506106f79190611070565b90508060026000858152602001908152602001600020819055506005818154811061074b577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b906000526020600020018590806001815401808255809150506001900390600052602060002001600090919091909150556001935050505092915050565b6000600360008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805490509050919050565b600582815481106107e557600080fd5b9060005260206000200181815481106107fd57600080fd5b90600052602060002001600091509150505481565b6000806000602867ffffffffffffffff811115610858577f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040519080825280601f01601f19166020018201604052801561088a5781602001600182028036833780820191505090505b5090506000856040516020016108a09190610eda565b604051602081830303815290604052905060005b60148110156109bb578181815181106108f6577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60200101517f010000000000000000000000000000000000000000000000000000000000000090047f010000000000000000000000000000000000000000000000000000000000000002838281518110610979577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535080806109b390611155565b9150506108b4565b50846040516020016109cd9190610eda565b604051602081830303815290604052905060005b6014811015610af457818181518110610a23577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60200101517f010000000000000000000000000000000000000000000000000000000000000090047f01000000000000000000000000000000000000000000000000000000000000000283601483610a7b919061101a565b81518110610ab2577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053508080610aec90611155565b9150506109e1565b50600282604051610b059190610ef5565b602060405180830381855afa158015610b22573d6000803e3d6000fd5b5050506040513d601f19601f82011682018060405250810190610b459190610d03565b925082935050505092915050565b828054828255906000526020600020908101928215610b8f579160200282015b82811115610b8e578251825591602001919060010190610b73565b5b509050610b9c9190610ba0565b5090565b5b80821115610bb9576000816000905550600101610ba1565b5090565b600081359050610bcc8161120a565b92915050565b600081359050610be181611221565b92915050565b600081519050610bf681611221565b92915050565b600081359050610c0b81611238565b92915050565b600081359050610c208161124f565b92915050565b600060208284031215610c3857600080fd5b6000610c4684828501610bbd565b91505092915050565b60008060408385031215610c6257600080fd5b6000610c7085828601610bbd565b9250506020610c8185828601610bbd565b9150509250929050565b60008060408385031215610c9e57600080fd5b6000610cac85828601610bbd565b9250506020610cbd85828601610bd2565b9150509250929050565b60008060408385031215610cda57600080fd5b6000610ce885828601610bbd565b9250506020610cf985828601610c11565b9150509250929050565b600060208284031215610d1557600080fd5b6000610d2384828501610be7565b91505092915050565b600060208284031215610d3e57600080fd5b6000610d4c84828501610bfc565b91505092915050565b60008060408385031215610d6857600080fd5b6000610d7685828601610c11565b9250506020610d8785828601610c11565b9150509250929050565b6000610d9d8383610e3c565b60208301905092915050565b610db2816110a4565b82525050565b610dc9610dc4826110a4565b61119e565b82525050565b6000610dda82610fca565b610de48185610fed565b9350610def83610fba565b8060005b83811015610e20578151610e078882610d91565b9750610e1283610fe0565b925050600181019050610df3565b5085935050505092915050565b610e36816110b6565b82525050565b610e45816110c2565b82525050565b610e54816110c2565b82525050565b6000610e6582610fd5565b610e6f8185610ffe565b9350610e7f818560208601611122565b80840191505092915050565b6000610e98601783611009565b91507f6f776e65722063616e6e6f74206265206368616e6765640000000000000000006000830152602082019050919050565b610ed481611118565b82525050565b6000610ee68284610db8565b60148201915081905092915050565b6000610f018284610e5a565b915081905092915050565b6000602082019050610f216000830184610da9565b92915050565b60006020820190508181036000830152610f418184610dcf565b905092915050565b6000602082019050610f5e6000830184610e2d565b92915050565b6000602082019050610f796000830184610e4b565b92915050565b60006020820190508181036000830152610f9881610e8b565b9050919050565b6000602082019050610fb46000830184610ecb565b92915050565b6000819050602082019050919050565b600081519050919050565b600081519050919050565b6000602082019050919050565b600082825260208201905092915050565b600081905092915050565b600082825260208201905092915050565b600061102582611118565b915061103083611118565b9250827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff03821115611065576110646111c2565b5b828201905092915050565b600061107b82611118565b915061108683611118565b925082821015611099576110986111c2565b5b828203905092915050565b60006110af826110f8565b9050919050565b60008115159050919050565b6000819050919050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000819050919050565b60005b83811015611140578082015181840152602081019050611125565b8381111561114f576000848401525b50505050565b600061116082611118565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff821415611193576111926111c2565b5b600182019050919050565b60006111a9826111b0565b9050919050565b60006111bb826111f1565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006c0100000000000000000000000082029050919050565b611213816110a4565b811461121e57600080fd5b50565b61122a816110c2565b811461123557600080fd5b50565b611241816110cc565b811461124c57600080fd5b50565b61125881611118565b811461126357600080fd5b5056fea2646970667358221220b195c41e2015a9efebdf328e034692ad6acccbfaf91d54c68ca396942282058664736f6c63430008000033 -\ No newline at end of file +60806040523480156200001157600080fd5b5060405162001d1738038062001d178339818101604052810190620000379190620007a7565b6060336000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550600581908060018154018082558091505060019003906000526020600020016000909190919091509080519060200190620000b69291906200071f565b5060056001600580549050620000cd9190620008ce565b8154811062000105577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b90600052602060002001434090806001815401808255809150506001900390600052602060002001600090919091909150556200015233836200015b640100000000026401000000009004565b50505062000a5f565b600080606060006200017d3387620003c5640100000000026401000000009004565b92506002600084815260200190815260200160002054905060008114156200031e57600360008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020339080600181540180825580915050600190039060005260206000200160009091909190916101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506005829080600181540180825580915050600190039060005260206000200160009091909190915090805190602001906200027c9291906200071f565b50600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020869080600181540180825580915050600190039060005260206000200160009091909190916101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055505b6001600580549050620003329190620008ce565b90508060026000858152602001908152602001600020819055506005818154811062000387577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b906000526020600020018590806001815401808255809150506001900390600052602060002001600090919091909150556001935050505092915050565b6000806000602867ffffffffffffffff8111156200040c577f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040519080825280601f01601f1916602001820160405280156200043f5781602001600182028036833780820191505090505b50905060008560405160200162000457919062000825565b604051602081830303815290604052905060005b60148110156200057857818181518110620004af577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60200101517f010000000000000000000000000000000000000000000000000000000000000090047f01000000000000000000000000000000000000000000000000000000000000000283828151811062000533577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535080806200056f9062000987565b9150506200046b565b50846040516020016200058c919062000825565b604051602081830303815290604052905060005b6014811015620006bb57818181518110620005e4577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60200101517f010000000000000000000000000000000000000000000000000000000000000090047f010000000000000000000000000000000000000000000000000000000000000002836014836200063e919062000871565b8151811062000676577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053508080620006b29062000987565b915050620005a0565b50600282604051620006ce919062000842565b602060405180830381855afa158015620006ec573d6000803e3d6000fd5b5050506040513d601f19601f82011682018060405250810190620007119190620007a7565b925082935050505092915050565b8280548282559060005260206000209081019282156200075e579160200282015b828111156200075d57825182559160200191906001019062000740565b5b5090506200076d919062000771565b5090565b5b808211156200078c57600081600090555060010162000772565b5090565b600081519050620007a18162000a45565b92915050565b600060208284031215620007ba57600080fd5b6000620007ca8482850162000790565b91505092915050565b620007e8620007e28262000909565b620009d5565b82525050565b6000620007fb826200085b565b62000807818562000866565b93506200081981856020860162000951565b80840191505092915050565b6000620008338284620007d3565b60148201915081905092915050565b6000620008508284620007ee565b915081905092915050565b600081519050919050565b600081905092915050565b60006200087e8262000947565b91506200088b8362000947565b9250827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff03821115620008c357620008c2620009fd565b5b828201905092915050565b6000620008db8262000947565b9150620008e88362000947565b925082821015620008fe57620008fd620009fd565b5b828203905092915050565b6000620009168262000927565b9050919050565b6000819050919050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000819050919050565b60005b838110156200097157808201518184015260208101905062000954565b8381111562000981576000848401525b50505050565b6000620009948262000947565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff821415620009ca57620009c9620009fd565b5b600182019050919050565b6000620009e282620009e9565b9050919050565b6000620009f68262000a2c565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006c0100000000000000000000000082029050919050565b62000a50816200091d565b811462000a5c57600080fd5b50565b6112a88062000a6f6000396000f3fe608060405234801561001057600080fd5b50600436106100bb576000357c0100000000000000000000000000000000000000000000000000000000900480638c661b36116100835780638c661b361461018a5780638da5cb5b146101ba578063ae47ece0146101d8578063d0e95db114610208578063ff7496b414610238576100bb565b806301ffc9a7146100c057806322168e4f146100f057806350e0c6d3146101205780637d64bf1d14610150578063880ad0af14610180575b600080fd5b6100da60048036038101906100d59190610d2c565b610268565b6040516100e79190610f2c565b60405180910390f35b61010a60048036038101906101059190610cc7565b61026f565b6040516101179190610eef565b60405180910390f35b61013a60048036038101906101359190610c26565b61031b565b6040516101479190610f82565b60405180910390f35b61016a60048036038101906101659190610cc7565b610367565b6040516101779190610eef565b60405180910390f35b610188610413565b005b6101a4600480360381019061019f9190610c4f565b61044e565b6040516101b19190610f0a565b60405180910390f35b6101c2610512565b6040516101cf9190610eef565b60405180910390f35b6101f260048036038101906101ed9190610c8b565b610536565b6040516101ff9190610f2c565b60405180910390f35b610222600480360381019061021d9190610c26565b610789565b60405161022f9190610f82565b60405180910390f35b610252600480360381019061024d9190610d55565b6107d5565b60405161025f9190610f47565b60405180910390f35b6000919050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002082815481106102e8577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b9060005260206000200160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905092915050565b6000600160008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805490509050919050565b6000600360008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002082815481106103e0577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b9060005260206000200160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905092915050565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161044590610f62565b60405180910390fd5b606060008061045d8585610812565b915060026000838152602001908152602001600020549050600581815481106104af577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b9060005260206000200180548060200260200160405190810160405280929190818152602001828054801561050357602002820191906000526020600020905b8154815260200190600101908083116104ef575b50505050509250505092915050565b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b600080606060006105473387610812565b92506002600084815260200190815260200160002054905060008114156106e557600360008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020339080600181540180825580915050600190039060005260206000200160009091909190916101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550600582908060018154018082558091505060019003906000526020600020016000909190919091509080519060200190610643929190610b53565b50600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020869080600181540180825580915050600190039060005260206000200160009091909190916101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055505b60016005805490506106f79190611053565b90508060026000858152602001908152602001600020819055506005818154811061074b577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b906000526020600020018590806001815401808255809150506001900390600052602060002001600090919091909150556001935050505092915050565b6000600360008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805490509050919050565b600582815481106107e557600080fd5b9060005260206000200181815481106107fd57600080fd5b90600052602060002001600091509150505481565b6000806000602867ffffffffffffffff811115610858577f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040519080825280601f01601f19166020018201604052801561088a5781602001600182028036833780820191505090505b5090506000856040516020016108a09190610ebd565b604051602081830303815290604052905060005b60148110156109bb578181815181106108f6577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60200101517f010000000000000000000000000000000000000000000000000000000000000090047f010000000000000000000000000000000000000000000000000000000000000002838281518110610979577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535080806109b390611138565b9150506108b4565b50846040516020016109cd9190610ebd565b604051602081830303815290604052905060005b6014811015610af457818181518110610a23577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60200101517f010000000000000000000000000000000000000000000000000000000000000090047f01000000000000000000000000000000000000000000000000000000000000000283601483610a7b9190610ffd565b81518110610ab2577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053508080610aec90611138565b9150506109e1565b50600282604051610b059190610ed8565b602060405180830381855afa158015610b22573d6000803e3d6000fd5b5050506040513d601f19601f82011682018060405250810190610b459190610d03565b925082935050505092915050565b828054828255906000526020600020908101928215610b8f579160200282015b82811115610b8e578251825591602001919060010190610b73565b5b509050610b9c9190610ba0565b5090565b5b80821115610bb9576000816000905550600101610ba1565b5090565b600081359050610bcc81611216565b92915050565b600081359050610be18161122d565b92915050565b600081519050610bf68161122d565b92915050565b600081359050610c0b81611244565b92915050565b600081359050610c208161125b565b92915050565b600060208284031215610c3857600080fd5b6000610c4684828501610bbd565b91505092915050565b60008060408385031215610c6257600080fd5b6000610c7085828601610bbd565b9250506020610c8185828601610bbd565b9150509250929050565b60008060408385031215610c9e57600080fd5b6000610cac85828601610bbd565b9250506020610cbd85828601610bd2565b9150509250929050565b60008060408385031215610cda57600080fd5b6000610ce885828601610bbd565b9250506020610cf985828601610c11565b9150509250929050565b600060208284031215610d1557600080fd5b6000610d2384828501610be7565b91505092915050565b600060208284031215610d3e57600080fd5b6000610d4c84828501610bfc565b91505092915050565b60008060408385031215610d6857600080fd5b6000610d7685828601610c11565b9250506020610d8785828601610c11565b9150509250929050565b6000610d9d8383610e3c565b60208301905092915050565b610db281611087565b82525050565b610dc9610dc482611087565b611181565b82525050565b6000610dda82610fad565b610de48185610fd0565b9350610def83610f9d565b8060005b83811015610e20578151610e078882610d91565b9750610e1283610fc3565b925050600181019050610df3565b5085935050505092915050565b610e3681611099565b82525050565b610e45816110a5565b82525050565b610e54816110a5565b82525050565b6000610e6582610fb8565b610e6f8185610fe1565b9350610e7f818560208601611105565b80840191505092915050565b6000610e98601783610fec565b9150610ea3826111ed565b602082019050919050565b610eb7816110fb565b82525050565b6000610ec98284610db8565b60148201915081905092915050565b6000610ee48284610e5a565b915081905092915050565b6000602082019050610f046000830184610da9565b92915050565b60006020820190508181036000830152610f248184610dcf565b905092915050565b6000602082019050610f416000830184610e2d565b92915050565b6000602082019050610f5c6000830184610e4b565b92915050565b60006020820190508181036000830152610f7b81610e8b565b9050919050565b6000602082019050610f976000830184610eae565b92915050565b6000819050602082019050919050565b600081519050919050565b600081519050919050565b6000602082019050919050565b600082825260208201905092915050565b600081905092915050565b600082825260208201905092915050565b6000611008826110fb565b9150611013836110fb565b9250827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff03821115611048576110476111a5565b5b828201905092915050565b600061105e826110fb565b9150611069836110fb565b92508282101561107c5761107b6111a5565b5b828203905092915050565b6000611092826110db565b9050919050565b60008115159050919050565b6000819050919050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000819050919050565b60005b83811015611123578082015181840152602081019050611108565b83811115611132576000848401525b50505050565b6000611143826110fb565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff821415611176576111756111a5565b5b600182019050919050565b600061118c82611193565b9050919050565b600061119e826111d4565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006c0100000000000000000000000082029050919050565b7f6f776e65722063616e6e6f74206265206368616e676564000000000000000000600082015250565b61121f81611087565b811461122a57600080fd5b50565b611236816110a5565b811461124157600080fd5b50565b61124d816110af565b811461125857600080fd5b50565b611264816110fb565b811461126f57600080fd5b5056fea26469706673582212202fc6a202a1e23325179dd0e3b6e9473cd6447e4bce6a6d74c8493a3786f4709b64736f6c63430008020033 +\ No newline at end of file diff --git a/solidity/TokenUniqueSymbolIndex.bin b/solidity/TokenUniqueSymbolIndex.bin @@ -1 +1 @@ -608060405234801561001057600080fd5b50336000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550600260009080600181540180825580915050600190039060005260206000200160009091909190916101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550610cac806100c46000396000f3fe608060405234801561001057600080fd5b50600436106100a5576000357c010000000000000000000000000000000000000000000000000000000090048063bb34534c11610078578063bb34534c14610132578063cbb8343414610162578063d22057a914610180578063e2095c07146101b0576100a5565b806301ffc9a7146100aa5780637ef50298146100da578063880ad0af1461010a5780638da5cb5b14610114575b600080fd5b6100c460048036038101906100bf9190610840565b6101e0565b6040516100d191906109a3565b60405180910390f35b6100f460048036038101906100ef91906107b2565b6102d0565b60405161010191906109de565b60405180910390f35b6101126102e8565b005b61011c610323565b6040516101299190610988565b60405180910390f35b61014c600480360381019061014791906107b2565b610347565b6040516101599190610988565b60405180910390f35b61016a6103cd565b60405161017791906109de565b60405180910390f35b61019a60048036038101906101959190610804565b6103e6565b6040516101a791906109a3565b60405180910390f35b6101ca60048036038101906101c591906108aa565b610667565b6040516101d79190610988565b60405180910390f35b600063325d15e27c0100000000000000000000000000000000000000000000000000000000027bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916141561025457600190506102cb565b6301ffc9a77c0100000000000000000000000000000000000000000000000000000000027bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614156102c657600190506102cb565b600090505b919050565b60016020528060005260406000206000915090505481565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161031a906109be565b60405180910390fd5b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b600080600160008481526020019081526020016000205490506002818154811061039a577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b9060005260206000200160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16915050919050565b600060016002805490506103e19190610ad7565b905090565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161461044157600080fd5b60606000806000808673ffffffffffffffffffffffffffffffffffffffff166040516024016040516020818303038152906040527f95d89b41000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff83818316178352505050506040516104f09190610971565b6000604051808303816000865af19150503d806000811461052d576040519150601f19603f3d011682016040523d82523d6000602084013e610532565b606091505b50915091508161054157600080fd5b808060200190518101906105559190610869565b94506002856040516105679190610971565b602060405180830381855afa158015610584573d6000803e3d6000fd5b5050506040513d601f19601f820116820180604052508101906105a791906107db565b93508388146105b557600080fd5b60016000858152602001908152602001600020549250600083146105d857600080fd5b60028054905060016000868152602001908152602001600020819055506002879080600181540180825580915050600190039060005260206000200160009091909190916101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060019550505050505092915050565b600060026001836106789190610a81565b815481106106af577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b9060005260206000200160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050919050565b60006106f46106ef84610a2a565b6109f9565b90508281526020810184848401111561070c57600080fd5b610717848285610b89565b509392505050565b60008135905061072e81610c1a565b92915050565b60008135905061074381610c31565b92915050565b60008151905061075881610c31565b92915050565b60008135905061076d81610c48565b92915050565b600082601f83011261078457600080fd5b81516107948482602086016106e1565b91505092915050565b6000813590506107ac81610c5f565b92915050565b6000602082840312156107c457600080fd5b60006107d284828501610734565b91505092915050565b6000602082840312156107ed57600080fd5b60006107fb84828501610749565b91505092915050565b6000806040838503121561081757600080fd5b600061082585828601610734565b92505060206108368582860161071f565b9150509250929050565b60006020828403121561085257600080fd5b60006108608482850161075e565b91505092915050565b60006020828403121561087b57600080fd5b600082015167ffffffffffffffff81111561089557600080fd5b6108a184828501610773565b91505092915050565b6000602082840312156108bc57600080fd5b60006108ca8482850161079d565b91505092915050565b6108dc81610b0b565b82525050565b6108eb81610b1d565b82525050565b60006108fc82610a5a565b6109068185610a65565b9350610916818560208601610b89565b80840191505092915050565b600061092f601783610a70565b91507f6f776e65722063616e6e6f74206265206368616e6765640000000000000000006000830152602082019050919050565b61096b81610b7f565b82525050565b600061097d82846108f1565b915081905092915050565b600060208201905061099d60008301846108d3565b92915050565b60006020820190506109b860008301846108e2565b92915050565b600060208201905081810360008301526109d781610922565b9050919050565b60006020820190506109f36000830184610962565b92915050565b6000604051905081810181811067ffffffffffffffff82111715610a2057610a1f610beb565b5b8060405250919050565b600067ffffffffffffffff821115610a4557610a44610beb565b5b601f19601f8301169050602081019050919050565b600081519050919050565b600081905092915050565b600082825260208201905092915050565b6000610a8c82610b7f565b9150610a9783610b7f565b9250827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff03821115610acc57610acb610bbc565b5b828201905092915050565b6000610ae282610b7f565b9150610aed83610b7f565b925082821015610b0057610aff610bbc565b5b828203905092915050565b6000610b1682610b5f565b9050919050565b60008115159050919050565b6000819050919050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000819050919050565b60005b83811015610ba7578082015181840152602081019050610b8c565b83811115610bb6576000848401525b50505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b610c2381610b0b565b8114610c2e57600080fd5b50565b610c3a81610b29565b8114610c4557600080fd5b50565b610c5181610b33565b8114610c5c57600080fd5b50565b610c6881610b7f565b8114610c7357600080fd5b5056fea2646970667358221220ed793e808a1b3d8da182de33941a4b54f28a143f42ff73df90a085bdbcde321364736f6c63430008000033 -\ No newline at end of file +608060405234801561001057600080fd5b50336000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550600260009080600181540180825580915050600190039060005260206000200160009091909190916101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550610ccf806100c46000396000f3fe608060405234801561001057600080fd5b50600436106100a5576000357c010000000000000000000000000000000000000000000000000000000090048063880ad0af11610078578063880ad0af146101585780638da5cb5b14610162578063bb34534c14610180578063e2095c07146101b0576100a5565b806301ffc9a7146100aa5780630cbb0f83146100da5780634420e486146100f85780637ef5029814610128575b600080fd5b6100c460048036038101906100bf9190610820565b6101e0565b6040516100d19190610966565b60405180910390f35b6100e26102d0565b6040516100ef91906109a1565b60405180910390f35b610112600480360381019061010d91906107a5565b6102e9565b60405161011f9190610966565b60405180910390f35b610142600480360381019061013d91906107ce565b61055d565b60405161014f91906109a1565b60405180910390f35b610160610575565b005b61016a6105b0565b604051610177919061094b565b60405180910390f35b61019a600480360381019061019591906107ce565b6105d4565b6040516101a7919061094b565b60405180910390f35b6101ca60048036038101906101c5919061088a565b61065a565b6040516101d7919061094b565b60405180910390f35b600063325d15e27c0100000000000000000000000000000000000000000000000000000000027bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916141561025457600190506102cb565b6301ffc9a77c0100000000000000000000000000000000000000000000000000000000027bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614156102c657600190506102cb565b600090505b919050565b600060016002805490506102e49190610a8f565b905090565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161461034457600080fd5b60606000806000808673ffffffffffffffffffffffffffffffffffffffff166040516024016040516020818303038152906040527f95d89b41000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff83818316178352505050506040516103f39190610934565b6000604051808303816000865af19150503d8060008114610430576040519150601f19603f3d011682016040523d82523d6000602084013e610435565b606091505b50915091508161044457600080fd5b808060200190518101906104589190610849565b945060028560405161046a9190610934565b602060405180830381855afa158015610487573d6000803e3d6000fd5b5050506040513d601f19601f820116820180604052508101906104aa91906107f7565b935060016000858152602001908152602001600020549250600083146104cf57600080fd5b60028054905060016000868152602001908152602001600020819055506002879080600181540180825580915050600190039060005260206000200160009091909190916101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550600195505050505050919050565b60016020528060005260406000206000915090505481565b6040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105a790610981565b60405180910390fd5b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b6000806001600084815260200190815260200160002054905060028181548110610627577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b9060005260206000200160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16915050919050565b6000600260018361066b9190610a39565b815481106106a2577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b9060005260206000200160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050919050565b60006106e76106e2846109e1565b6109bc565b9050828152602081018484840111156106ff57600080fd5b61070a848285610b41565b509392505050565b60008135905061072181610c3d565b92915050565b60008135905061073681610c54565b92915050565b60008151905061074b81610c54565b92915050565b60008135905061076081610c6b565b92915050565b600082601f83011261077757600080fd5b81516107878482602086016106d4565b91505092915050565b60008135905061079f81610c82565b92915050565b6000602082840312156107b757600080fd5b60006107c584828501610712565b91505092915050565b6000602082840312156107e057600080fd5b60006107ee84828501610727565b91505092915050565b60006020828403121561080957600080fd5b60006108178482850161073c565b91505092915050565b60006020828403121561083257600080fd5b600061084084828501610751565b91505092915050565b60006020828403121561085b57600080fd5b600082015167ffffffffffffffff81111561087557600080fd5b61088184828501610766565b91505092915050565b60006020828403121561089c57600080fd5b60006108aa84828501610790565b91505092915050565b6108bc81610ac3565b82525050565b6108cb81610ad5565b82525050565b60006108dc82610a12565b6108e68185610a1d565b93506108f6818560208601610b41565b80840191505092915050565b600061090f601783610a28565b915061091a82610c14565b602082019050919050565b61092e81610b37565b82525050565b600061094082846108d1565b915081905092915050565b600060208201905061096060008301846108b3565b92915050565b600060208201905061097b60008301846108c2565b92915050565b6000602082019050818103600083015261099a81610902565b9050919050565b60006020820190506109b66000830184610925565b92915050565b60006109c66109d7565b90506109d28282610b74565b919050565b6000604051905090565b600067ffffffffffffffff8211156109fc576109fb610bd4565b5b610a0582610c03565b9050602081019050919050565b600081519050919050565b600081905092915050565b600082825260208201905092915050565b6000610a4482610b37565b9150610a4f83610b37565b9250827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff03821115610a8457610a83610ba5565b5b828201905092915050565b6000610a9a82610b37565b9150610aa583610b37565b925082821015610ab857610ab7610ba5565b5b828203905092915050565b6000610ace82610b17565b9050919050565b60008115159050919050565b6000819050919050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000819050919050565b60005b83811015610b5f578082015181840152602081019050610b44565b83811115610b6e576000848401525b50505050565b610b7d82610c03565b810181811067ffffffffffffffff82111715610b9c57610b9b610bd4565b5b80604052505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6000601f19601f8301169050919050565b7f6f776e65722063616e6e6f74206265206368616e676564000000000000000000600082015250565b610c4681610ac3565b8114610c5157600080fd5b50565b610c5d81610ae1565b8114610c6857600080fd5b50565b610c7481610aeb565b8114610c7f57600080fd5b50565b610c8b81610b37565b8114610c9657600080fd5b5056fea2646970667358221220d95d8be242e45aeef1ba98f83ed7a80092bea8a4da0e29317cc9c3f401d0242564736f6c63430008020033 +\ No newline at end of file diff --git a/solidity/TokenUniqueSymbolIndex.json b/solidity/TokenUniqueSymbolIndex.json @@ -1 +1 @@ -[{"inputs":[],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"bytes32","name":"_key","type":"bytes32"}],"name":"addressOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_idx","type":"uint256"}],"name":"entry","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"_key","type":"bytes32"},{"internalType":"address","name":"_token","type":"address"}],"name":"register","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"name":"registry","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"registryCount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes4","name":"_interfaceCode","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"}] +[{"inputs":[],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"bytes32","name":"_key","type":"bytes32"}],"name":"addressOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_idx","type":"uint256"}],"name":"entry","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"entryCount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"}],"name":"register","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"name":"registry","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes4","name":"_interfaceCode","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"}] diff --git a/solidity/TokenUniqueSymbolIndex.sol b/solidity/TokenUniqueSymbolIndex.sol @@ -42,7 +42,7 @@ contract TokenUniqueSymbolIndex { return tokens[idx]; } - function register(bytes32 _key, address _token) public returns (bool) { + function register(address _token) public returns (bool) { require(msg.sender == owner); bytes memory token_symbol; @@ -55,7 +55,6 @@ contract TokenUniqueSymbolIndex { token_symbol = abi.decode(_r, (bytes)); token_symbol_key = sha256(token_symbol); - require(_key == token_symbol_key); idx = registry[token_symbol_key]; require(idx == 0); @@ -64,7 +63,7 @@ contract TokenUniqueSymbolIndex { return true; } - function registryCount() public view returns ( uint256 ) { + function entryCount() public view returns ( uint256 ) { return tokens.length - 1; } }