A Beginner's Guide to How Cryptocurrencies Work
From Bitcoin to blockchain, here's what you need to know.
Whether you're at the head or tail of the cryptocurrency craze, one thing's for sure: These digital assets are hitting the mainstream hard and don't look like they're going away any time soon. Notably, the country of El Salvador recently adopted bitcoin as legal tender, and incoming New York Mayor Eric Adams intends to transform New York City into a cryptocurrency hotspot.
Although only 16 percent of Americans say they have invested, traded, or used cryptocurrency, nearly 90 percent have heard of it, according to a recent Pew Research Center survey.
Proponents of cryptocurrency and decentralized finance (where people can make financial deals with each other without being moderated by an intermediary or a central authority like a bank) generally argue that these platforms are both transparent and anonymous, both of which are good things.
The key to this vision lies in a digital technology called blockchain, which underpins all cryptocurrencies. The blockchain serves as a virtual room of record, or public ledger, recording every transaction, detailing the amount, as well as the sender's and recipient's wallet addresses.
However, critics and regulators are concerned about the potential for harm from cryptocurrencies, such as people using them to scam, money launder, or finance illegal activities (not to mention the huge carbon footprint some of these have). cryptocurrencies). And experts have raised concerns about the robustness of cryptocurrency networks against attack and whether the design of some systems has warped over time to centralize or allow the rich to get richer.
For those just delving into cryptocurrency territory, here is a basic explanation of how the computer science behind these systems works.
The Basics of Cryptography, Explained
For starters, this is what happens when you send and receive cryptocurrencies. Note that all cryptocurrencies are based solely on computer programs, including bitcoin, and that these "coins" are not actually money, but rather snippets of computer code that transfer value from one user to another. To be part of this process, you must first create a digital wallet. Bitcoin and Ethereum have recommendations on which wallet works best with your cryptocurrency, and specialized exchanges like Coinbase and Gemini also offer wallets.
Whenever you create a new wallet, the algorithm running that cryptocurrency will generate a paired private key and a public key associated with it. You can think of the public key as an address or bank account number, and the private key proves your ownership. These keys are a long string of characters that identify where the crypto should go. Addresses usually only accept the type of cryptocurrency they are affiliated with (although something called cross-chain bridges and exchanges can help link different cryptocurrencies).
You can then tap some of the unspent value in your wallet and send it to someone else's public key. When you sign to verify that you want to send the bitcoins, you generate a small custom piece of code attached to the transaction, and the system creates a mathematical puzzle that locks in that value and scrambles the code. When the recipient is ready to spend the money, they will place the corresponding code on the transaction. Everyone on the network can verify that the two pieces of code fit together (through a process called transaction confirmation, also known as mining, more on that later). This whole operation is called signature verification.
“It's impossible for someone to find a missing piece if they don't have the right information, but it's very easy for anyone to verify that two pieces fit together,” explains Christin. “Bitcoin has very few additional computational capabilities beyond signature verification. The vision of Satoshi Nakamoto [the pseudonym of the supposed creator of Bitcoin] was to have programmable money, initially. The problem is that Bitcoin got very popular very quickly and the developers decided to freeze the features where they were.”
However, a new update released last week could open up the possibility of supporting extended features beyond signature verification.
So how are other cryptocurrencies different from Bitcoin?
Many modern cryptocurrencies are derived from the Bitcoin model. For example, Litecoin is in many ways similar to Bitcoin, but the puzzle component was slightly changed. They replaced the mining algorithm (called SHA-256) used in Bitcoin with a function called Scrypt, which they claim requires less power to run. On the other hand, the creators of Bitcoin Cash parted ways with a team that was working on Bitcoin to make a Bitcoin-like cryptocurrency that can process more transactions per second.
Ethereum, however, takes a different approach. Its blockchain has an additional feature called "loops", which allows it to repeatedly execute a piece of code, and engineers can program on top of it. Ethereum uses a mechanism called "gas" that charges the person who initiated the transaction a fee for executing a programming instruction. The program burns off the "gas" as it runs, and when it runs out of gas, the program completes or terminates.
Developers can build a cryptocurrency on top of Ethereum (such as the DAI stablecoin), create mortgages, or unique non-fungible tokens, as they are all snippets of code. “Those are all snippets of code that are extensions to Ethereum transactions,” says Christin.
Ethereum is also credited with the clever innovation of integrating smart contracts into its blockchain. Ethereum developers describe them as code scripts that "perform some actions or calculations if certain conditions are met", comparing the logic of the code to the operation of a "vending machine". If a digital art NFT lives inside a smart contract, for example, the artist can create a royalty program that accumulates a fee each time the art is transferred to the blockchain.
Or, as another example, imagine walking into a bank and borrowing $10 million for the day without telling anyone your name. "Someone is going to look for a red button under a desk somewhere," says Ari Juels, a computer science professor at Cornell Tech. "But you can actually do something like this on a blockchain."
You would borrow money using a smart contract and use it to do whatever you want to do. It is typically used for arbitrage, where you buy and sell tokens at a profit. Then you pay back the loan and all of that is contained in one single transaction. "The way blockchains work, if you don't repay the loan, the entire transaction can be canceled," Juels says, "meaning it's like you never borrowed the money to begin with."
Proof-of-work, proof-of-stake, and other forms of "consensus"
Now, to open the curtains a bit further: To keep any cryptocurrency system running, there has to be a way to release new coins into the network, along with a way to maintain the public ledger that tracks where all the new ones come from. coins and where they go.
But since these cryptocurrencies are meant to be peer-to-peer, there is no single entity that does all of this, like a traditional bank does. Instead, the responsibility for running the system rests with the entire network of participants, so they must come to some form of consensus on whether the transactions are valid or invalid. Every transaction made on the blockchain must be verified. A batch of transactions forms a block and multiple blocks form a chain.
"Blockchain gives you a different trust model," says Juels. "The rules are very well defined and the transactions can be executed in a rigorous and programmatic way."
There are a variety of methods used by different cryptocurrencies to accomplish those two standard tasks. Proof-of-work is the process used by most cryptocurrencies, including Bitcoin and Ethereum, to do this. Although all users can verify if the transaction was good in the end, only one user can be chosen to lead the validation, add the transaction to the blockchain and receive a reward. These bounties are how new coins are released into the system. This operation is also known as mining. But first, users, called miners, have to compete against each other to solve a cryptographic puzzle whose difficulty is proportional to the number of people trying to solve the puzzle. The puzzle is created by an algorithm.
With Bitcoin, there is a limited number of bitcoins in the system (21 million) and the rewards for mining decrease over time, although miners are still incentivized because they can receive a portion of the transaction as a fee. “Bitcoin's ideal goal was one vote per CPU. That has finally been subverted,” says Juels. "People are using specialized mining hardware to participate in the system." As bitcoin mining heated up, people built and burned specialized hardware, consuming electricity and creating tons of waste.
“Proof of work still works according to the original principle of requiring an investment of resources to participate in the block mining system,” Juels notes.
Meanwhile, in proof-of-stake systems, you pay to play and have to stake tokens as an investment of resources to participate, like making a security deposit that you get back once the transactions you added to the blockchain are approved by the net. . The system randomly chooses a bettor who is online at that moment and they can validate the transactions and receive the rewards. Because it doesn't require solving puzzles, in theory, it should consume less energy.
"In Bitcoin, your stake in the system is proportional to the amount of computation you do," says Juels. "In a proof-of-stake system, it's proportional to the number of cryptocurrencies you have in the system."
“Typically the way [both proof-of-work and proof-of-stake] systems work is that the rights to create the next block are randomly determined in a sort of lottery where your chances of winning the lottery are proportional to their resources," he adds.
While Ethereum said it was transitioning to a proof-of-stake system, that jump hasn't happened yet. Existing cryptocurrency projects that use proof of stake have their own variations. For example, Cardano uses a proof-of-stake system called "Ouroboros" that incorporates stake delegation and stake pools. And Solana, a blockchain on which you can also build smart contract programs and other decentralized applications, combines proof-of-stake with another consensus algorithm called proof-of-history to embed timestamps in transactions.
Even though proof-of-stake is faster and more energy efficient, many experts are concerned about its stability and barriers to entry. “In Bitcoin, you can start mining, in principle, with your laptop. It would not go very well for you, but you can join the system without any prior investment of resources,” says Juels. “In the case of these proof-of-stake systems, you have to buy some coins to participate or have the coins assigned to you at the beginning of the protocol. There are some people who object to the need to get coins to be able to participate, but that is a necessity.”
Alternatively, a cryptocurrency project called the XRP ledger uses a consensus protocol unlike proof of stake or proof of work which is almost democratic, but validators do not receive any rewards.
What about the storage test?
There is also another concept that you should know. Proof of storage (also known as proof of space) is where you are committing an amount of space to network storage. “The idea initially was digital preservation: we want to record everything, so at least we can use the disk space for a good purpose. Turns out it's less necessary than we think,” says Christin. "There is a need for digital preservation, but it's not scaling as fast as a currency would." Juels proposes that these systems could potentially be useful for storing NFT data. A project that proves this concept is Filecoin.
Ultimately, despite gaining ground with big financial platforms like PayPal, Mastercard, and Robinhood, the future of cryptocurrencies is still uncertain – looming federal regulations could drastically reshape the community and ecosystem. And the value of currencies like bitcoin remains volatile and represents risky investments. Wherever the next chapter of cryptocurrency leads, it is indisputable that the popularity of this new wave of technology has already forced large financial institutions to evolve their thinking about how people want to interact with money and with each other using money. .
Reasons to invest in real estate versus shares in the Stock Market