Bitcoin Forum
May 04, 2024, 02:56:31 AM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Proof-of-work outputs  (Read 787 times)
Taras (OP)
Legendary
*
Offline Offline

Activity: 1386
Merit: 1053


Please do not PM me loan requests!


View Profile WWW
August 28, 2014, 11:49:59 PM
Last edit: August 29, 2014, 12:37:22 AM by Taras
 #1

Could we theoretically create an output that could only be spent after some proof-of-work?
stringtoconcatenate OP_CAT OP_SHA256 00000000839a8e6886ab5951d76f411475428afc90947ee320161bbf18eb6048 OP_LESSTHAN OP_VERIFY OP_DROP OP_DUP OP_HASH160 e6ee700d3b22c43b4ad5d4144ae16d35a0013bc0 OP_EQUALVERIFY OP_CHECKSIG

Our scriptsig would have first the signature and then the nonce.
The nonce and a string in the script - perhaps a recent headline, to prove work wasn't done prior to the transaction - would be concatenated (if OP_CAT wasn't disabled) and then we'd get the SHA-256 hash of the combined string. If that hash is less than a target, then yes, we can check the signature.

I think this could be useful (if not fun) for a trust fund, or proof-of-illiquidity, if our target has enough leading zeroes to make it (on average) take a few days to find a working nonce, and therefore make the output spendable. Perhaps the target could take years with a GPU farm.

Any comments? Would this be a good/bad idea? (assuming of course OP_CAT was enabled?)
Even if you use Bitcoin through Tor, the way transactions are handled by the network makes anonymity difficult to achieve. Do not expect your transactions to be anonymous unless you really know what you're doing.
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
jl2012
Legendary
*
Offline Offline

Activity: 1792
Merit: 1093


View Profile
August 29, 2014, 04:58:39 AM
 #2

Could we theoretically create an output that could only be spent after some proof-of-work?
stringtoconcatenate OP_CAT OP_SHA256 00000000839a8e6886ab5951d76f411475428afc90947ee320161bbf18eb6048 OP_LESSTHAN OP_VERIFY OP_DROP OP_DUP OP_HASH160 e6ee700d3b22c43b4ad5d4144ae16d35a0013bc0 OP_EQUALVERIFY OP_CHECKSIG

Our scriptsig would have first the signature and then the nonce.
The nonce and a string in the script - perhaps a recent headline, to prove work wasn't done prior to the transaction - would be concatenated (if OP_CAT wasn't disabled) and then we'd get the SHA-256 hash of the combined string. If that hash is less than a target, then yes, we can check the signature.

I think this could be useful (if not fun) for a trust fund, or proof-of-illiquidity, if our target has enough leading zeroes to make it (on average) take a few days to find a working nonce, and therefore make the output spendable. Perhaps the target could take years with a GPU farm.

Any comments? Would this be a good/bad idea? (assuming of course OP_CAT was enabled?)

Your example won't work even if OP_CAT is enabled because OP_LESSTHAN could only handle 32-bit integers. You need OP_SUBSTR (which is also disabled) to split the string first and use multiple OP_LESSTHAN to make the comparison.

Anyway, I can't see how a probabilistic proof of illiquidity could be useful in any scenario.

Donation address: 374iXxS4BuqFHsEwwxUuH3nvJ69Y7Hqur3 (Bitcoin ONLY)
LRDGENPLYrcTRssGoZrsCT1hngaH3BVkM4 (LTC)
PGP: D3CC 1772 8600 5BB8 FF67 3294 C524 2A1A B393 6517
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!