LocalCryptos Launches Bitcoin Cash Trading As 5th Crypto

[ad_1]

Users can now buy and sell Bitcoin Cash (BCH) on the most popular non-custodial peer-to-peer crypto market.

Almost a year has passed since we added a new cryptocurrency to LocalCryptos, and many of you have requested Bitcoin Cash as the next version of our non-custodial formula. The wait is finally over.

As of today, peer-to-peer Bitcoin Cash trading is available on LocalCryptos.

How will non-custodial escrow work on Bitcoin Cash?

Bitcoin Cash is a fork of BTC, which means it has similar Bitcoin script smart contract capabilities. Unlike our non-depository escrow scripts for Bitcoin, Litecoin, and Dash, LocalCryptos operates the op code OP_CHECKDATASIG which is only available in Bitcoin Cash transactions.

A regular user will not notice a difference between this new type of escrow, as the result is virtually identical to LocalCryptos’ non-custodial BTC escrow script. However, from a programmers point of view, the non-custodial Bitcoin Cash P2SH script is more simplistic and intuitive, and it has some advantages.

As with all escrows on LocalCryptos, it is technically impossible for us to spend BCH on escrow. We only intervene when there is a payment dispute, and once involved, we only have the option of authorizing the buy-back of the BCH by either the buyer or the seller. Click here to learn more about the crypto magic that makes this possible.

Of course, your Bitcoin Cash wallet on LocalCryptos is also self-guarding. Your keys, your coins. Developers can check out our annotated Bitcoin Cash script templates at the bottom of this announcement.

Some facts about Bitcoin Cash: Bitcoin Cash (BCH) was born in 2017 from a Bitcoin fork. It was created out of demand for a variant of Bitcoin to process a higher number of transactions per block, which proponents say would require increasing the block size of the blockchain. Due to this approach to the scalability issue, Bitcoin Cash does not support separate cookie transactions (unlike Bitcoin and Litecoin). Despite the differences, the two coins still share many similarities, they both mine coins under the Proof-of-Work consensus algorithm, their total coin supply is capped at 21 million, and both support the pay-to-public-key-hash (P2PKH) and pay-to-script-hash (P2SH) addresses. Average Bitcoin Cash transaction fees are usually less than 1 virtually free! How Bitcoin Cash Non-Custody Escrow Works

As with the non-custodial scripts we have developed for other cryptos, our non-custodial Bitcoin Cash escrow code is open source.

This script works in a manner similar to a multi-signed Bitcoin transaction, except that the parties involved do not need to agree on how and when the Bitcoin Cash outputs are spent. The oracle which can be the seller, the buyer or the arbiter, depending on the circumstances of the trade does not have the ability to put conditions on the transaction, unlike traditional multi-signature portfolios.

This is because with a traditional multi-signature wallet all parties have to sign a full transaction including all exits and entries, whereas with a non-custodial escrow transaction that uses OP_CHECKDATASIG the oracle simply needs to give a signature to the winner. which they can use at any time to unlock the BCH in any way they choose.

This type of chain escrow mechanism gives the buyer and seller the ability to trade without authorization, and the arbitrator the ability to act as a non-custodian mediator in the event of a payment dispute.

Sellers deposit in escrow

To move Bitcoin Cash into escrow, the seller generates a transaction with two exits. One outlet is escrow to the buyer and the other is a refundable charge. If the transaction is not successful, the fees can be claimed by the seller.

In ordinary trades, the seller will allow the buyer to spend the escrow release. This does not require our intervention. Likewise, if the buyer chooses to cancel the transaction on their own, the seller can spend the exit without our help. The first scenario is a release and the second is a return.

In the event of a payment dispute, an arbitrator can intervene and act as a mediator. The arbitrator can only allow the seller or the buyer to spend, by design. The fee script allows the arbiter to collect a fee after a blocked deposit or the seller to request a refund if the transaction fails.

