Bitcoin Forum
December 13, 2024, 08:10:25 AM *
News: Latest Bitcoin Core release: 28.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: [ANN] Instant SicBo for BTC  (Read 1332 times)
SRoulette (OP)
Sr. Member
****
Offline Offline

Activity: 364
Merit: 252



View Profile WWW
September 23, 2012, 06:46:57 AM
Last edit: September 23, 2012, 07:04:30 AM by SRoulette
 #1

Satoshi Roulette Presents:
Instant SicBo
Features
  • Win up to 180 BTC instantly.
  • Players receieve the die rolled in the form of a micro payment 0.00000[d1][d2][d3] BTC is  added to winnings or sent to confirm a loss.
  • Chinese Translation coming soon.
  • Normally Recieve Winnings in less than 20 Seconds.
  • Provably fair (all our games use cryptographic private+public key generated results which can be verified by the player once the private secret is released).
  • Public Shoutbox for support and chat

Min Bet 0.05 BTC, Max Bet 1 BTC

Rules: http://en.wikipedia.org/wiki/Sic_bo
Reddit Announcement: http://www.reddit.com/r/Bitcoin/comments/10c0yz/instant_sicbo_for_btc/


Stephen Gornick
Legendary
*
Offline Offline

Activity: 2506
Merit: 1010


View Profile
September 23, 2012, 07:11:23 AM
 #2

  • Provably fair (all our games use cryptographic private+public key generated results which can be verified by the player once the private secret is
Can you show how a player would verify?

I see the file for the secret:

 - http://satoshiroulette.com/secrets/btc.secret.20120923.000001.txt

Is that just the hash for the current day, or perhaps that is the secret for the previous day's wagers?

Unichange.me

            █
            █
            █
            █
            █
            █
            █
            █
            █
            █
            █
            █
            █
            █
            █
            █


SRoulette (OP)
Sr. Member
****
Offline Offline

Activity: 364
Merit: 252



View Profile WWW
September 23, 2012, 08:19:11 AM
 #3

Hello Stephen,
Codemonkey is still working on releasing a packaged version of our bet verfier for players so they can verify bets  themselves easily.
For now, I shall paste our script for you and others to check and confirm.
It works fine, code monkey just wishes to make it more user friendly and package it as an exe for windows users.

confirm_bet.pl

Code:
#!/usr/bin/perl -w
# bet_verify.pl
use Digest::SHA qw(hmac_sha512_hex);

if(!$ARGV[0] || $ARGV[0] eq "--help" || $ARGV[0] eq "-h" || $ARGV[0] eq "/?")
{
        print "usage: confirm_bet.pl <HIGHEST NUMBER> <SECRET> <TXID>";
}
$highest_number=$ARGV[0];
$secret=$ARGV[1];
$tx=$ARGV[2];

# create a hash using bet txid and secret
$number = hmac_sha512_hex($tx, $secret);
# Grab the 1st 4 digits of the hash (0000 - FFFF)
$number =~ s/^(.{4}).*$/$1/;
# this converts 0000 - FFFF to 0 to 65535
$number = hex($number);
# convert 0-65535 to 1-N (for roulette its 37)
$number = int( ($number/ 65536) * ($highest_number))+1;
print "Result: $number\n";

This is yesterdays secret:
http://satoshiroulette.com/secrets/btc.secret.20120923.000001.txt

Todays secret which will change in the next 8h, this is a sha512sum of it.

Code:
satoshi@KVMSERVER:~$ sha512sum super_satoshi/data-btc/secret.txt
a8a3096db1b50b14603c05afac553bae3a5a235809952eefd395cded9eab36540a5726a59e9a35fc21dcc987e9ea601ed1de48dfe67d5556eaeeefe2b18df0eb  super_satoshi/data-btc/secret.txt

I shall task code monkey with uploading sha's of the current secret as well.
We announce in our live logs secrets when the secret is changed at Midnight GMT 0.

To use our verify program, you must have 3 user inputs.
Code:
perl bet_verify.pl TOTAL_OUTCOMES SECRET TXID
TOTAL_OUTCOMES = Number of different results a game can have, roulette it is 37 (36 numbers plus house number 0).

To verify a roulette game you would run:
Code:
perl bet_verify.pl 37 SECRET TXID

For example, lets verify the last bet made before the secret was changed, still visible in the logs currently.

Log:
Code:
2012/09/22 22:14:11: roulette-2nd12        : 24             txid: c20627067823cb97e6d39bccbe8ea27d2c52e9a39999c957bee8119d08b256bd
2012/09/23 00:00:08: Secret changed                         OLD SECRET: a5ae751f40a1d957129b9b6060aa7b97b63f17a25e8d5b5906ebba450f29fc907a7cf8598aa686002f917baf1c9311343093af0cc0bb132abe9c56be277e26ab

Shell:
Code:
perl confirm_bet.pl 37 a5ae751f40a1d957129b9b6060aa7b97b63f17a25e8d5b5906ebba450f29fc907a7cf8598aa686002f917baf1c9311343093af0cc0bb132abe9c56be277e26ab  c20627067823cb97e6d39bccbe8ea27d2c52e9a39999c957bee8119d08b256bd
Result: 24

Now to verify dice games, its the same concept but we need a map to lookup random result --> dice result.
http://satoshiroulette.com/dice.map.txt

Again taking the last SicBo bet made before the secret change:

Log:
Code:
2012/09/22 19:18:58: sicbo-4XX             : 2 5 4          txid: 3d086b5827a237d32995d498027df64ef6535d97809d8aa8c7e052866f9fdbf5

Shell:
Code:
perl confirm_bet.pl 216 a5ae751f40a1d957129b9b6060aa7b97b63f17a25e8d5b5906ebba450f29fc907a7cf8598aa686002f917baf1c9311343093af0cc0bb132abe9c56be277e26ab 3d086b5827a237d32995d498027df64ef6535d97809d8aa8c7e052866f9fdbf5
Result: 64

Look up 64 in http://satoshiroulette.com/dice.map.txt

64 254

The Dealer Rolled 2 5 4

Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!