Delegation in Bitcoin: Part 3 – CoinGeek

Home » Tech » Delegation in Bitcoin: Part 3

This post was first published on Medium. Read Part 2 here.
Previously, we have introduced two ways to delegate the right to spend one’s bitcoin: one at Script level, the other at transaction level.
We generalize the former to delegate to any script/smart contract, instead of a public key only. It allows one to authorize arbitrary smart contract to spend one’s bitcoin.
two hands transfering a thing
The full code is shown below:
Contract DelegateToScript
Line 9 checks the delegated script is signed and thus authorized by the owner. Line 12 and 13 ensure the delegated script goes into the spending transaction’s output as the new locking script using OP_PUSH_TX, similar to the emulation of Pay to Script Hash (P2SH).
Watch: CoinGeek New York presentation, The Path to BitCoin Adoption: How to Turn the Entire Web into Bitcoin Apps

New to Bitcoin? Check out CoinGeek’s Bitcoin for Beginners section, the ultimate resource guide to learn more about Bitcoin—as originally envisioned by Satoshi Nakamoto—and blockchain.
Bloom filters being sunset in BSV is a little more interesting because they are incompatible with massive scaling due to the inefficient way that it breaks out address data for light clients.
The proposed rules will see an increase in fines by up to fivefold and will also be accompanied by revocation of business licenses and threat of imprisonment as a last resort.
sCrypt developed a novel approach to emulate any SIGHASH flag by coding the logic in a smart contract. It requires no protocol change and is more practical than adding a hardcoded flag through a fork.
sCrypt demonstrated how to implement Taproot on the original Bitcoin using a contractless contract and shows that its follow-up proposal, Graftroot, can be implemented in a similar fashion.