Styler Stellar! An overview of Stellar Lumens
Cross-border payments are one space where blockchain technology is actively worked upon to enable better, faster, cheaper payment alternatives than one's prevalent today!. Stellar.org is prominent among them. You might find similarities in how blockchain networks Ripple and Stellar.org works because both of them have a common factor called Jed McCaleb.
The fundamental principles of cross-border payment originate from the years-old Hawala network for both Ripple and Stellar. Hence both use some form of trusted distributed entities called Ripple Gateways in case of Ripple Network and Anchors in case of Stellar network for money movement.
Stellar network has all the basic entities of a regular blockchain network. These are some of the features of the Stellar Lumens blockchain network:
- Decentralized network of servers
- Distributed global ledger software runs and syncs across all the servers.
- All the servers sync and validate the ledger by means of a consensus algorithm.
- Stellar use Stellar Consensus protocol — SCP
- Stellar network uses anchors for the money movement and exchange. Anchors are the real world banks and other remittance companies, cryptocurrency exchanges which exist in our current world!
Anchors are simply entities that people trust to hold their deposits and issue credits into the Stellar network for those deposits. They act as a bridge between different currencies and the Stellar network. All money transactions in the Stellar network (except the native digital currency of lumens) occur in the form of a credit issued by anchors.
Anchors do two simple things:
- They take your deposit and issue the corresponding credit to your account address on the Stellar ledger.
- You can make a withdrawal by bringing them credit they issued.
This is basically what Paypal does now. But the idea here is Paypal works in its own private network whereas Stellar can have all these different Paypal’s, Banks, Remittance companies all connected to their network and make cross transactions.
- Stellar functions as a Distributed Forex
The Stellar ledger is able to store offers that people have made to buy or sell currencies. Offers are public commitments to exchange one type of credit for another at a pre-determined rate. The ledger becomes a global marketplace for offers. All these offers form what is called an orderbook. There is an orderbook for each currency/issuer pair.
For e.g., If you are wanting to exchange a Bank of America/USD for Binance/BTC you look at their particular order books in the ledger to see what people are buying and selling it for and then initiate your transaction.
- Stellar has multi-fiat currency/cryptocurrency transactions enabled.
Stellar allows you to send any currency you hold to anyone else in a different currency through the built-in distributed exchange — DEX. People can receive any currency through an anchor they added.
For e.g., Amy wants to send Bob euros, using her USD balance. Stellar automatically submits an offer to the distributed exchange selling USD for EUR. The network finds the best exchange rate for the transaction.
Here are the different routes through which this transaction can take place:
- Conversion through an offer
Stellar network finds an offer on the internal USD/EUR exchange for someone wanting to buy EUR for USD and automatically makes the exchange between the two parties.
- Using Stellar Lumens [ which is the native digital currency of Stellar network ] as an intermediary currency
Stellar looks for offers on the network asking for USD in exchange for lumens. It simultaneously looks for an offer asking for lumens in exchange for euros. The network makes those exchanges and sends Bob the resulting euro credit.
- Chain of conversions
If there are no explicit relationships between offers to buy and sell, Stellar tries to find offers from the network that will lead a chain of conversions from EUR to USD. For example, EUR to AUD, AUD to BTC, BTC to XLM, XLM to USD.
How does consensus work in Stellar Network?
Stellar Consensus Protocol (SCP) is the first provably safe consensus mechanism that simultaneously enjoys four key properties:
- decentralized control
- low latency
- flexible trust
- asymptotic security
To tolerate Byzantine failure (behavior of individual nodes act arbitrarily), which is an important aspect required of blockchain networks, SCP is designed not to require unanimous consent from the complete set of nodes for the network to reach an agreement, and to tolerate nodes that lie or send incorrect messages. The Stellar blockchain refined the Federated Byzantine Agreement (FBA) approach by adopting the first provably safe FBA protocol. In FBA systems, each node does not have to be known and verified ahead of time, membership is open, and control is decentralized. Nodes can choose whom they trust. This means there is no central authority providing the list of validator nodes but each node can decide their validator nodes!.
In a distributed system, a quorum is a set of nodes sufficient to reach an agreement.
Federated Byzantine agreement introduces the concept of a quorum slice, the subset of a quorum that can convince one particular node of an agreement. The key difference between a Byzantine agreement system and a federated Byzantine agreement system is that, in FBA each node chooses its own quorum slices. The system-wide quorums result from these decisions by individual nodes.
In FBA, there’s no gatekeeper and no centralized authority, so individual nodes decide which other participants they trust for information. Nodes can have multiple slices, and these individual node choices may be based on some extrinsic criteria. For example, a particular bank might be viewed as reputable, causing other nodes to require its acknowledgment of all transactions; a company might already have a financial relationship with a credit union and want to make sure it and the bank both sign off on all transactions. Good quorum share nodes and lead to quorums that overlap. We call this overlap quorum intersection. When quorums don’t intersect, we end up with disjoint quorums which will undermine consensus. Each node is responsible for ensuring that its choice of quorum slice doesn’t violate quorum intersection.
In slice selection, nodes must maintain a balance between safety and liveness.
Nodes lack liveness when they get blocked on the way to agreement, slowing down the system. Nodes lack safety when they externalize values inconsistent with those externalized at other nodes, undermining the system-wide agreement. Such nodes are divergent or they fork easily. A blocked system is less dangerous than a divergent one. FBA systems prefer a blocked system to a divergent one which is more lively but prone to forks!
The nodes in FBA systems use a federated voting technique to get to an agreement. Federated voting is an iterative process with various stages including initial voting, Acceptance, Ratification, and Confirmation.
Voting is preliminary and only happens on the node level. Each individual node decides on one thing over the other.
Thanks to quorum intersection, slices influence one another on accepting a quorum decision. This is where the idea of v-blocking comes to picture. v-blocking nodes affect the decision one way or other for quorums.
A v-blocking set is a set of nodes that intersects with any quorum: you can think of that are set as nodes that must be included (but not at the same time) in order to reach a quorum. A simple example is that if you require 75% majority, any set that makes 30% of the population would be v-blocking as you cannot have any 75% majority without gaining support from members in that fixed 30% (as at least 5% would be required from that group to reach 75%).
Based on what the majority decides on in a quorum we can say the quorum has ratified on that decision.
Confirmation is the final step of the voting process and implies system-wide agreement. To ensure agreement, nodes exchange confirmation messages. A system agrees on a statement if, once sufficient messages are delivered and processed, and no matter what events subsequently transpire, every responsive, accurate node will accept the statement.
There are more to the Stellar protocol — SCP. The white paper is here.
If you have a sleeping syndrome while reading white papers I would recommend watching this video to get a quick grasp on the key principles in Stellar Consensus Protocol!
Ripple and Stellar are two active blockchain projects working on implementing a new solution for cross-border payments which is faster, reliable, and cheaper. Ripple is more centralized in their approach on the network protocol whereas Stellar is more open-source and decentralized.
Two notable achievements in the development of Stellar Lumens project is IBM Blockchain World Wire: a cross-border payment system being developed by IBM using Stellar protocol and Stellar X: a decentralized currency exchange — DEX developed by Stellar Lumens team.