ethereum-etl
ethereum-etl copied to clipboard
Process all basic blocks to make the sighash checks 'greedy'
Instead of processing just basic_block[0] I've looped through all the basic blocks this finds the sighashes for many more ERC20 contracts.
I think this also removed the limitation around proxies. I'm still building my knowledge around ETH so it may do so at the expense of introducing false positives.
Sorry, I missed the actual fix I wanted to implement in my commit. This now contains a loop through the basic blocks adding all the hashes.
This will may add more sighashes than there really are (I'm not sure everything that's a PUSH4 is actually a function) but it doesn't seem to miss any which works for the matching on contracts if the function comes through a proxy, which lots of contracts seem to implement.
Thanks for the PR!
Looking only at the 1st block could produce false negatives (some function sighashes will be missing), while looking at all blocks could product false positives (some function sighashes will be added mistakenly). The PR needs some test cases and comparison of results before and after to understand the impact
I kindly request to add test cases that could surface false positives.
Any updates relating this issue/PR?