Discreet Log Contracts

Invisible smart contracts on the bitcoin blockchain

Discreet log contracts are an exciting new technology that facilitates conditional payments on bitcoin and compatible blockchains

By creating a Discreet Log Contract, two parties can form a monetary contract redistributing their funds to each other, based on preset conditions, without revealing any details of those conditions to the blockchain. Its appearance on the blockchain will be no different than an ordinary multi signature output. Therefore the contract is discreet in the sense that no external observer can learn its existence or details from the public ledger.

If you want to learn more about what this technology is, how it works, and how you can use it, you can either read the paper or read this blog post detailing its applications.

If you want to get started leveraging this technology, you can do so in a couple of ways:

Creating an oracle

If you have an interesting data feed that might be useful for people to use in their contracts, consider making an oracle out of it. We created a library for that exact purpose. Check out one of the tutorials available. We created one for Go, NodeJS and .NET Core

Essentially, you pre-commit to publishing the data feed’s value at a particular time in the future by publishing the public key, and you publish the values and signatures once the publication is due.

Right now, the publication could just be on a plain website. We are still working on a standardized publication mechanism. If a standard is decided we will add this to the library.

Executing Discreet Log Contracts

You can execute Discreet Log Contracts using lit, the Lightning Network implementation that the DCI is working on.

You can find a tutorial on setting up an environment consisting of two lit nodes and a Bitcoin Regtest here.

Here is a tutorial on executing a Discreet Log Contract from lit’s console client (lit-af).

We also have a RPC Client for LIT in Go, NodeJS and .NET Core that you can use to execute Discreet Log Contracts from your own software. Samples on how to do that are also available in Go, NodeJS or .NET Core.

People:

Thaddeus “Tadge” Dryja, MIT Digital Currency Initiative
Gert-Jaap Glasbergen, MIT Digital Currency Initiative

Outputs

Discreet Log Contracts (paper)

Abstract: Smart contracts [1] are an often touted feature of cryptographic currency systems such as Bitcoin, but they have yet to see widespread financial use. Two of the biggest hurdles to their implementation and adoption have been scalability of the smart contracts, and the difficulty in getting data external to the curency system into the smart contract. Privacy of the contract has been another issue to date. Discreet Log Contracts are a system which addresses the scalability and privacy concerns and seeks to minimize the trust required in the oracle which provides external data. The contracts are discreet in that external observers cannot detect the presence of the contract in the transaction log. They also hinge on knowledge of a discrete logarithm, which is a plus.

Authors:

James Lovejoy, MIT Media Lab

Discreet Log Contracts: invisible smart contracts on the Bitcoin blockchain (blog post)

On May 19, 2018, MIT’s Digital Currency Initiative and Fidelity Labs and organized the Layer 2 Summit in Boston. During this event, two people from the DCI, Tadge Dryja (Research Scientist) and Gert-Jaap Glasbergen (Software Developer), gave a presentation and demonstration on Discreet Log Contracts. The paper on Discreet Log Contracts is written by Tadge Dryja and published in 2017.

In this blog post, we’ll try to further explain what Discreet Log Contracts are, how they work, and what the next steps are if you’re interested in leveraging this technology.

Authors:

Gert-Jaap Glasbergen, MIT Media Lab

Previous
Previous

Cryptokernel | A Blockchain Toolkit

Next
Next

Double-Spend Counterattacks: Threat of Retaliation in Proof-of-Work Systems