Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Please Upload to Datacoin and Tag the Attached Key
- by vintagetrex aka Donal Lumsden
- //*This algorithm for P2P proof of knowledge is arranged as a race. It works between a main blockchain building network and a side chain network. The challenge is generated and published by the "prover" node and answered by the "verifier" nodes. There are two rewards used: the first is crypto currency for a successful "prover" role and the second is a counter for a "verifier" who wins the proof of knowledge competition. Counters reset after a time period (tr). Rewards and counters can be replaced with two distinct currencies. A negative consequence for an incorrect response to the POK challenge should be used to prevent guessing. A certain amount of counters is required for a verifier to become eligible for the "prover draft." Provers are drafted from the eligible nodes through a pseudorandom number generated by the blockchain, such as the numbers generated by primecoin. The case discussesd has 1 prover and 2 verifiers in competition. *//
- //prover and verifier roles are delegated by the blockchain
- 1) Random number R0 is generated by the blockchain and N0 is drafted as the prover with verifiers N1 and N2
- //prover generates the proof of knowledge competition in steps 2 to 6
- 2) Prover generates random numbers R1 and R2 which will be used as salt (random number padding)
- 3) Prover generates 2 one-time-pads X1 and X2 which will be used to change hashes at a rate of 50%
- 4) Prover hashes concatenated N1, X1, R1, N2, X2, and R2
- Hash ( N1 + X1 + R1 + N2 + X2 + R2) = D
- 5) Prover uploads D to the blockchain
- 6) Prover creates challenges C1 and C2 by XORing the hash of R concatenated with F
- X1( Hash(R1 + F) ) = C1
- X2( Hash(R2 + F) ) = C2
- //C1 = Hash(R1 + F) 50% of the time
- //C2 = Hash(R2 + F) 50% of the time
- 7) Prover encrypts C1 concatenated with R1 and C2 concatenated with R2 with the public keys of N1 and N2, PK1 and PK2 respectively to make M1 and M2. Signing keys are SK1 and SK2
- PK1 ( C1 + R1 ) = M1
- PK2 ( C2 + R2 ) = M2
- 8) Prover uploads M1 and M2 to the blockchain
- 9) Verifier performs POK by checking if the challenge is the hash of R1 concatenated with F or not (true or false)
- SK1( M1 ) == C1 + R1
- if ( C1 == Hash(R1 + F) ) {upload true;}
- else {upload false}
- 11) Prover uploads N1, X1, R1, N2, X2, and R2 concatenated or (N1+X1+R1+N2+X2+R2)
- //anyone can verify this as the solutions to the POK using the previously uploaded Hash in step 5, in essence the prover is posting the solutions to the POK challenges
- 12) Protest period; a node can upload its private key if the prover role wasn't performed correctly and anyone may check if messages and challenges (M, C) were made correctly
- Reward for prover = inflation of currency;
- Reward for verifier who answers first = counter++;
- counters required for prover draft eligibility >= some number;
- time period for counters to reset = tr;
- time span between upload of messages (M) and upload of solution (N1+X1+R1+N2+X2+R2) <= tchallenge; //very small to prevent cheaters
- cheater = running a node without unique storage of F for that node
- //cheaters are combatted by making a time dependent competition or race
- //assumption: cheaters have to take extra steps so they will never be as fast and will lose to non cheaters
- -----BEGIN PGP PUBLIC KEY BLOCK-----
- mQENBFM7MyYBCADRtFqhErCi4Ep57JUlkjOXns50w5ZlpZq1K9OZUFdqYCZ1s3Bj
- PQJBFUhobChKnSf0QuCA0ETe6+x1dzPblyf0pOxky39n8l3eY8WP792ORjuYHAwN
- aeKAq2pUKpTzZ2wGXRoUDBTMeSUHBPPWtR/aCTggheb1ZCLrLnmdT2LU/1ZOicyr
- +B/YWrY/2qmc+E4Gbvn+eip+17Kg5CQHYHOMEAwcch6HAuPSeqhZNXb6b1anoC/4
- ONXXPjr7KMqIKOSQH+BSk843XC6BfkF7/vQMxSwppF8jiKFP3hI09BY8vgwB9RmQ
- CiUVGUUPF+KdbW3T5UKO8tsyU5+s0ThWw5LzABEBAAG0GGZpcnN0IFBHUCBrZXkg
- KHByYWN0aWNlKYkBPQQTAQoAJwUCUzszJgIbAwUJAeAB2gULCQgHAwUVCgkICwUW
- AgMBAAIeAQIXgAAKCRACvJj0Hvl/RrOuB/4wdfxa+0pmgztyD3STOABv0L0omU2z
- 8xzSaD6r3ImhRLLftNjJMFdsKcoBWiuC6aGZieIvyHUgT62ROl9ogqJciSUzq8mO
- eZUv24qYYtRROSBBs4wElobb98zvT0LxFc5s+Ecxe8bv07Ms9ml12l3G/rYnpZjb
- qw9dmR/3XXDNeN3bZxk+bh5C4lAAyhoTLkmy/OKsH2WFYdRNpzxJ3E/4WhxljwIq
- TA9HGatFsDlVqGCVP8coTRW0W1n6/FhgowxqKe2Thn3cWivRMACQfN6tw/70QZ9W
- teYdUBsw8NfK1yAjTbm67ESvk3NysqgXD55U+8HNMMfbMU6jPrQGxD0TuQENBFM7
- MyYBCACmICDurza5xNFUICIQicYasOFQl0EBZRhM1BM25YR72VgfUS06SWKtH80k
- xvmd5mxDMylFhEeXBSoaLns8Xk9IQ5xjiD1676GgM6KFoN0W98IogfTNej2qbt3U
- hgQHN74BQYh6wNRZymaav6mYBeHwpYiEpd7vPvFuv+K1QLA84ZtaWXxHD/NcKdUl
- e8XCrV2gUHpUhS3u9ZmvApjqdCHb8VCNM+qjc3++n34Uq3IIP6hvSyPuqoXaBdZZ
- kDeIGMLi33YAJtvMmt0GW2GRHrKlaAQY/UVkYJ/PNkZDACGMPFLFE8XVDBLJXZXO
- JYX96YZZhMBLA/YePw4/cgbo6gUZABEBAAGJASUEGAEKAA8FAlM7MyYCGwwFCQHg
- AdoACgkQAryY9B75f0bzHQgAxfUKgixemx0BehJZz6Hk0vxL6Z4vnLav7zXhKBXV
- /EUuOPeddaizXIjaoCF+WfXGuKEPYmOEBAqmZEnesKbQIdYWvti3qD2Iwxjm5yBp
- l/qa9LGbKwGUDmWkEdfTOEutX0J/sf8FhT48x5J604slayV2dOsrmmhhx+UPOHXH
- tCWlPH5UkHjT4OZJAJOWH83fwjutGmBipOljw1aigW7/QIDpo5SDweZaSxbg78ml
- vYL8maxm0rZE4WNTHyz5tUJvtwBSItVrRbnHD58SGUYCLLo6v2Iv5KpnvbaEQ3Nf
- d459JRFXNFSvKH58T0JRKVkaUw/SReBraTxQM7ftRgTHCQ==
- =kpCL
- -----END PGP PUBLIC KEY BLOCK-----
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement