Cyrptography
Cryptocurrency - Bitcoin and the Lightning Network 2
Team 1
Cryptocurrency - Bitcoin and the Lightning Network
Project Report
By
Dr. Emmanuel Udoh
University of the Cumberlands
Cryptography
TABLE OF CONTENTS:
1. Abstract 3
2. Introduction to Block Chain 4
3. Bitcoin 4
a. What is bitcoin? 4
b. Pros and Cons of bitcoin 5
c. Private Keys 7
d. Hashing 8
4. Volatility Problem 8
5. The Bitcoin Blockchain Scalability Problem 10
6. Usability Problem 12
7. The Bitcoin Lightning Network explained 12
a. What is Lightning Network and How does this work? 13
8. Instant Payments 16
9. Micropayments 16
10. Timestamping 17
11. Privacy 18
a. Onion Routing 18
b. Fixed Identifiers 18
12. Specifications and Implementations 19
13. Advantages and Criticisms of the Lighting Network 20
14. Future State and Current Trends 21
15. Conclusion 25
Abstract
Bitcoin protocol can completely change the future of financial transactions globally and can change the way modern man looked at electronic transfer of money or currency. It can eliminate the need for a third party which can hold the funds or act as an intermediator. All this can be achieved only with the use of a computer and a broadband connection. But there are quiet a few roadblocks in achieving this. Bitcoin is associated with certain problems. It has a scaling problem, where the number of transactions done per second are very few compared to other electronic transfer methods present in the modern world. The other roadblock is Volatility. Bitcoin being a global electronic currency, where millions of users are dependent on it for their daily transactions cannot be volatile. This is because of various external factors driving the users to either use a Cryptocurrency or not to do it. At the same time there is no standard that is used too make transfers here. Scalability and Volatility cause the third problem with Bitcoin. That is Usability. The number of people actively using Bitcoin for electronic transfers is always fluctuating. These issues are answered as a part of “The Lightning Network”, which is an additional layer that transmits signed transactions by only utilizing the Bitcoin blockchain for the final transfer of funds. The associated advantages and disadvantages of this Lightning network are discussed in relation to how this answer’s the basic questions raised in regard to Bitcoin and blockchain in general.
Introduction to Block Chain
Blockchain is considered as the most fundamental and most important aspect of Bitcoin. The blockchain is a distributed database of records of all transactions or digital event that have been executed and shared among participating parties which contains every single record of each transaction. Blockchain Technology first came to light when a person or Group of individuals name ‘Satoshi Nakamoto’ published a white paper on “BitCoin: A peer to peer electronic cash system in 2008. Blockchain Technology Records Transaction in Digital Ledger which is distributed over the Network thus making it incorruptible. Anything of value like Land Assets, Cars, etc. can be recorded on Blockchain as a Transaction.” (Gupta, 2019)
Bitcoin
What is bitcoin?
Bitcoin (₿) is a type of cryptocurrency. It is a digital currency that is decentralized and works
Advantages of Using Bitcoin
1. Greater Liquidity Relative to Other Cryptocurrencies
Bitcoin in the most popular cryptocurrency, that has greater liquidity than its peers. This allows users to retain most of its inherent value when converting to fiat currencies, such as the U.S. dollar
2. Increasingly Wide Acceptance as a Payment Method
Most of the merchants accept Bitcoin payments, it’s possible to buy virtually any physical item serious about reducing your exposure to fiat currencies.
3. International Transactions Easier Than Regular Currencies
Bitcoin transactions aren’t any international transaction fees or red tape to navigate, as is often the higher, while money transfer fees can be as high as 15%.
4. Generally Lower Transaction Fees
Credit cards and Paypal has high transaction fees like 2% - 3% whereas Bitcoin comes with lower transaction fees.
5. Anonymity and Privacy Relative to Traditional Currencies
Bitcoin’s built-in privacy protections allow users to separate their Bitcoin accounts from their out who those users really are.
6. Independence from Political Agents and Creators
Bitcoin is also unbeholden to its creators, due to its completely decentralized nature, popularity, relative to other cryptocurrencies, negatively impacting other holders.
Disadvantages of Using Bitcoin
1. Exposure to Bitcoin-Specific Scams and Fraud
Bitcoin is one of the most popular currencies in the world. This caused a lot of frauds that are
2. Black Market Activity May Damage Reputation and Usefulness
Obviously, dark web marketplaces like Silk Road and Sheep expose rank-and-file users to fraud and the threat of criminal prosecution.
3. Susceptible to High Price Volatility
In the wake of the Mt. Gox collapse, Bitcoin’s value fell by more than 50%. Following the FBI’s times, only to halve in the first weeks of 2018 – wiping out billions in market value almost overnight.
4. Environmental Ills of Bitcoin Mining
Bitcoin mining consumes vast amounts of electricity. According to Business Insider, some of the plants and horrific smog routinely makes even low-key outdoor activity unsafe for healthy adults.
Private Keys
Every Bitcoin user has at least one private key (basically, a password), which is a whole number between 1 and 78 digits in length. Private keys confirm their owners’ identities and allow them to
Hashing
“In simple terms, hashing means taking an input string of any length and giving out an output of a fixed length. In the context of cryptocurrencies like Bitcoin, the transactions are taken as an input and run through a hashing algorithm (Bitcoin uses SHA-256) which gives an output of a fixed length.” (Rosic, 2017)
A common use of this kind of hash function is to store passwords. When you create a user
“This means that if a hacker is able to access the database containing the stored hashes, they will not be able to immediately compromise all user accounts because there is no easy way to find the password which produced any given hash.” (Faife, 2017)
Volatility
Volatility is one of the problems with Bitcoin (BTC) along with most other cryptocurrencies and they fluctuate discouragingly against dollar. For example, if you take a bitcoin when FOMO fueled impulse you would bring one hundred us dollar worth of bitcoin in
Why Bitcoin has a Volatile Value
Bitcoin has no fundamental costs to fall back upon and the price fluctuations inside the Bitcoin spot fee at the Bitcoin exchanges is pushed by many factors. Volatility is measured in conventional markets with the aid of the Volatility Index, additionally referred to as the CBOE
Unpleasant News Hurts Adoption Rate
News occasions that scare Bitcoin users consist of geopolitical occasions and statements
All these incidents and the general public panic that ensued drove the cost of Bitcoins versus fiat currencies down swiftly. However, Bitcoin-friendly buyers viewed the ones events as proof that the marketplace became maturing, riding the price of Bitcoins versus the greenback markedly returned up in the short period right away following the information events. ( Barker, 2019)
Large Currency Holder Risks
Bitcoin volatility is likewise to a quantity driven through holders of large proportions of the full top-notch drift of the foreign money. For Bitcoin traders with modern-day holdings above
Since Bitcoin’s extent resembles a small cap inventory, the foreign money has now not hit the mass market adoption rates that might be necessary to provide alternative value to big holders of the forex.
Security Breaches
Bitcoin can also become unstable while the Bitcoin community exposes safety vulnerabilities which will produce massive open supply responses within the shape of safety fixes. For example, it has become a hack that drove the Yapian Youbit to financial smash, whilst
Scalability
The second crucial factor Armstrong believes is crypto mass adoption is scalability solutions. He started off by way of saying there are presently 5 to ten groups running on possible scalability answers. He mentioned that 2d-layer solutions like the lightning network and next-gen protocols, which he says will begin to come out over the subsequent 6 to 12 months.
Why Bitcoin has a Scalability Problem
Bitcoin is designed to keep all transactions in a facts structure referred to as a block. A block carries data approximately the preceding block, miscellaneous records about mining rewards, and maximum of the block is just transaction records. Blocks also are fixed at most of
mins on an average. To continue, that might be over 400 terabytes of information per year. ( Poon & Thaddeus, 2016)
As the wide variety of transactions starts to growth, your character transaction competes with every different for inclusion interior a restrained block space, and so, the probability of getting yours protected inside the block starts off evolved to lower. Since miners can arbitrarily decide which transactions to include in a block, on these activities, the only manner to incentivize the miners to consist of your transaction is by way of growing your transaction rate. However, this starts to make transactions prohibitively pricey consisting of this 192-byte transaction for $92.98 in which the transaction rate changed into $14.86. (Gilani, 2019)
Usability
As most of the people already aware that, using the cryptocurrency is not nearly instinctive as it needs to be for public adoption. In regarding, Armstrong explained that there are numerous process steps when it comes to buying, selling, storing and securing the cryptocurrency. He said that retail investors want something that works in addition to the famous Chinese app, WeChat. (Wall, 2019)
On the other hand, as formerly pronounced with the aid of IIB, 75% of crypto holders nevertheless worry the failure of sending transactions even as sending crypto. In order for crypto mass adoption to occur, managing your crypto has to be as smooth using a not unusual messaging app. (Wall, 2019)
The Bitcoin Lightning Network explained
The Bitcoin Lightning Network is basically a solution that’s been marketed as the solution to all problems that are associated with Bitcoin. There are certain claims done by the Lightning network like solving the scaling problem,
Lightning Nodes and Channels
A Lightning node operates basically like a Bitcoin node like in a networked approach, validating all the transactions and communicating with other nodes. In addition to this, it manages to do things that Bitcoin nodes couldn’t do, like it can hold funds, act as an automated financial intermediary, monitor the Lightning “channels” continuously for any suspicious behavior and react to the malicious behavior defensively.
Creating a Lightning Channel:
Please find the example transaction considered to explain creating the Lightning Network. As an example, consider you and your friend Bob are trying to do a financial transaction. One way this is done is by Venmo-ing each other. But consider using Crypto for the same transaction. This can be done by creating a new channel that is mutual between you and Bob, that can be funded equally by both the users with half a bitcoin each.
Illustration of two nodes creating a channel on the Bitcoin Lightning Network
A new Lightning channel is basically like designing a multi-signature bitcoin wallet that will require signatures from both the parties involved(You and Bob), but only with a difference that each one gets a signed, but still not a broadcasted, “Commitment Transaction”, as per the Lightning Network white paper, that returns your initial deposits back to you(citation paper). The advantage with this is that any one of the users can unilaterally close the channel by broadcasting this transaction and everyone gets their rightful amounts (Gilani, 2019).
Making Lightning Transactions with People Without Channels:
In this scenario consider another friend say Alice is added to the transaction. Based on certain spending norms, there comes a situation where you have to pay Alice but you don’t have a channel established with Alice.
Illustration of a multi-hop lightning transaction
Assume that Bob has a channel with Alice, this can be used to pay Alice via Bob. Your node calculates the optimal route between you and Alice—in this case, with Bob as the financial intermediary—and the middlemen can all pay money forward, with a small fee if they choose. (Gilani, 2019)
Closing the Channel:
Instant Payments
Micropayments
Timestamping:
Trusted Timestamping is a secure process to track the creation of a document or bitcoin and works as a legal validation tool for a record created in the bitcoin network. In the real world, it acts similar to a notary that would let anybody validate whether the records existed at a particular date and time. By default, every bitcoin transaction holds a timestamp that includes the date and time and a cryptographic digest can be added to the transaction to check the data existence at a specific point of time.
In such a way the timestamp serves as a digital validation for different types of media files, e.g. plain text TXT, Portable Document Format (PDF), Microsoft Word (DOC, DOCX), Image (TIFF, JPEG etc), Spreadsheets (XLS, XLSX), Drawings (CAD) with any kind of content like: Contracts, Photos, Literature, Drawings, Books, Poetry etc.
The fundamental blocks of timestamp are digital signatures and hash functions. First step is to calculate the hash function for the data and then send it to Time Stamp Authority, where the hashed
Privacy:
Privacy is important in lightning network to secure payments. Below explained one of the concerns with the current security and proposed solution for future.
Concern – Fixed Identifiers: Currently the privacy in the lightning network used fixed identifiers in their payments, i.e., an identifier is repeated through entire route. This opens a chance for an adversary to identify the source of the payment flow and the entire path if two nodes are known. This can be improved by adopting Schorr aggregated public keys.
Solution – Onion Routing:
The lines are channels and circles are nodes.
Implementations of the Lightning Network Protocol
Below are few implementations of the lightning network protocol and others are to be added more in future.
· LND - Lightning Network Daemon (Golang)
· eclair - A Scala implementation of the Lightning Network (Scala)
· lit - Lightning Network node software (Golang)
· c-lightning - A Lightning Network implementation in C
· rust-lightning - A Lightning Network implementation in Rust [Incomplete]
· lightning-onion - Onion Routed Micropayments for the Lightning Network (Golang)
· ptarmigan - C++ BOLT-Compliant Lightning Network Implementation
The Pros and Cons of The Lightning Network:
Pros
The Cons:
Like everything else, the Lightning network is not perfect and has certain limitations.
The system is primarily designed to handle small to medium transactions, so it cannot process large payments. Another important issue is centralization. Some cryptographers believe that this type of network can actually facilitate centralization at the payment center level. This process is similar to minor centralization. Lightning Network does not support offline payments. The situation is similar for point-to-point connections. If one of the pairs does not respond, the user must wait hours until he can recover the money.
Future State and Current Trends:
After years of conception and development, the first Lightning implementation is currently in beta. Every day more online nodes appear, and more and more users open channels to each other. Some merchants now accept Lightning payments. But, of course, these are the first days of the Lightning network. While the main implementation is available and some wallets and other applications are available, the Bitcoin overlay network will improve in the coming years from network architecture to ( Wirdum, 2018) security and ease of use. use. That is predicted. ( Wirdum, 2018)
Dual-Funded Channels:
The Lightning network consists of several payment channels. Each payment channel exists between two users and can transfer money between users. However, at this early stage of development, payment channels can only be financed by one of them. The lender must first deal with the counterpart. Only then can the counterparty return the payment in the same way.
However, the Lightning Network technical document proposed a dual financing channel. For this purpose, a specification of the ACINQ company behind Eclair is proposed. As the name implies, both users can partially finance the payment channel by depositing their respective bitcoins. This makes the Lightning user experience more flexible, as users not only receive a payment immediately after opening a channel but can also send money. ( Wirdum, 2018)
Submarine Swaps:
Compact Client-Side Block Filtering:
Although Lightning Network is a second level protocol, the Bitcoin block chain is still relevant to lightning users for security reasons. In particular, Lightning users should monitor the block chain to see if it contains a particular transaction. This may require many resources, especially for mobile users. A solution for this is called Simplified Payment Verification (SPV) and is described in the Bitcoin technical document. Current SPV wallets use a trick called "Bloom Filter" to determine if an associated transaction has occurred. ( Wirdum, 2018)
Watchtowers:
The current design of the watchtower is not a rock, but it works that way. Each time a user updates a channel, it sends a small data packet to the watchtower. The first part of this package is a transaction index that you can observe as if it were a puzzle. This trick alone says nothing about the transaction that the Watchtower needs to know. In this way, users do not give privacy.
However, if the corresponding transaction appears in Bitcoin Block chain, the Watchtower can recognize it with a hint. Then, using the transaction data in the block chain itself, the watchtower can reconstruct the penalty transaction using the second part of the received package. This penalty transaction sends all channel amounts to the trap user. Sanctions can also be established so that the Watchtower can claim some of the money as a reward for their work. Users can outsource channel monitoring to multiple monitoring towers. If one fails, the other fails, which limits the risks to the Lightning user to almost negligible levels. ( Wirdum, 2018)
Atomic Multi-Path Payments:
Conclusion:
Lightning Network is touted to be the solution to all the drawbacks associated with Bitcoin.
With this paper we have clearly outlined Blockchain, Bitcoin and its drawbacks, Lightning Network being a solution to the drawbacks of Bitcoin. With instant and free Lightning payments, Bitcoin can replace credit cards, including cash or other personal transactions. Lightning Network provides solutions to Instant Payments, Micropayments and to reduce the amount of burden that is being put on the blockchain network. This network uses the Bitcoin scripting opcodes to enable real Bitcoin transactions, simultaneously providing security against fraudulent transactions and counterparty theft. According to the creators of Lightning Network Joseph Poon and Thaddeus Dryja “If all transactions using Bitcoin were on the blockchain, to enable 7 billion people to make two transactions per day, it would require 24GB blocks every ten minutes at best (presuming 250 bytes per transaction and 144 blocks per day). But if all transactions using Bitcoin were conducted inside a network of micropayment channels, to enable 7 billion people to make two channels per year with unlimited transactions inside the channel, it would require 133 MB blocks (presuming 500 bytes per transaction and 52560 blocks per year). Current generation desktop computers will be able to run a full node with old blocks pruned out on 2TB of storage.” ( Poon & Thaddeus, 2016).
Thus, the usage of Lightning network can revolutionize the way web-based transactions are done and the way billions of users can use this technology to transfer funds without any risk.
References: Barker, J. T. (2019, July 9). Why Bitcoin Has a Volatile Value. Retrieved from Investopedia: https://www.investopedia.com/articles/investing/052014/why-bitcoins-value-so-volatile.asp FRANKENFIELD, J. (2019, june 25). Mt. Gox. Retrieved from Investopedia: https://www.investopedia.com/terms/m/mt-gox.asp Poon, J., & Thaddeus, D. (2016). The Bitcoin Lightning Network:. lightning-network-paper. Wirdum, A. v. (2018, June 7). The Future of Bitcoin: What Lightning Could Look Like. Retrieved from Bitcoin Magzine: https://bitcoinmagazine.com/articles/future-bitcoin-what-lightning-could-look Bitcoin. (2019). Retrieved from Bitcoin is an innovative payment network and a new kind of money: https://bitcoin.org/en/ Bitcoin, U. t. (2018, July 8). Bitcoin Lighting Network Explained: Pros and Cons. Retrieved from https://usethebitcoin.com/bitcoin-lighting-network-explained-pros-and-cons/ Dryja, T., Gert Jaap, G., & Lovejoy, J. (n.d.). MIT Media Lab. Retrieved from Digital Currency Initiative: https://dci.mit.edu/lightning-network Faife, C. (2017, Feb 19). Bitcoin Hash Functions Explained. Retrieved from Coindesk: https://www.coindesk.com/bitcoin-hash-functions-explained Floyd, D. (2018, March 12). Lightning Network: What Is It and Can It Solve Bitcoin's Scaling Problem? Retrieved from Investopedia: https://www.investopedia.com/news/lightning-network-what-it-and-can-it-solve-bitcoins-scaling-problem/ Gilani, A. S. (2019, April). Scale with Speed: The Bitcoin Lightning Network Explained. Retrieved from Topal: https://www.toptal.com/bitcoin/intro-to-bitcoin-lightning-network Gupta, A. (2019, Jan). Introduction to Blockchain technology. Retrieved from geeksforgeeks: https://www.geeksforgeeks.org/blockchain-technology-introduction/ Martucci, B. (2019). What Is Bitcoin – History, How It Works, Pros & Cons. Retrieved from Moneycrashers: https://www.moneycrashers.com/bitcoin-history-how-it-works-pros-cons/ Rahouti, M., Xiong, K., & Ghani, N. (2018). Bitcoin Concepts,Threats and Machine-Learning Security Solutions. IEEE Access. Rosic, A. (2017). What Is Hashing? [Step-by-Step Guide-Under Hood Of Blockchain]. Retrieved from Blookgeeks: https://blockgeeks.com/guides/what-is-hashing/ Wall, J. (2019, April 11). Coinbase CEO Outlines 3 Things Needed For Crypto Mass Adoption. Retrieved from Invest in Blockchain: https://www.investinblockchain.com/coinbase-ceo-outlines-3-things-needed-for-crypto-mass-adoption/ Weicker, O. (2019, September 27). Blockchain Scenarios. Retrieved from Content Blockchain: https://content-blockchain.org/scenarios/