Discreet Log Contracts (DLCs) are a type of Bitcoin smart contract that utilize oracles to complete trustless transactions.
At its core, this technology enables peer-to-peer betting directly on the Bitcoin blockchain. DLCs are a beneficial alternative to centralized betting platforms, where an intermediary oversees a bet and holds custody of both parties' funds.
For the DLC to eventually determine the result of a bet, it imports off-chain information from what is known as an “oracle”. Oracles provide data to Bitcoin and act as a source of real-world information for smart contracts. Once the outcome is settled, funds are redistributed according to the initial agreements between the two parties.
While Discreet Log Contracts have been on Bitcoin since 2020, their functionality significantly improved in November 2021 when the Bitcoin network activated the Taproot upgrade.
The most common use case for a DLC is when two parties wish to commit to a monetary agreement based on the future outcome of a real-world event.
Bitcoin DLCs are best executed on the Lightning Network. By using a Lightning channel, users can benefit from fewer transaction costs and faster settlement times.
How do Discreet Log Contracts Work?
We will explain how DLCs operate alongside the Bitcoin protocol by walking through the process of starting, entering, and settling a Discreet Log Contract.
Here are the 3 key events that occur when two parties want to create a “bet” on the future outcome of a real-world event.
1. Funding transactions
To initiate a Discreet Log Contract, both parties send Bitcoin to a shared, 2-of-2 multi-signature wallet. These deposits serve as the funds that each party will be “wagering.” Then, both parties sign the transaction with their private keys and submit this to the Bitcoin blockchain for confirmation.
2. Contract Execution Transactions (CET)
Next, the two parties agree to the terms outlined within the contract. This includes attributes like the data source, initial funding, and potential payouts.
Then, each party will sign two additional transactions, designated as a “Contract Execution Transaction (CET). The signed CETs represent the possible future outcomes (depending on the type of wager, these can be binary, or much more complex with thousands of potential outcomes). Since either of the two transactions requires a signature from the oracle to settle, they will remain unpublished.
CETs occur off-chain and function as payment channels on Bitcoin’s Lightning Network. Due to the higher costs and lower throughput of Bitcoin’s mainnet, Lightning Network is much more fitting for carrying out a DLC.
Once the oracle determines the outcome from the data feed, it will release the signature for the CET representing the winning bet. The CET for the losing bet is subsequently dismissed.
The final signature for the winning CET is posted by the oracle, and the winning party can execute the contract and claim their rightful funds. The payment channel is closed and the transaction is sent to the Bitcoin base layer.
Advantages of Discreet Log Contracts
There are many benefits that Discreet Log Contracts have over normal Bitcoin transactions.
DLCs are indistinguishable from any other 2-of-2 multi-signature Bitcoin transaction. Therefore, no information regarding the oracle is ever revealed publicly on the blockchain’s ledger.
DLCs do not require a third party to hold custody of funds over the duration of the transaction. Instead, each party can have peace of mind possessing their own private keys.
The Lightning Network sends only the opening and closing transactions to Bitcoin’s base layer. This reduces the energy required to process DLCs and can be exponentially significant if a transaction has thousands of possible outcomes.
Disadvantages of Discreet Log Contracts
Bitcoin DLCs could be better and are potential risks that users should be aware of until further advancements in blockchain technology are achieved.
Bridging a blockchain with off-chain, real-world data requires an element of centralization. For a DLC to execute, it must connect to an external network. This is in stark contrast to ordinary blockchain transactions, which always have the necessary information on-chain to reach consensus. Ultimately, this could present concerns regarding the legitimacy and accuracy of centralized oracles.
Currently, it can be difficult for users to establish a DLC when the counterparty is unknown before the transaction. For these contracts to be scalable, there must be a place for parties to conveniently meet and agree to contract terms.
Discreet Log Contracts on Bitcoin are a relatively new concept, having existed only since 2020. Consequently, they have yet to be battle-tested at scale. Similarly, there has yet to be an easily accessible infrastructure that allows users to seamlessly interact with DLCs.
Discreet Log Contract Use Cases
Powered by innovative smart contracts and oracle technology, Discreet Log Contracts have immense potential to serve hundreds of unique functions. Using the world’s most secure blockchain, DLCs can define the terms and obligations for any value exchanges that depend on real-world events.
Let’s examine a few prominent use cases for Discreet Log Contracts:
- Decentralized Finance
DLCs process financial data for prediction markets and peer-to-peer derivatives. By importing cross-chain data, parties could use smart contracts to “bet” on the future value of many different digital assets.
DLCs facilitate trust-minimized systems that better address information parity. These oracle-based solutions could drive the next generation business models for the largest providers in the insurance industry.
- Sports betting
DLCs enable peer-to-peer gambling on the Bitcoin network. With peer-to-peer bets, users eliminate the existence of the sportsbook “house edge” and increase their own odds.
Discreet Log Contracts: Private, Peer-to-Peer Smart Contracts for Bitcoin
Discreet Log Contracts are a unique type of smart contract that hold promise for expanding the future of Bitcoin DeFi.
They increase the utility of smart contracts beyond simple “bets” and incorporate real-world data into the Bitcoin blockchain. This opens Bitcoin smart contracts to a number of new use cases that can improve many functions of everyday life.
Looking to the future, DLCs will continue to grow alongside Bitcoin’s vast ecosystem of technologies and applications. With Lightning Network compatibility, DLCs are positioned to be scalable Bitcoin infrastructure from a technological perspective. Eventually, market makers and other innovations will emerge and make DLCs more simple and convenient for every Bitcoin user.