If I am using web3py to hash some data, like so,
msgHash = w3.soliditySha3(['bytes32','bytes32'], [dataBytes, saltBytes]);
What would be the correct way to hash inside of a Solidity contract and expect the same resultant hash?
In Solidity (v0.4.24) I have tried,
keccak256(abi.encodePacked(data, salt)) sha3(data, salt)
and a few other ways but no luck. I believe there is a specific way to do this and the exact hashing algorithms don't always match. In Solidity the data type I am using is,
Could the text= prefix be messing this up? Also is there a specific prefix that Solidity uses?
dataBytes = w3.toBytes(text=data); saltBytes = w3.toBytes(text=salt);