Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?

London Bitcoin Devs links for Socratic on "Discreet Log Contracts" w/ Suredbits

August 10th 2021

YouTube Live link: https://www.youtube.com/watch?v=h6SkBwOCFsA

Zoom link (passcode is 170934 if needed ): https://us02web.zoom.us/j/84937108751?pwd=Yk1MM3hVNHlvT2lGa3I5MXVubENNZz09

Public meetup link: https://www.meetup.com/BitDevsLDN/events/279736686/

Private meetup link: https://www.meetup.com/London-Bitcoin-Devs/events/279736667/

The basic concept of a Discreet Log Contract

What is a Discreet Log Contract: https://suredbits.com/discreet-log-contracts-part-1-what-is-a-discreet-log-contract/

Z-man on smart contracts: https://zmnscpxj.github.io/bitcoin/unchained.html

Examples of DLCs in the wild

Nicolas Dorier and Chris Stewart on US presidential election: https://suredbits.com/settlement-of-election-dlc/

Chris Stewart and Nadav Kohen on Bitcoin price volatility: https://suredbits.com/settlement-of-volatility-dlc/

Blockstream and Crypto Garage on Bitcoin price: https://blockstream.com/2019/04/19/en-transacting-bitcoin-based-p2p-derivatives/

Lloyd Fournier CLI P2P betting: https://github.com/LLFourn/gun

How to Make a Prediction Market on Twitter with Bitcoin: https://github.com/LLFourn/gun/blob/master/docs/bet.md

Evolution of the DLC and variations

Tadge Dryja's original DLC white paper: https://adiabat.github.io/dlc.pdf

Tadge Dryja presentation on DLCs at MIT: https://www.youtube.com/watch?v=P6AX8KdXAts

How do they work (old non-adaptor version): https://suredbits.com/discreet-log-contracts-part-2-how-they-work/

Adaptor signatures

Use oracle's signature as a private key (non interactive), shows adaptor sig and once you see unencrypted one you can construct an adaptor sig for any tweak

Thibaut Le Guilly and Ichiro Kuwahara on DLC and Adaptor signatures: https://www.youtube.com/watch?v=hVAR6VRlgYk

ECDSA adaptor signatures: https://github.com/discreetlogcontracts/dlcspecs/blob/b0839bf56974f95f0ff8185df478b9ffe1c5afdd/v0Milestone.md#updated-ecdsa-adaptor-signatures-done

Why DLCs are great: https://suredbits.com/discreet-log-contracts-part-3-why-they-are-great/

Security and Trust Model for DLCs: https://suredbits.com/discreet-log-contracts-part-4-security-and-trust-model/

DLCs versus multisig: https://suredbits.com/dlcs-vs-multisig-censorship-resistance/

Nadav Kohen presentation at LA BitDevs: https://www.youtube.com/watch?v=a3rsFRLUQK0

DLC video demo: https://www.youtube.com/watch?v=jDTDqiaYmNU

Different oracle models

DLC oracle demo using Krystal Bull: https://www.youtube.com/watch?v=aoHBCm3_0uA

Suredbits oracle docs: https://test.suredbits.com/api/#discreet-log-contract-dlc-oracles

Oracle explorer: https://oracle.suredbits.com/

Oracle failure cases: https://suredbits.com/dlc-oracle-failure-cases/

Using multiple oracles: https://suredbits.com/multi-oracle-dlc-deep-dive/

Oracle announcements: https://oracle.suredbits.com/contract/enum/02311138dcbf36dd79f3e2e8c2fdf8dfd053bb3b1ed2c7e4f0935e119c1ffa43

DLC specs on Oracles: https://github.com/discreetlogcontracts/dlcspecs/blob/master/Oracle.md

DLC specs on multiple oracles: https://github.com/discreetlogcontracts/dlcspecs/blob/master/MultiOracle.md

Attacks on DLCs (Bitcoin Problems): https://bitcoin-problems.github.io/problems/secure-dlcs.html

DLCs within a payment channel

.....

Routed DLCs on Lightning

The outputs need to be fully collateralized (full amount locked in a bitcoin utxo on a commitment tx) which is why we keep commenting about capital inefficiency so if you have dlc1,dlc2,dlc3... in the the channel, you need dlc_output_1, dlc_output_2, dlc_output_3 that hang off of the commitment tx

those DLCs are removed from the commitment tx in the case

Oracle signature published Something like a mutual_close is sent between the two parties

Lightning Dice (AJ Towns): https://lists.linuxfoundation.org/pipermail/lightning-dev/2021-January/002937.html

Lightning Dice at Sydney Socratic: https://btctranscripts.com/sydney-bitcoin-meetup/2021-02-23-socratic-seminar/#lightning-dice-aj-towns

Integrating DLC channels in Lightning: https://medium.com/crypto-garage/scaling-dlc-part4-integrating-dlc-channels-in-the-lightning-network-cb60eed5c283

Barrier escrows: https://suredbits.com/payment-points-and-barrier-escrows/

Different DLC implementations

DLC specs: https://github.com/discreetlogcontracts/dlcspecs

v0 Milestone: https://github.com/discreetlogcontracts/dlcspecs/blob/b0839bf56974f95f0ff8185df478b9ffe1c5afdd/v0Milestone.md

Spec meeting notes: https://github.com/discreetlogcontracts/dlcspecs/tree/master/meeting

Last meeting (August 3rd 2021): https://github.com/discreetlogcontracts/dlcspecs/pull/172/files

Thibaut DLC PR in rust-lightning: https://github.com/rust-bitcoin/rust-lightning/pull/1031

Tadge's Lit Lightning implementation: https://github.com/mit-dci/lit/pulls

Schnorr and Taproot'd DLCs

.....

The impact of possible future soft forks on DLCs

Jeremy Rubin blog post on Taproot activation - You Betcha (uses Sapio but not OP_CTV): https://blog.bitmex.com/taproot-you-betcha/

"When a scriptSig is changed, the txid changes. If the txid of a funding transaction of a DLC changes, it invalidates all contract execution transactions (“CET”) that were created to spend that funding transaction. This effectively invalidates your DLC. In the future if the bitcoin protocol decides to upgrade SIGHASH_ANYPREVOUT, this will be less of a problem as the protocol can just bind to a specific script in an output, rather than the full outpoint itself."

https://suredbits.com/hashrate-derivatives-with-dlcs-coinbase-put-contracts/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment