4 ms·
It's unfortunate that most bitcoin-related posts require the reader to have a lot of in-depth knowledge about the details of how bitcoin transactions work. As s
by bramblerose 11y ago
It's unfortunate that most bitcoin-related posts require the reader to have a lot of in-depth knowledge about the details of how bitcoin transactions work. As somewhat-interested-person, I can /just/ figure out what the gist of the story is ('Alice can show she knows the answer and can then transfer the answer in an atomic payment'), but it's completely unclear to me how either part works. The "The buyer makes his payment to the following ScriptPubkey" section is maybe the worst offender in that respect -- apparently that script is supposed to be obvious, but it's not clear to me what it does /at all/.
- ryan-c 11y agoHere's my attempt at explanatory comments - the ScriptPubkey is a program (written in Bitcoin Script) which is attached to an output of a Bitcoin transaction - parameters must be provided that make it return "true". # Compute the SHA256 of the value on the top of the stack (spender input), # then add the result to the top of the stack OP_SHA256 # Check whether this value is equal to Y, the hash of the key under which # the solution was encrypted. <Y> OP_EQUAL # If the correct key was provided, add the seller's public key to the stack OP_IF <Seller Pubkey> # Otherwise, if it has been 100 blocks or more, add the buyer's public key # to the stack so they may refund themselves if the seller does not complete # the protocol OP_ELSE <block_height+100> OP_CHECKLOCKTIMEVERIFY OP_DROP <Buyer Pubkey> OP_ENDIF # Verify the signature against the public key on the top of the stack OP_CHECKSIG
- bramblerose 11y agoThank you, that clarifies a lot.
- jnbiche 11y agoGood explanation. By way of background, I'll add that Bitcoin Script runs on a stack machine, similar to Forth (except Script is non-Turing complete).
- ptrincr 11y agoYep, very true. However the Internet itsself was a mystery to most people during its early life. The technology was refined, made more user friendly and opened up to the masses. The same happened with Bitcoin (as a payment method) and I'm pretty sure someone will find way to make this simple enough for the layman to use.
- ssharp 11y agoThis drum keeps getting pounded, but a cogent answer to the question "why would I use Bitcoin when I can use existing payment methods?" has yet to be given. The benefits of the internet were pretty clear and obvious. The benefits of Bitcoin are neither clear nor obvious.
- stormbrew 11y agoThis seems very hindsight driven to me. I didn't realize how powerful the internet could be for news until Di died and I heard about it online something like a half hour before my parents confirmed it on TV. My mother didn't trust the internet for film information until imdb had existed for many years, still relying on yearly Leonard Maltin books all the time. Obviousness doesn't tend to come until something compels it. But in the meantime, people who recognize it before others do are working to profit off that difference.
- kanzure 11y ago> "why would I use Bitcoin when I can use existing payment methods?" Bitcoin can be used for other reasons beyond payment system transactions; for example, a bunch of coins are stored in cold wallets, as a physical store of value which cannot be confiscated. Market fluctuations still happen but that's unrelated to physical coin storage.
- TylerE 11y agoI've never believed this line of logic at all. You really think in a serious shit-hits-the-fan scenario (be it natural disaster, government takeover, whatever) you are going to have reliable internet connectivity?
- Uptrenda 11y agoBelieve me - it's not just you. Bitcoin has always been like this. You'll have one smart guy who says something fairly interesting but somehow they never go into enough detail for anyone else to be able to reproduce their results. Because of this - if you want to be able to do anything interesting working by yourself is still the best way to do it. Coincidentally: I was actually working on using ZKPs before this was posted and I had a hell of time even getting the library installed (Snarkfront.) In the end I resorted to emailing one of the devs who managed to get it to work since I'm probably one of less than 50 people world-wide who have ever used Snarklib before - (a group that would probably include Greg Maxwell too.) So yes - the bleeding edge stuff unfortunately does require a lot of time to master but sometime in the future I hope to post some proper documentation and put a virtual machine online so normal devs can play with this stuff without having to waste hours.
- ewillbefull 11y agoThe simple explanation -- which I unfortunately left out of my slides but did elaborate on during my talk -- is that Bitcoin has a way for you to send money to someone contingent on them producing the preimage of a SHA256 hash. The remainder of the script allows you to get your money back if the person doesn't have or doesn't provide the preimage within a certain amount of time. If you use a zero-knowledge proof to enforce that the preimage of the hash is a key which unlocks some data you want, this becomes a powerful tool for building exotic protocols or performing risky transactions. It also doesn't cost much on the Bitcoin side of things.
- mkramlich 11y agothis is the clearest summary I've seen, thank you