BlockchainYM
Newbie
Offline
Activity: 8
Merit: 1
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
August 19, 2021, 01:34:23 PM |
|
The first one uses Bitcoin script to implement string concatenation in the stack? I did not find a valid opcode in the latest Bitcoin script?
There aren't any string concatenation OPs in bitcoin simply because there is no use cases for it in a payment system. There used to be a couple of disabled OP codes in early version that are completely removed now that use to deal with string manipulation: OP_CAT, OP_SUBSTR, OP_LEFT, OP_RIGHT Second, how can I better learn the Bitcoin script, or can I recommend some good information?
I don't know any source that explains everything but chapter 7 of the book called "Mastering Bitcoin" has a good explanation of the standard scripts that should give you enough information about how things work: https://github.com/bitcoinbook/bitcoinbook/blob/develop/ch07.asciidoc(You may want to start in chapter 6 where it explains transactions). For additional information and details you should check the source code and then ask questions here about any part that is unclear: https://github.com/bitcoin/bitcoin/blob/master/src/script/interpreter.cppI'm sorry .When I saw tapscript, I paid attention to this sentence: Many previously disabled opcodes are redefined to be OP_SUCCESS opcodes that unconditionally render the entire script valid to simplify soft fork upgrades. I don't quite understand what is the use of OP_SUCCESS opcodes? Could you explain that?
|
|
|
|
garlonicon
|
OP_SUCCESS simply means "this script is automatically valid", it is the opposite of OP_RETURN that means "this script is automatically invalid". It is needed, because if you want to make upgrades in the future, you want a situation where old nodes consider new scripts as valid, so old nodes will see OP_SUCCESS and accept that as valid without any conditions, but new nodes will add some restrictions.
|
|
|
|
cygan
Legendary
Offline
Activity: 3262
Merit: 8491
icarus-cards.eu
|
once again i came across a very interesting and very informative article today about the upcoming taproot upgrade, which i would like to share with you guys ![](https://ip.bitcointalk.org/?u=https%3A%2F%2Fstatic.seekingalpha.com%2Fuploads%2F2021%2F8%2F17%2F53609103-16292071678254488.png&t=665&c=gQ_vzlOPkhBaMQ) - At the beginning of November, Bitcoin will undergo a major upgrade known as ‘Taproot’.
- Taproot will update Bitcoin’s back-end code, increase privacy, transparency, and fungibility, and improve Bitcoin’s smart contract functionality.
- After Taproot, the Bitcoin Network will support decentralized finance applications, oracle input data, and simple executable scripts.
https://seekingalpha.com/article/4450212-the-bitcoin-taproot-upgrade-is-bigger-than-you-think
|
|
|
|
BlockchainYM
Newbie
Offline
Activity: 8
Merit: 1
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
August 20, 2021, 01:17:58 AM |
|
OP_SUCCESS simply means "this script is automatically valid", it is the opposite of OP_RETURN that means "this script is automatically invalid". It is needed, because if you want to make upgrades in the future, you want a situation where old nodes consider new scripts as valid, so old nodes will see OP_SUCCESS and accept that as valid without any conditions, but new nodes will add some restrictions.
I don’t know if you have noticed the word redefine. I don’t understand how the disabled opcode is redefined by OP_SUCCESS.
|
|
|
|
pooya87
Legendary
Offline
Activity: 3556
Merit: 10798
|
I don’t know if you have noticed the word redefine. I don’t understand how the disabled opcode is redefined by OP_SUCCESS.
It's very simple, the script interpreter starts with evaluating the output script being spent and when it is version 1 witness script it uses a different route for evaluation. That way it executes the script in another method that checks the OP code to be in a certain range (including those disabled OP codes) and considers them OP_SUCCESS and simply returns true when they are in a Taproot script. In a way it is bypassing the old evaluation where these disabled OP codes are rejected.
|
|
|
|
Pmalek
Legendary
Offline
Activity: 2870
Merit: 7412
Playgram - The Telegram Casino
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
August 21, 2021, 07:39:04 AM Last edit: August 22, 2021, 06:35:55 AM by Pmalek Merited by JayJuanGee (1) |
|
"Defi" is just the latest media-hype buzzword. Asking anyone "what does Defi actually mean?" is a good way of discovering what kind of person they are (hint: the more confident and/or specific reply they give, the more full of shit they are ![Smiley](https://bitcointalk.org/Smileys/default/smiley.gif) ) It's part of a newsmedia storyline designed to influence how people think about the cryptocurrency marketplace, and so not particularly reflecting reality I hope I won't sign sound full of shit, but I don't think all aspects of DeFi are useless. Especially the opportunities that have arisen in the money borrowing/lending niche. If you are a law-abiding, tax-paying citizen, you know that every time you sell your Bitcoin or exchange it for another cryptocurrency, you create taxable events. But if you need cash, you can provide your coins as collateral and receive a loan, and that doesn't generate taxable events. Of course, there is interest and other fees to account for, but I don't think this is bad for those who can't get a personal loan, don't want or can use the services of traditional banks. Then there is the interest you can get by lending out your money to such platforms.
|
|
|
|
▄▄███████▄▄███████ ▄███████████████▄▄▄▄▄ ▄████████████████████▀░ ▄█████████████████████▄░ ▄█████████▀▀████████████▄ ██████████████▀▀█████████ █████████████████████████ ██████████████▄▄█████████ ▀█████████▄▄████████████▀ ▀█████████████████████▀░ ▀████████████████████▄░ ▀███████████████▀▀▀▀▀ ▀▀███████▀▀███████ | ▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄ Playgram.io ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀ | ▄▄▄░░ ▀▄ █ █ █ █ █ █ █ ▄▀ ▀▀▀░░
| │ | ▄▄▄███████▄▄▄ ▄▄███████████████▄▄ ▄███████████████████▄ ▄██████████████▀▀█████▄ ▄██████████▀▀███▄██▐████▄ ██████▀▀████▄▄▀▀█████████ ████▄▄███▄██▀█████▐██████ ██████████▀██████████████ ▀███████▌▐██▄████▐██████▀ ▀███████▄▄███▄████████▀ ▀███████████████████▀ ▀▀███████████████▀▀ ▀▀▀███████▀▀▀ | | │ | ██████▄▄███████▄▄████████ ███▄███████████████▄░░▀█▀ ███████████░█████████░░█ ░█████▀██▄▄░▄▄██▀█████░█ █████▄░▄███▄███▄░▄██████ ████████████████████████ ████████████████████████ ██░▄▄▄░██░▄▄▄░██░▄▄▄░███ ██░░░█░██░░░█░██░░░█░████ ██░░█░░██░░█░░██░░█░░████ ██▄▄▄▄▄██▄▄▄▄▄██▄▄▄▄▄████ ███████████████████████ ███████████████████████ | | │ | ► | |
|
|
|
Wind_FURY
Legendary
Offline
Activity: 3024
Merit: 1880
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
August 21, 2021, 09:56:34 AM |
|
is it even possible to do Defi applications on Bitcoin? "Defi" is just the latest media-hype buzzword. Asking anyone "what does Defi actually mean?" is a good way of discovering what kind of person they are (hint: the more confident and/or specific reply they give, the more full of shit they are ![Smiley](https://bitcointalk.org/Smileys/default/smiley.gif) ) It's part of a newsmedia storyline designed to influence how people think about the cryptocurrency marketplace, and so not particularly reflecting reality It’s very laughable that the community that are supporting “DeFi” are saying “Reject Regulations”, are also the same people who are calling for the goverment to stop the U.S. Congress from passing a law that would tax its participants. The Irony of “DeFi”.
|
| .SHUFFLE.COM.. | ███████████████████████ ███████████████████████ ███████████████████████ ███████████████████████ ███████████████████████ ███████████████████████ ███████████████████████ ███████████████████████ ███████████████████████ ███████████████████████ ███████████████████████ ███████████████████████ ███████████████████████ | ███████████████████████ ███████████████████████ ███████████████████████ ███████████████████████ ███████████████████████ ███████████████████████ ███████████████████████ ███████████████████████ ███████████████████████ ███████████████████████ ███████████████████████ ███████████████████████ ███████████████████████ | . ...Next Generation Crypto Casino... |
|
|
|
pooya87
Legendary
Offline
Activity: 3556
Merit: 10798
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
August 22, 2021, 03:00:58 AM |
|
I hope I won't sign full of shit, but I don't think all aspects of DeFi are useless.
The idea looks good on paper but it stops there. If you are a law-abiding, tax-paying citizen, you know that every time you sell your Bitcoin or exchange it for another cryptocurrency, you create taxable events. But if you need cash, you can provide your coins as collateral and receive a loan, and that doesn't generate taxable events. Of course, there is interest and other fees to account for,
Your argument is flawed. For starters as you mentioned there is an interest involved which could be higher than the tax you have to pay, and that is basically usury! But more importantly you are comparing an act on a centralized platform (CEX) with an act on what is assumed to be decentralized (DeFi). Change the first part to DEX (no tax report) or change the second part to a centralized token (mandatory tax report) and you'll see that you no longer have an argument. And finally another big problem is that there is no security in what you described simply because there is no decentralized cryptographic connection between the two chains (eg. bitcoin and a shittoken on a token creation platform like ethereum) and why would you even need a token in first place? You give them bitcoin and receive fiat, when you pay back the fiat you receive the bitcoin. That token doesn't solve anything in this process since the token doesn't ensure return of bitcoin or fiat. Not to mention that bitcoin script language is capable of creating smart contracts needed for a loan which is more than enough.
|
|
|
|
Pmalek
Legendary
Offline
Activity: 2870
Merit: 7412
Playgram - The Telegram Casino
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
August 22, 2021, 06:52:57 AM |
|
For starters as you mentioned there is an interest involved which could be higher than the tax you have to pay, and that is basically usury! Not necessarily. Based on some very basic knowledge I have on this, the interest rates on some platforms are around 10%. Some offer less, some more. The taxes differ from country to country, but let's say that 15% to 20% is the average value. Maybe I don't want to sell my bitcoin today and buy back less in a year from now when I pay back my loan. But more importantly you are comparing an act on a centralized platform (CEX) with an act on what is assumed to be decentralized (DeFi). Change the first part to DEX (no tax report) or change the second part to a centralized token (mandatory tax report) and you'll see that you no longer have an argument. You lost me here, sorry. Not to mention that bitcoin script language is capable of creating smart contracts needed for a loan which is more than enough. Are there such platforms and solutions that provide such services?
|
|
|
|
▄▄███████▄▄███████ ▄███████████████▄▄▄▄▄ ▄████████████████████▀░ ▄█████████████████████▄░ ▄█████████▀▀████████████▄ ██████████████▀▀█████████ █████████████████████████ ██████████████▄▄█████████ ▀█████████▄▄████████████▀ ▀█████████████████████▀░ ▀████████████████████▄░ ▀███████████████▀▀▀▀▀ ▀▀███████▀▀███████ | ▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄ Playgram.io ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀ | ▄▄▄░░ ▀▄ █ █ █ █ █ █ █ ▄▀ ▀▀▀░░
| │ | ▄▄▄███████▄▄▄ ▄▄███████████████▄▄ ▄███████████████████▄ ▄██████████████▀▀█████▄ ▄██████████▀▀███▄██▐████▄ ██████▀▀████▄▄▀▀█████████ ████▄▄███▄██▀█████▐██████ ██████████▀██████████████ ▀███████▌▐██▄████▐██████▀ ▀███████▄▄███▄████████▀ ▀███████████████████▀ ▀▀███████████████▀▀ ▀▀▀███████▀▀▀ | | │ | ██████▄▄███████▄▄████████ ███▄███████████████▄░░▀█▀ ███████████░█████████░░█ ░█████▀██▄▄░▄▄██▀█████░█ █████▄░▄███▄███▄░▄██████ ████████████████████████ ████████████████████████ ██░▄▄▄░██░▄▄▄░██░▄▄▄░███ ██░░░█░██░░░█░██░░░█░████ ██░░█░░██░░█░░██░░█░░████ ██▄▄▄▄▄██▄▄▄▄▄██▄▄▄▄▄████ ███████████████████████ ███████████████████████ | | │ | ► | |
|
|
|
pooya87
Legendary
Offline
Activity: 3556
Merit: 10798
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
August 22, 2021, 07:44:06 AM |
|
Not necessarily. Based on some very basic knowledge I have on this, the interest rates on some platforms are around 10%. Some offer less, some more. The taxes differ from country to country, but let's say that 15% to 20% is the average value. Maybe I don't want to sell my bitcoin today and buy back less in a year from now when I pay back my loan.
Fair enough. You lost me here, sorry.
Tax reports are mandatory when using a centralized exchange that already reports you to IRS not when using a DEX that doesn't leave that much trace behind. The same laws would apply to the loans if the platform were centralized. Not to mention that Usury is illegal in some parts of the world and in some other parts only the interest rate are regulated. Besides if some day decentralized loans on a centralized platform become a thing, additional laws will apply such as taxing the profit the lender makes. Even if it is fully decentralized the lender and borrower can still be taxed. So you can't use the argument of lack of taxes as a benefit of DeFi Are there such platforms and solutions that provide such services?
I haven't searched but it shouldn't be that hard to write https://en.bitcoin.it/wiki/Smart_Property
|
|
|
|
Carlton Banks
Legendary
Offline
Activity: 3430
Merit: 3080
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
August 22, 2021, 09:23:48 AM Last edit: August 28, 2021, 12:58:45 PM by Carlton Banks |
|
the interest rates on some platforms are around 10%.
ot, but... red flag rate of return IMO any time ROI is at or approaching >10%, there is a strong tendency for the company/platform to pay out reliably... for a while, and then reliably disappear into a puff of smoke I would suggest not talking about this kind of thing, lest you be accused (fairly or unfairly) of shilling for such schemes
|
Vires in numeris
|
|
|
BlockchainYM
Newbie
Offline
Activity: 8
Merit: 1
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
August 23, 2021, 01:57:09 PM Last edit: August 23, 2021, 05:13:24 PM by achow101 |
|
There aren't any string concatenation OPs in bitcoin simply because there is no use cases for it in a payment system. There used to be a couple of disabled OP codes in early version that are completely removed now that use to deal with string manipulation: OP_CAT, OP_SUBSTR, OP_LEFT, OP_RIGHT
There absolutely are use cases! Unfortunately the original construction could be abused to cause nodes to require petabytes of ram ... Fixing that requires imposing additional restrictions, and without planning for specific uses it can be hard to be confident that the restrictions don't break them. ... and demand for fancy use cases seems pretty limited-- which doesn't motivate people to do the design and validation work needed to reintroduce the operations. I already know about tapscript in this link ( https://bitcoinops.org/en/topics/tapscript/), but I still can’t understand it thoroughly. Can you help me? Like information that is easier to understand. Especially about Many previously disabled opcodes are redefined to be OP_SUCCESS opcodes that unconditionally render the entire script valid to simplify soft fork upgrades. Can you explain it to me in detail? I don't quite understand what this upgrade brings about the OP_SUCCESS opcode?
I don’t know if you have noticed the word redefine. I don’t understand how the disabled opcode is redefined by OP_SUCCESS.
It's very simple, the script interpreter starts with evaluating the output script being spent and when it is version 1 witness script it uses a different route for evaluation. That way it cutes the script in another method that checks the OP code to be in a certain range (including those disabled OP codes) and considers them OP_SUCCESS and simply returns true when they are in a Taproot script. In a way it is bypassing the old evaluation where these disabled OP codes are rejected. I read the code, but I didn’t understand what is the purpose of this upgrade of OP_SUCCESS? Can you give me a detailed explanation? Thank you
|
|
|
|
j2002ba2
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
August 23, 2021, 03:45:49 PM |
|
I read the code, but I didn’t understand what is the purpose of this upgrade of OP_SUCCESS? Can you give me a detailed explanation? Thank you
This makes taproot upgradable.
|
|
|
|
BlockchainYM
Newbie
Offline
Activity: 8
Merit: 1
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
August 24, 2021, 01:04:23 AM |
|
I read the code, but I didn’t understand what is the purpose of this upgrade of OP_SUCCESS? Can you give me a detailed explanation? Thank you
This makes taproot upgradable. I know, but can you tell me the specific meaning of tapscript (Many previously disabled opcodes are redefined to be OP_SUCCESS opcodes that unconditionally render the entire script valid to simplify soft fork upgrades.)? I don’t understand what OP_SUCCESS specifically redefines? How is it used?
|
|
|
|
pooya87
Legendary
Offline
Activity: 3556
Merit: 10798
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
August 24, 2021, 02:48:31 AM |
|
I read the code, but I didn’t understand what is the purpose of this upgrade of OP_SUCCESS? Can you give me a detailed explanation? Thank you
If you are familiar with bitcoin scripts then you can think of OP_SUCCESS as something very similar to OP_NOP. We already have a couple of them in bitcoin, for example OP_NOP2 which made activating OP_CheckLocktimeVerify possible through a soft-fork. The only difference is that OP_NOPs don't do anything (interpreter simply moves to next OP) but OP_SUCCESS stops there and returns TRUE no matter what comes next.
|
|
|
|
j2002ba2
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
August 24, 2021, 10:33:01 AM |
|
I know, but can you tell me the specific meaning of tapscript (Many previously disabled opcodes are redefined to be OP_SUCCESS opcodes that unconditionally render the entire script valid to simplify soft fork upgrades.)? I don’t understand what OP_SUCCESS specifically redefines? How is it used?
In tapscript when the interpreter encounters one of the OP_SUCCESSx opcodes, it instantly succeeds. In the future this might change, and some opcodes might enforce restrictions - soft fork. But the future is not here yet, so nobody knows what and how exactly would happen. So there was OP_CAT at the very beginning, then it was disabled, and now inside tapscript there's OP_SUCCESS126 instead, which might change (in future tapscript version) to something else (instead of instant success). Here is the list of the codes redefined as OP_SUCCESSx, the red ones were disabled in usual script: OP_RESERVED = 0x50,
OP_VER = 0x62,
OP_CAT = 0x7e, OP_SUBSTR = 0x7f, OP_LEFT = 0x80, OP_RIGHT = 0x81, OP_SIZE = 0x82,
OP_INVERT = 0x83, OP_AND = 0x84, OP_OR = 0x85, OP_XOR = 0x86,
OP_RESERVED1 = 0x89, OP_RESERVED2 = 0x8a,
OP_2MUL = 0x8d, OP_2DIV = 0x8e,
OP_MUL = 0x95, OP_DIV = 0x96, OP_MOD = 0x97, OP_LSHIFT = 0x98, OP_RSHIFT = 0x99,
and everything between OP_CHECKSIGADD = 0xba,
and OP_INVALIDOPCODE = 0xff,
|
|
|
|
BlockchainYM
Newbie
Offline
Activity: 8
Merit: 1
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
August 28, 2021, 12:47:47 PM |
|
I know, but can you tell me the specific meaning of tapscript (Many previously disabled opcodes are redefined to be OP_SUCCESS opcodes that unconditionally render the entire script valid to simplify soft fork upgrades.)? I don’t understand what OP_SUCCESS specifically redefines? How is it used?
In tapscript when the interpreter encounters one of the OP_SUCCESSx opcodes, it instantly succeeds. In the future this might change, and some opcodes might enforce restrictions - soft fork. But the future is not here yet, so nobody knows what and how exactly would happen. So there was OP_CAT at the very beginning, then it was disabled, and now inside tapscript there's OP_SUCCESS126 instead, which might change (in future tapscript version) to something else (instead of instant success). Here is the list of the codes redefined as OP_SUCCESSx, the red ones were disabled in usual script: OP_RESERVED = 0x50,
OP_VER = 0x62,
OP_CAT = 0x7e, OP_SUBSTR = 0x7f, OP_LEFT = 0x80, OP_RIGHT = 0x81, OP_SIZE = 0x82,
OP_INVERT = 0x83, OP_AND = 0x84, OP_OR = 0x85, OP_XOR = 0x86,
OP_RESERVED1 = 0x89, OP_RESERVED2 = 0x8a,
OP_2MUL = 0x8d, OP_2DIV = 0x8e,
OP_MUL = 0x95, OP_DIV = 0x96, OP_MOD = 0x97, OP_LSHIFT = 0x98, OP_RSHIFT = 0x99,
and everything between OP_CHECKSIGADD = 0xba,
and OP_INVALIDOPCODE = 0xff,
Thank you. Can you tell me a demonstration website with a full transaction script?
|
|
|
|
BlockchainYM
Newbie
Offline
Activity: 8
Merit: 1
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
August 28, 2021, 02:19:16 PM |
|
I know, but can you tell me the specific meaning of tapscript (Many previously disabled opcodes are redefined to be OP_SUCCESS opcodes that unconditionally render the entire script valid to simplify soft fork upgrades.)? I don’t understand what OP_SUCCESS specifically redefines? How is it used?
In tapscript when the interpreter encounters one of the OP_SUCCESSx opcodes, it instantly succeeds. In the future this might change, and some opcodes might enforce restrictions - soft fork. But the future is not here yet, so nobody knows what and how exactly would happen. So there was OP_CAT at the very beginning, then it was disabled, and now inside tapscript there's OP_SUCCESS126 instead, which might change (in future tapscript version) to something else (instead of instant success). So there was OP_CAT at the very beginning, then it was disabled, and now inside tapscript there's OP_SUCCESS126 instead, which might change (in future tapscript version) to something else (instead of instant success). Where can I see this op_success126? can you give me what opcodes have been replaced by op_success? I didn't find too much useful information, can you tell me?
|
|
|
|
|
Daltonik
Legendary
Offline
Activity: 2562
Merit: 1499
|
![](https://bitcointalk.org/Themes/custom1/images/post/xx.gif) |
September 14, 2021, 01:26:56 PM |
|
The developers of Bitcoin Core itself have announced the release of the 22.0 version of the client, which is the first major release supporting the upcoming update of the Taproot protocol.
|
|
|
|
|