This contract has been out for a while (it's not mine). I wonder how secure it is. I understand encrypting & revealing process there, but what strikes me more is: When player1 calls method play
with arguments string choice, string randStr
, the fact that he called this method with those arguments is visible to all nodes on network, isn't it? Therefore player2 can search in blockchain transactions player1's call of play
method and see choice
?
As far as I know transaction data isn't private.
Contract URL: https://github.com/SCBuergel/ethereum-rps/blob/master/rps-advanced.sol