Author

Topic: Need some help with a provably fair drawing, advice please. (Read 790 times)

legendary
Activity: 3416
Merit: 1912
The Concierge of Crypto
Hi. I welcome friendly competition. You even got a whale on your first drawing (hey lightlord, why didn't you buy tickets from me, hehehe.)

There is the usual Provably Fair, sometimes called "Provably Results" according to mem, if you restrict the seed to one (you) or fix the seeds otherwise. But using an extra secret from someone else will make it truly Provably Fair.

Your method of determining the winner just has to be made public. The rules on how I compute or calculate the winner on mine is all posted so ... feel free to copy it. I ended up using 7 secrets, 1 I know, 5 known by others, and 1 no one knows until that date.

I'd be happy to hold one secret for you, which I will publish on your thread the day after all entries are in.

In fact, I'd be happy to do the whole drawing for you, to determine the winners (according to my system) while you hold all the coins. I did that recently with a dice site give away.

(Don't forget to tip the dealer.) hehehe.
sr. member
Activity: 285
Merit: 262
Also, just use txids of each payment as a secret and release a hash of your secret so there is no possibility of cheating, by you or anyone else.
sr. member
Activity: 285
Merit: 262
Code:
print "Usage: $argv[0] [total_winners] [total_tickets] \n";
$secrets "";
for(
$i 3$i sizeof($argv); $i++) $secrets .= $argv[$i];
print 
$secrets"\n";
$hash hash("sha256"$secrets);
print 
$hash "\n";
$seed hexdec(substr($hash08));
print 
$seed "\n";
mt_srand($seed);
$i $argv[1];
$winners = array();
do {
$randval mt_rand() % $argv[2];
if(!in_array($randval$winners)) {
array_push($winners$randval);
print "--$i--$randval\n";
$i--;
}
} while(
$i 0);
?>

sr. member
Activity: 294
Merit: 250
One of my last replies to you was a method entirely described and implemented, did you find some flaw on it ? I'm fine if you simple don't want to listen to me, that is ok. You can also look at Dabs lottery at least as an example for picking seeds.

Right now I honestly think you need to show some effort in implementing what has been described to you, then you can show other people what you have tried and what specifically you don't understand.
hero member
Activity: 602
Merit: 500
Acc bought - used solely for signature testing
So my last drawing went off and Lightlord won all the prizes. However, I am thinking for the next drawing offering it to cost .01 BTC each ticket, now here is my problem. I am not going to use Just-dice's rolling to decide the winners, this takes way too much time and honestly no one wants to count what # ticket they are and what numbers they have for the roll.

I need a simple way of randoming drawing a number 1-500 or 1-1000 or whatever I need. I was thinking I have a private seed or hash or whatever and I ask someone else extremely trusted to hold their own private seed or something, then when the drawing filled we "combine" them and input the user seeds "1" "2" "3" and so on for prize # that is being drawn for.

So in summary:
A secret seed held by me
Another seed held by another player
And the client / public seed being the number of the prize being drawn (my drawing would prob have 10 winners, so it would be 1, 2, 3, 4, 5 up to 10) for the 10 draws. If a ticket would be drawn a second time I would draw again by adding a zero or something.

Can someone explain to me how to do this?

I have the idea and I know coinroll.it is doing something similar with their 100 BTC giveaway, but I don't understand how you add hashes or any of that or compute what the drawn number would be using the hashes.

Please comment if you can explain or help, thanks!
Jump to: