Random numbers using blockchain How are the block hashes generated?

Are they trully 100% random (generated by hardware) or is it pseudo-random (generated by software)?

Can i rely on it or any other blockchain data to make a 100% trustable raffle?

Regards,
Are they truly 100% random (generated by hardware) or is it pseudo-random (generated by software)?


Pedantic answer: No, they're not random, because the first twenty digits or so will always be zero. 

Serious answer: The Bitcoin client does not use any hardware randomness, as far as I know. However, if even a single transaction in the block was generated using hardware randomness, the block hash will incorporate hardware randomness.

Also, I don't think you could predict the hash of a block that hasn't been found yet.


  Can I rely on it or any other blockchain data to make a 100% trustable raffle?


As Greg said, a miner can withhold blocks if releasing them would make the miner lose the raffle. Of course, the cost of withholding a block and not broadcasting it to the network is about $9000, so this attack might not be useful.


  How do I make a trustable raffle


Your method would probably work. This answer discusses how to exchange a secret between two parties that can't trust one another. You could use something based on that.