What is DeFi on BTC?


What is Decentralised Finance (DeFi)?

Decentralised finance (DeFi) is well known in sectors such as finance and business within the crypto space. As mentioned in the previous post ‘What is Proof- of – Transfer and Stacking?’, the features of blockchain is the same mechanism used to secure the cryptocurrency bitcoin. DeFi stores existing financial assets such as loans, savings and investments into blockchain with the implementation of smart contracts. Smart contracts  eliminates the need or trust of a middle man or corporation to make the arrangements of personal assets (I will further explain this is more depth later on). On the contrary, centralised finance (CeFi) has a co-dependant relationship between government control and our  assets. If DeFi fails, it would become CeFi, thus defeating the purpose of decentralisation. 

What makes DeFi desirable is the model of transparency, efficiency and most importantly security of personal assets. Bitcoin the digital currency is kept on a public ledger, meaning that nobody owns or controls bitcoin as the cryptocurrency is stored in decentralised ledger systems on blockchain. 

 Smart Contracts 

As mentioned earlier, smart contracts is a computer code that  eliminates the need for a middle man, instead it is a digital contract written in codes to facilitate the protocol between the seller and buyer. Smart contracts are immutable, meaning that they cannot be tampered with as they are stored in blockchain. However, Bitcoin has its own smart contract but it is limited in terms of processing documents. What Blockstack has done to evolve or anchor bitcoin’s proof of work, is through Proof-of-Transfer (PoX) to secure bitcoin on Stacks 2.0 network with the application of Blockstack’s own smart contract- ‘Clarity’. 

PoX  allows developers to build a secure foundation on bitcoin, while Clarity brings  smart contract applications to Bitcoin using decidable language. Decidable language means that developers are able to build codes and allows them to predict how their contract will be executed, as well as to analyse and identify potential bugs on the stacks network. 

What Clarity is bringing to the next generation of security for bitcoin  is by enhancing current smart contracts vulnerabilities  aiming to eliminate bugs. Additionally,  Clarity is readable for other developers following the principle of ‘what you see is what you get’ preventing the recurrence of bugs in smart contracts. 

Clarity does the following:

  1. Reentrancy – To prevent attackers from trying to perform the same transactions using smart contracts that can corrupt the internal chain. Clarity prevents reentrancy by  increasing the security of transactions on the chain. 

  2. Access Control – Developers are able to code the smart contract but inputting the code as a public domain that allows access to other contracts and transactions.

  3. Overflow and Underflow- Clarity solves the vulnerability of overflow and underflow of transactions that allows attackers to steal tokens. However, Clarity has prevented this from happening by  aborting the transaction if it suspects dishonest transactions. 

  4. Unchecked Return Values For Low Level Calls- If the developer does not check their code properly, this is checked by the people on the network and errors in the  system will cause the transaction to abort. This prevents bugs or accidental errors from happening.

  5. Denial of Service – If the Clarity system identifies that there are malicious behaviours on the network, the smart contract will not be allowed on the Clarity system and taken offline.

  6. Bad Randomness- Clarity has access to the Stacks Blockchain, due  to the programmed function, in order to tamper with the chain, the attacker would have to attack the Bitcoin chain itself which would be difficult. 

  7. Time Manipulation-  Clarity shows Bitcoin’s block timestamp as the Stacks block timestamp, preventing attackers from attacking the system. 

  8. Short Address Attack- Clarity is a secured and accurate programme that prevents attackers from manipulating or tampering with the written codes, levelling up the security of transactions. 


To conclude, PoX will leverage the bitcoin network with the support of the Clarity Smart Contracts by  making it possible to move the BTC chain to the Stack’s chain.  As blockstack is close to the launch of Stacks 2.0, it will be promising to see the implementation of  PoX  and Clarity in DeFi with bitcoins network. This for sure will revolutionise the way individuals make transactions and their assets  without the need of a centralised government. 


References: 

https://www.youtube.com/watch?v=Vq1bxcoW1jQ&t=24s

https://swissborg.com/blog/defi-vs-cefi

https://www.investopedia.com/terms/b/bitcoin.asp

https://www.coindesk.com/what-is-defi

https://www.youtube.com/watch?v=3EtXnygXk1I

https://clarity-lang.org/

https://cointelegraph.com/news/blockstack-ceo-says-bitcoin-is-a-better-defi-solution-than-most-think

https://www.youtube.com/watch?v=6lY0j2X2ENw

https://blog.blockstack.org/bringing-clarity-to-8-dangerous-smart-contract-vulnerabilities/


Comments

Popular posts from this blog

What is Proof- of-Transfer and Stacking?

What Is Freehold?