Introduction :
Recently a lot of new Player vs Player sites have been opening up in the Bitcoin gambling scene.
Which is great, I've personally been a huge advocate for PvP to come into popularity with Bitcoin gambling, however it's still important to be cautious.
Many sites claim to have a provably fair system, when in fact they don't. Provably fair implies the user's bets are backed by math, not the casinos word to be fair.
Problem :
We'll start with a very basic coinflip between two users example.
False provable fairness PvP :
> User Satoshi creates his game for 1BTC
> Server displays hash beneath the users game which contains {Winner,RandomString}
> User Nakamoto joins the game for 1BTC
> Server reveals RandomString + Winner
Everything may seem to check out here, the hash was displayed at the start meaning it can't be manipulated, right?
Correct, however it's not manipulation that's the point of failure here, it's the casinos knowledge.
The casino generated the winner themselves, meaning in theory they could know if the game Satoshi created would be a win for whoever joined, or a loss.
The casino could also generate their own name under a different pseudonym, and create one in which is a win for themselves while still providing the hash in the beginning.
Solution :
External source of random of which is determined beforehand but not known by the user or the casino.
For sake of simplicity, I'll illustrate an easy way to implement this.
>User Satoshi creates his game for 1BTC
>User Nakamoto joins the game for 1BTC
>Server gets the current highest bitcoin block + 1 and displays this block to both users to verify its unmined
>Once the block is mined, the server uses the binary of the blocks hash to determine the winnner (i.e 0 = Heads 1 = Tails)
This ensures several things :
1. Transparent and verifiable still by both parties
2. Impossible for casino to manipulate results
3. Predetermined games with still and unknown result by both the player and casino
This may seem very trivial and obvious to a lot of you, however I've seen far too many people confusing fancy hashing and the term
provably fair being thrown around, when in fact the PvP site is not provably fair and essentially has a useless system in place for it.
No need to use 3rd-party information. Imo if you want to make a gambling site, you should be able to make your own RNG on your site.
We made a provably fair RNG on our site without 3rd party software or offsite information.
https://www.youtube.com/watch?v=OAmSAvmvA70 I saw sites even use Random.org as their RNG lol. Well if there are any questions i will be glad to answer them.