<?xml version="1.0"?>
<rss version="2.0">
   <channel>
      <title>Blockchain and Bitcoin by Nida Sajid</title>
      <link>https://padlet.com/nida25/wm4d1x4dw49b</link>
      <description></description>
      <language>en-us</language>
      <pubDate>2016-07-08 12:08:36 UTC</pubDate>
      <lastBuildDate>2023-10-14 00:56:08 UTC</lastBuildDate>
      <webMaster>hello@padlet.com</webMaster>
      <image>
         <url></url>
      </image>
      <item>
         <title>Alice sends bitcoins to Bob</title>
         <author>nida25</author>
         <link>https://padlet.com/nida25/wm4d1x4dw49b/wish/116112746</link>
         <description><![CDATA[<div>Alice tells her <strong>Bitcoin client</strong> the amount she wants to send and signs a hashed version of transaction data with her private key. The Bitcoin client creates a <strong>transaction </strong>(data structure) with:<br><br>-Input referencing <strong>UTXO </strong>Unspent Transation Output from a previous transaction (bitcoin address, used to send the bitcoins to Alice in the first place). <br>-<strong>Unlocking script/ScriptSig </strong>containing a digital signature <br>(which is verified by showing it came from the hash and private key which corresponds to the public key) <br>-<strong>Locking scrip</strong>t/encumberence/<strong>scriptPubKey </strong>containing a public Key (when hashed, yields bitcoin address)<br>-<strong>Output </strong>of a certain amount <em>encumbered</em>&nbsp; (locked) to Bob's bitcoin address<br>(public key ---&gt;hash---&gt;hash = bitcoin address)<br><br>This transaction is then transmitted to the entire bitcoin network.<br>Can be done over a public network as only sending signature/public key and no confidential information. <br>As there is no centralized authority e.g a bank, bitcoin miners work to firstly, verify the transaction is valid and secondly, add this to the blockchain. <br><br><strong>Coinbase transaction </strong>: First transaction on the block</div>]]></description>
         <enclosure url="http://i.stack.imgur.com/Jbz7k.jpg" />
         <pubDate>2016-07-08 12:10:33 UTC</pubDate>
         <guid>https://padlet.com/nida25/wm4d1x4dw49b/wish/116112746</guid>
      </item>
      <item>
         <title>Proof of work</title>
         <author>nida25</author>
         <link>https://padlet.com/nida25/wm4d1x4dw49b/wish/116114226</link>
         <description><![CDATA[<div>Once verified, a Bitcoin miner can add a transaction to the transaction block chain by finding a proof-of work ( so that the concatenation of new transaction and old transactions is hashed to produce a string with a certain number of zeros at the start). By Bitcoin protocol, this happens every 10 minutes. Each block contains the hash for the previous transaction.<br><br>-----The algorithm for proof of work involves repeatedly hashing the header of the block and a random number with the SHA256 cryptographic algorithm until a solution matching a predetermined pattern emerges.</div>]]></description>
         <enclosure url="" />
         <pubDate>2016-07-08 12:56:02 UTC</pubDate>
         <guid>https://padlet.com/nida25/wm4d1x4dw49b/wish/116114226</guid>
      </item>
      <item>
         <title>Inputs/UTXO</title>
         <author>nida25</author>
         <link>https://padlet.com/nida25/wm4d1x4dw49b/wish/116114572</link>
         <description><![CDATA[<div>Money received in a wallet is kept separate, according to the different bitcoin addresses it was received from. If Alice has received a 10BTC payment and 20BTC payment and wants to send 25BTC, she sends both as the input and defines 25 as the payment for Bob and 4 as the change returned to her. The remaining amount, 1, goes to the bitcoiner miner as a transaction fee (higher fee=priority processing). </div>]]></description>
         <enclosure url="" />
         <pubDate>2016-07-08 13:02:42 UTC</pubDate>
         <guid>https://padlet.com/nida25/wm4d1x4dw49b/wish/116114572</guid>
      </item>
      <item>
         <title>Hash</title>
         <author>nida25</author>
         <link>https://padlet.com/nida25/wm4d1x4dw49b/wish/116118581</link>
         <description><![CDATA[<div>Input--&gt;Crypotopraphic hash function = Digest<br>Hashes are one-way functions that transform a string of chars. into another block of bytes of a fixed size such as 128bit or 256bit (SHA/MD5)</div>]]></description>
         <enclosure url="" />
         <pubDate>2016-07-08 14:23:57 UTC</pubDate>
         <guid>https://padlet.com/nida25/wm4d1x4dw49b/wish/116118581</guid>
      </item>
      <item>
         <title>Mathematical Minutia </title>
         <author>nida25</author>
         <link>https://padlet.com/nida25/wm4d1x4dw49b/wish/116122435</link>
         <description><![CDATA[]]></description>
         <enclosure url="http://www.coindesk.com/math-behind-bitcoin/" />
         <pubDate>2016-07-08 16:28:20 UTC</pubDate>
         <guid>https://padlet.com/nida25/wm4d1x4dw49b/wish/116122435</guid>
      </item>
      <item>
         <title> Elliptic Curve Cryptography ECC</title>
         <author>nida25</author>
         <link>https://padlet.com/nida25/wm4d1x4dw49b/wish/116159618</link>
         <description><![CDATA[<div><br></div><div><strong>Step 1: Pick ECC curve, parameters and generate key pair<br></strong><br>Elliptic curve for bitcoin is always&nbsp; y^2 = x^3 +ax + b&nbsp; <br>Known as spec256k1, established by National Institute of Standards and Technology (<strong>NIST</strong>)<br>Domain paramenters (<strong><em>p,a,b,G,n,h</em></strong>) are all set/fixed by Bitcoin <br>p is prime modulo of field F<em>p</em><br>Finite fields are modular, things wrap around until they fit in<br>a=0, b=7<br>G is base point (always the same)<br>n is order of point G. Smallest positive number <em>n</em> such that nG=infinity<br>so number of times G can be added to itself to make a vertical line<br>h = 1, the cofactor = Order of elliptic curve / order of subgroup <br>By Lagrange, order of a any finite group is divisible by the order of subgroup <br>so h is always an integer <br><br>-<strong>Private Key</strong>: any number b/w 1 and 2^256 (n=order of curve) - 1<br>This is randomly generated by feeding a larger string of numbers through <strong>SHA256 hash </strong>to get a 256-bit number. If less then n-1, then great, if not, then try again.<br><br>Order 2^256 is approx. 10^77<br>No. of atoms in universie is 10^80 <br><br>-<strong>Public key</strong>: base point x private key<br>^Example of a trapdoor function: Discrete log problem<br>Easy to compute in one direction but nearly impossible to go backwards <br><br><strong>Step 2: Hash data using algorithm e.g SHA-1 and sign hashed data </strong><br>Signature (r,s) is created, different each time <br>but created from the same private key<br><strong>Step 3: Verify</strong></div>]]></description>
         <enclosure url="" />
         <pubDate>2016-07-10 13:56:10 UTC</pubDate>
         <guid>https://padlet.com/nida25/wm4d1x4dw49b/wish/116159618</guid>
      </item>
      <item>
         <title>Elliptic Curve Diffie-Hellman ECDH</title>
         <author>nida25</author>
         <link>https://padlet.com/nida25/wm4d1x4dw49b/wish/116160120</link>
         <description><![CDATA[<div>k = private key<br>Q = public key&nbsp;<br>G = basepoint/generator&nbsp;<br><br>Middle man could have both public keys but not figure out the private keys (without solving the DH problem equivalent to discrete log problem in modular arithmetic) due to the one-way multiplication function</div>]]></description>
         <enclosure url="http://samvartaka.github.io/images/ecdh1.png" />
         <pubDate>2016-07-10 14:28:42 UTC</pubDate>
         <guid>https://padlet.com/nida25/wm4d1x4dw49b/wish/116160120</guid>
      </item>
      <item>
         <title></title>
         <author>nida25</author>
         <link>https://padlet.com/nida25/wm4d1x4dw49b/wish/116160237</link>
         <description><![CDATA[]]></description>
         <enclosure url="http://image.slidesharecdn.com/ellipticcurvecryptographyandzeroknowledgeproof-131105012551-phpapp02/95/elliptic-curve-cryptography-and-zero-knowledge-proof-13-638.jpg?cb=1383614911" />
         <pubDate>2016-07-10 14:37:58 UTC</pubDate>
         <guid>https://padlet.com/nida25/wm4d1x4dw49b/wish/116160237</guid>
      </item>
      <item>
         <title></title>
         <author>nida25</author>
         <link>https://padlet.com/nida25/wm4d1x4dw49b/wish/116160345</link>
         <description><![CDATA[]]></description>
         <enclosure url="http://i.stack.imgur.com/AEx0X.png" />
         <pubDate>2016-07-10 14:43:38 UTC</pubDate>
         <guid>https://padlet.com/nida25/wm4d1x4dw49b/wish/116160345</guid>
      </item>
      <item>
         <title>Mastering Bitcoin E-Book</title>
         <author>nida25</author>
         <link>https://padlet.com/nida25/wm4d1x4dw49b/wish/116222921</link>
         <description><![CDATA[<div><a href="http://chimera.labs.oreilly.com/books/1234000001802/index.html">http://chimera.labs.oreilly.com/books/1234000001802/index.html</a><br><br>Invented by Satoshi Nakamoto (alias) in 2008 - identity unknown<br><br>To get started, we need a <strong>bitcoin client </strong>software <br>-<strong>Full</strong>: stores history, manages wallet (database), can initiate transactions, basically does everything e.g a standalone email server<br>-<strong>Lightweight</strong>: stores wallet but uses 3rd party for transaction initiation and verification <br>-<strong>Web</strong>: accessed through a web browser and store the user’s wallet on a server owned by a third party.<br><br>Within a bitcoin client, there is a bitcoin wallet which generates<br>-transaction when a user wants to send bitcoins<br>-<strong>Public Key</strong><br>-Corresponding <strong>bitcoin address, </strong>160-bit (20 byte)  which is<br><strong>Base58Check encoded: </strong>combination of base58 and checksum<strong><br>Base58 </strong>is a base of 58 symbols, basically Base64 without (0,O, i,L, \+, /)<br><br><strong>Checksum </strong><br>datachecksum = SHA256(SHA256(prefix+data))<br>This gives us 32 bytes (32 bits) but we only take the first 4 bytes and append them onto the end of data<br><br><strong>Private Key Formats</strong>: <br><strong>Hexadecimal</strong>/hex/base-16: uses a base of 16 distinct symbols to represent data.<br>One hex digit = 4 bits (<strong>8 bits = 1 byte</strong>)<br>256 binary digits written in 64 hexadecimal digits, each digit represting 4 bits) <br>OR<br><strong>Wallet Import Format (WIF): </strong>Prefix Payload Checksum<br>NB: WIF Compressed PRIVATE Key means key is in WIF format and compressed PUBLIC keys and compressed bitcoin addresses should be derived from it. Private key itself cannot be compressed. <br><br><strong>Compresed PUBLIC Key Format</strong>: Just the x coordinate is stored to save space, as y can be calculated from equation. If x coordinate has a 02 prefix, then y is even/positive, if 03 prefix then y is odd/negative<br><br><br></div><div><br><br>If the wallet application does not maintain a copy of unspent transaction outputs, it can query the bitcoin network to retrieve this information, using a variety of APIs. <br><br>B<strong>lockchain explorer: </strong>bitcoin search engine to search for addresses, transactions, blocks<br><br><br><br><br><br><br><br></div>]]></description>
         <enclosure url="https://padletuploads.blob.core.windows.net/aws/120711170/6219217092a56cca86c47c4777de9f697cda65e0/91dcfe30d72daef4c3cd45e3e28ee218.png" />
         <pubDate>2016-07-11 19:41:54 UTC</pubDate>
         <guid>https://padlet.com/nida25/wm4d1x4dw49b/wish/116222921</guid>
      </item>
      <item>
         <title>Wallets</title>
         <author>nida25</author>
         <link>https://padlet.com/nida25/wm4d1x4dw49b/wish/117363175</link>
         <description><![CDATA[<div><strong>Nondeterministic</strong>/random/JBOK (Just a Bunch of Keys) Wallet:<br>Random keys are generated, making backing up cumbersome. Usage is discouraged <br><br><strong>Deterministic</strong>/<strong>Seeded </strong>Wallet:<br>Keys are generated by a one-way hash function applied to a 'seed' <br>Only the seed needs back up as all keys can be derived from it<br><br><strong>Hierarchical deterministic wallet<br></strong>Chain code is used to produce child keys from parents keys so we have a tree-like structure <br><br><strong>Backing up a wallet<br></strong>BIP0038 encryption scheme:&nbsp;<br>private key (WIF format, Base58Check prefix 5) + long password =&nbsp; private key ( Base58Check prefix 6P).&nbsp;<br>This new key will need to be decrypted back to WIF format for it to be used in any wallet.<br><br></div>]]></description>
         <enclosure url="https://padletuploads.blob.core.windows.net/aws/120711170/161ef63ac34e7a545972c92c6755db75b8a61fde/454cd0ae21c580009ed43597baf2e470.png" />
         <pubDate>2016-08-02 10:10:55 UTC</pubDate>
         <guid>https://padlet.com/nida25/wm4d1x4dw49b/wish/117363175</guid>
      </item>
      <item>
         <title>&#39;Script&#39;</title>
         <author>nida25</author>
         <link>https://padlet.com/nida25/wm4d1x4dw49b/wish/117375428</link>
         <description><![CDATA[<div>Bitcoin transaction script <strong>language</strong><br>Uses data structure called <strong><em>stack</em></strong><em><br></em>Can push/add item to top of stock or pop/remove item from top of stack<br>Example: OP_ADD will pop two items from the stack, <br>add them, and push the resulting sum onto the stack.<br>-<strong>Turing Incomplete<br></strong>limited complexity <br>predictable execution times<br>-<strong>Stateless <br></strong>no state before or after verification<strong><br></strong>all the information needed to execute a script is contained within the script<br><br>Sample script below returns TRUE</div>]]></description>
         <enclosure url="https://padletuploads.blob.core.windows.net/aws/120711170/da6671512533154f217c9c0778498747f667bc9d/f2fe4ab94ed562c0690e097fee7a43ed.PNG" />
         <pubDate>2016-08-02 14:23:46 UTC</pubDate>
         <guid>https://padlet.com/nida25/wm4d1x4dw49b/wish/117375428</guid>
      </item>
      <item>
         <title>Bitcoin adresses</title>
         <author>nida25</author>
         <link>https://padlet.com/nida25/wm4d1x4dw49b/wish/117793175</link>
         <description><![CDATA[<div><strong>P2PKH address </strong>Pay to public key hash, <br><strong>Starts with 1</strong><br>Beneficiary is owner of public key<br>Bitcoin address=Base58Check encoded (RIPEMD160 hash(SHA256 hash(<strong>public key</strong>)))<br><br><strong>P2SH</strong> <strong>address </strong>Pay to script hash<br><strong>Starts with 3<br></strong>Beneficiary is defined in the hash script <br>Can add functionality to the script - multi-signatures required to prove ownership (think joint a/c)&nbsp;<br>Derived from transaction script, Mostly used for multi-signatures<br>Bitcoin address=Base58Check encoded (RIPEMD160 hash(SHA256 hash(<strong>script</strong>)))</div>]]></description>
         <enclosure url="" />
         <pubDate>2016-08-09 13:46:13 UTC</pubDate>
         <guid>https://padlet.com/nida25/wm4d1x4dw49b/wish/117793175</guid>
      </item>
      <item>
         <title>Bitcoin Network</title>
         <author>nida25</author>
         <link>https://padlet.com/nida25/wm4d1x4dw49b/wish/117805322</link>
         <description><![CDATA[<div>P2P peer to peer<br>Flat topology - no hierarchy <br>Decentralized<br><br><strong>Node: collection of functions - <br></strong>Wallet, Miner, Full blockchain, Network Routing Node <strong><br><br>Full node: </strong>complete copy of blockchain<strong><br>Lightweight node: </strong>contain subset of blockchain, verification done by SPV Simplified Payment Verification<strong> </strong><br><br><br><br><br><br></div>]]></description>
         <enclosure url="" />
         <pubDate>2016-08-09 15:40:22 UTC</pubDate>
         <guid>https://padlet.com/nida25/wm4d1x4dw49b/wish/117805322</guid>
      </item>
   </channel>
</rss>
