<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>Forem: Shivanshu</title>
    <description>The latest articles on Forem by Shivanshu (@geekshiv).</description>
    <link>https://forem.com/geekshiv</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F328382%2F68e766d0-27b5-470f-b165-f6dd4acbe9ae.jpg</url>
      <title>Forem: Shivanshu</title>
      <link>https://forem.com/geekshiv</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://forem.com/feed/geekshiv"/>
    <language>en</language>
    <item>
      <title>00 - Smart Contract Security | Blockchain basics</title>
      <dc:creator>Shivanshu</dc:creator>
      <pubDate>Sun, 10 Oct 2021 04:57:41 +0000</pubDate>
      <link>https://forem.com/geekshiv/00-smart-contract-security-blockchain-basics-54o</link>
      <guid>https://forem.com/geekshiv/00-smart-contract-security-blockchain-basics-54o</guid>
      <description>&lt;p&gt;In this series of smart contract security articles, I (&lt;a href="https://twitter.com/geekshiv" rel="noopener noreferrer"&gt;@geekshiv&lt;/a&gt;) and &lt;a href="https://twitter.com/Thtsuman" rel="noopener noreferrer"&gt;@Thtsuman&lt;/a&gt; will cover Solidity, Smart Contract, etc with the security (Audit) aspect of it. Let's go through some of the basic terms and concepts before jumping to the complex part.&lt;br&gt;
&lt;br&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Block&lt;/strong&gt;: Block is kind of container which stores data relevant to the network and transactions. Example: If you send ETH to someone, the transaction data needs to be added to a block for it to be successful.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;A block may look like this:&lt;br&gt;
&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fcvcjexi1nv6lo6gieojr.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fcvcjexi1nv6lo6gieojr.png" alt="Block Example"&gt;&lt;/a&gt;&lt;br&gt;
&lt;br&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Block-chain&lt;/strong&gt;: Whenever a new block is created it refers to it's parent block and this creates a chain of blocks. A block's data cannot be changed without changing all subsequent blocks, which would require the consensus of the entire network.&lt;br&gt;
&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F3qean2615zqkujc17k20.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F3qean2615zqkujc17k20.jpeg" alt="Blockchain Example"&gt;&lt;/a&gt;&lt;br&gt;
&lt;br&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Ethereum&lt;/strong&gt;: Ethereum is built upon the concept of blockchain which acts as an open-source blockchain network providing features like a decentralized ledger, Smart Contracts, tokens (ERC-20 and ERC-721), and has its cryptocurrency called Ether(ETH).&lt;br&gt;
&lt;br&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Ether&lt;/strong&gt;: Ether (ETH) is a cryptocurrency. It facilitates the operations of the ethereum platform. &lt;br&gt;
Example: Any transaction in the ethereum network needs a fee that is paid in the form of ether.&lt;br&gt;
&lt;br&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Gas&lt;/strong&gt;: Gas is a fee that is paid to the miner for the computational effort required to execute specific operations on the Ethereum network. &lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;



&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Consensus&lt;/strong&gt;: When it comes to a decision of a network or large group the majority of people have to agree upon the decision to be successfully executed. This agreement can be referred to as a consensus mechanism. In Blockchain at least 51% of nodes have to agree for successful execution.&lt;br&gt;
In Ethereum Consensus is achieved using the following Consensus mechanisms:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Proof of Work (PoW)&lt;/li&gt;
&lt;li&gt;Proof of Stake (PoS)

&lt;/li&gt;
&lt;/ol&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Smart Contract&lt;/strong&gt;: A smart contract is a digital contract that is deployed on the Ethereum network. A smart contract is basically an agreement between nodes converted into a piece of code which once agreed upon and deployed on the network cannot be changed.&lt;br&gt;
&lt;br&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Solidity&lt;/strong&gt;: Solidity is a programming language that is used to write smart contracts in Ethereum.&lt;br&gt;
&lt;br&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Web3&lt;/strong&gt;: Web3, in the context of Ethereum, refers to decentralized apps that run on the blockchain. These are apps that allow anyone to participate without monetising their personal data.&lt;br&gt;
&lt;br&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;DAPP&lt;/strong&gt;: DAPP (decentralized application) is a combination of smart contracts and a frontend interface. DAPP allows users to interact with services using the ethereum network.&lt;br&gt;
&lt;br&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;DeFi&lt;/strong&gt;: Defi (Decentralized finance) is a term referred to finance applications or services on a Blockchain network. Its a modern, effective way of decentralized banking that overcome the difficulties faced in the traditional banking system.&lt;br&gt;
&lt;br&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Accounts&lt;/strong&gt;: Every entity in the network had an account of its own which is determined by a unique string. The smart contract also has an account that is different from the owner's account. Example account:&lt;br&gt;
&lt;br&gt;
&lt;code&gt;{0x0B76a1869bb55ABE5c8e696552418CD15e9eaEdd}&lt;/code&gt;&lt;br&gt;
&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;



&lt;p&gt;References:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://andersbrownworth.com/blockchain/" rel="noopener noreferrer"&gt;https://andersbrownworth.com/blockchain/&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://ethereum.org/en/developers/docs/" rel="noopener noreferrer"&gt;https://ethereum.org/en/developers/docs/&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;Web3: &lt;a href="https://blockchainhub.net/web3-decentralized-web/" rel="noopener noreferrer"&gt;https://blockchainhub.net/web3-decentralized-web/&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>blockchain</category>
      <category>security</category>
      <category>solidity</category>
      <category>ethereum</category>
    </item>
  </channel>
</rss>
