Just read that generating random a random number via keccak256 is insecure. What is insecure about it and what are the implications of insecurity?


2 Answers 2


It's not the keccak, which is btw. just an hashing algorithm, but more the input you give to that, that can be cheated on. For example if you would try to make randomness with the block number, the miners could hack it. If you hash the block number with keccak, this would not change the fact that it's manipulable.


The number will always be the same, the difference between the numbers 1 and 2 will be massive when ran through a Keccak hash, however, they will always be the same each time they are hashed.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.