Escrow output template OP_DUP # We need to reuse the byte afterwards # Get the hashed public keys we need to compare (ours and the oracle) OP_1 OP_EQUAL OP_IF
# Oracle release key
# Spending ad key OP_ELSE OP_DUP OP_2 # = release of the arbitrator OP_EQUAL OP_IF
# Oracle release key
# Spender ad key OP_ELSE OP_DUP OP_3 # = buyer’s return OP_EQUAL OP_IF
# Oracle release key
# Spender pub key OP_ELSE OP_DUP OP_4 # = return from arbiter OP_EQUALVERIFY # must be true, otherwise the message is unknown
# Oracle release key
# Spender pub key OP_ENDIF OP_ENDIF OP_ENDIF # Put the hashed public keys on the alt stack OP_TOALTSTACK OP_TOALTSTACK # The stack is effectively reset at the entry # On the alt stack we have: [ hash160(SpenderPubKey), hash160(OraclePubKey) ]
# Add the nonce to the escrow key to make the OP_CAT message # The stack is [ …, , <0x01 || EscrowKey> ]
OP_SWAP # Use it later; first check the hash of the oracle public key OP_DUP OP_HASH160 OP_FROMALTSTACK # Get the hashed pub key from the stack alt OP_EQUALVERIFY # The public key is extracted; now verify oracle signature OP_CHECKDATASIGVERIFY # Now verify sender OP_DUP OP_HASH160 OP_FROMALTSTACK OP_EQUALVERIFY OP_CHECKSIG Charge output template

This is the cost portion of the trade. If the transaction fails, the fees can be claimed by the seller; if the transaction is successful, the exit fee will be claimed by LocalCryptos.

OP_DEPTH # Count the size of the stack OP_2 OP_EQUAL # Does the input stack only have two elements? OP_IF # If yes, these are the owner’s collection costs; Simple PKH OP_DUP OP_HASH160

OP_EQUALVERIFY OP_CHECKSIG OP_ELSE # Seller spends “returned” (i.e. canceled) escrow OP_DUP OP_3 # = return from buyer OP_EQUAL OP_IF
# Oracle pub key OP_ELSE OP_DUP OP_4 # = arbiter return OP_EQUALVERIFY # must be true, otherwise the message is unknown
# Oracle publication key OP_ENDIF
# Spender pub key # Put the hashed public keys on the alt stack OP_TOALTSTACK OP_TOALTSTACK # The stack is effectively reset at the entry # On the alt stack we have: [ hash160(SpenderPubKey), hash160(OraclePubKey) ]
# Add the nonce to the escrow key to make the OP_CAT message # The stack is [ …, , <0x01 || EscrowKey> ]
OP_SWAP # Use it later; first check the hash of the oracle public key OP_DUP OP_HASH160 OP_FROMALTSTACK # Get the hashed pub key from the stack alt OP_EQUALVERIFY # The public key is extracted; now check the oracle signature OP_CHECKDATASIGVERIFY # Check the sender OP_DUP OP_HASH160 OP_FROMALTSTACK OP_EQUALVERIFY OP_CHECKSIG OP_ENDIF Signature of the script

To spend an escrow outflow, the spender must provide in their Bitcoin CashSig transaction script:

# Example: 1
is a byte corresponding to the running situation. 1: Escrow is released by seller 2: Escrow is released by arbitrator 3: Escrow is returned by buyer 4: Escrow is returned by arbitrator is the public key of the person signing the release / return message. 1: = 2: = (controlled by LocalCryptos) 3: = 4: = (controlled by LocalCryptos) is a signature of the oracle of the ECDSA ( || ). The is unique so that signatures cannot be reused across escrows. is the buyer’s public key if it is a version, otherwise the seller’s public key. is the signature of the spender’s transaction.

Sources

1/ https://Google.com/

2/ https://blog.localcryptos.com/bitcoin-cash-trading-begins/

The mention sources can contact us to remove/changing this article

[ad_2]

Related Posts