SlideShare a Scribd company logo
Towards a Generalised
Blockchain Fabric
Code Block 2018
Alexei Zamyatin
Motivation
Different
Properties
Privacy
Scalability
Security
Expressiveness
Transparency
Consensus
Finality
Challenge:
Secure, privacy preserving,
scalable and decentralized
cross-chain communication
Today:
Over 1500 heterogeneous
cryptocurrencies
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
Why not simply agree on a single standard?
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
Why Decentralization?
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
Why Decentralization?
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
Why Decentralization?
X
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
Why Decentralization?
Miners
Developers
P2P
Network
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
Cross-Blockchain Communication Today
• Assumption: (Most) permissionless blockchains are decentralized
• How about the communication between these systems?
• Centralized liquidity providers necessary
• „Trusted“ 3rd parties (exchanges, …)
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
Transfer via Liquidity Providers
Liquidity Provider (LP)
Bob‘s BTC Wallet
Bob‘s
BTC
Account
Bob‘s
ETH
Account
Alice‘s ETH Wallet
LP‘s
BTC Wallet
LP‘s
ETH Wallet
LP fee
Tx fee Tx fee
BTC‘s P2P Network ETH‘s P2P NetworkTowards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
Properties Relevant for Interoperability
Interoperability
Privacy
Scalability
Security
Expressiveness
Transparency
Consensus Finality
(Simplified)
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
(Non-Exhaustive Example!)Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
General Categorization of Approaches
1. Centralized Exchanges
• ShapeShift, …
2. Notary Schemes
• Liquid, Interledger, Comit Network
3. Atomic Cross-Chain Swaps
• Pegged Sidechains and Cross-chain
Payment Channels (Lightning)
4. Chain Relays
• BTCRelay (BTC-ETH), PeaceRelay (ETC-ETH),
Project Alchemy (ZEC-ETH)
5. Merged Mining
• PoW reuse, Drivechains
6. Meta-layer constructions
• Polkadot, Cosmos
7. Sharding
• Aspen, Elastico
8. Based on Trusted Execution
Environments
• Tesseract, Teechan
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
General Categorization of Approaches
1. Centralized Exchanges
• ShapeShift, …
2. Notary Schemes (Trust N/M)
• Liquid, Interledger, Comit Network
3. Atomic Cross-Chain Swaps
• Pegged Sidechains and Cross-chain
Payment Channels (Lightning)
4. Chain Relays
• BTCRelay (BTC-ETH), PeaceRelay (ETC-ETH),
Project Alchemy (ZEC-ETH)
5. Merged Mining
• PoW reuse, Drivechains
6. Meta-layer protocols
• Polkadot, Cosmos
7. Sharding
• Aspen, Elastico
8. Based on Trusted Execution
Environments
• Tesseract, Teechan
Covered in today‘s session
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
Atomic Cross-Chain Swaps
• Operations on chain A and chain B have the same „trigger“
• E.g. revealing of a hash preimage
• Also referred to as Hash Locking
 Idea: Lock funds on A, while unlocking corresponding funds on B
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
BTC LTC
Alice
(has BTC wants LTC)
Bob
(has LTC wants BTC)
time
No broadcast
 No effect
Published to LTC
Published to BTC
Unpublished /
Sent directly to user
Legend
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
s  𝑟𝑎𝑛𝑑𝑜𝑚()
Tx1  if (𝐻 𝑖𝑛𝑝𝑢𝑡 = 𝐻 𝑠 ∧ ∃𝑠𝑖𝑔 𝐵 ∨
BTC LTC
Alice
(has BTC wants LTC)
Bob
(has LTC wants BTC)
time
No broadcast
 No effect
Published to LTC
Published to BTC
Unpublished /
Sent directly to user
Legend
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
s  𝑟𝑎𝑛𝑑𝑜𝑚()
Tx1  if (𝐻 𝑖𝑛𝑝𝑢𝑡 = 𝐻 𝑠 ∧ ∃𝑠𝑖𝑔 𝐵 ∨
BTC LTC
Alice
(has BTC wants LTC)
Bob
(has LTC wants BTC)
time
t1
No broadcast
 No effect
Published to LTC
Published to BTC
Unpublished /
Sent directly to user
Legend
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
s  𝑟𝑎𝑛𝑑𝑜𝑚()
Tx1  if (𝐻 𝑖𝑛𝑝𝑢𝑡 = 𝐻 𝑠 ∧ ∃𝑠𝑖𝑔 𝐵 ∨
BTC LTC
Tx2
𝑠𝑖𝑔𝑛 𝑠𝑘 𝐵, 𝐓𝐱𝟐
Alice
(has BTC wants LTC)
Bob
(has LTC wants BTC)
time
t1
No broadcast
 No effect
Published to LTC
Published to BTC
Unpublished /
Sent directly to user
Legend
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
s  𝑟𝑎𝑛𝑑𝑜𝑚()
Tx1  if (𝐻 𝑖𝑛𝑝𝑢𝑡 = 𝐻 𝑠 ∧ ∃𝑠𝑖𝑔 𝐵 ∨
BTC LTC
Tx2
𝑠𝑖𝑔𝑛 𝑠𝑘 𝐵, 𝐓𝐱𝟐
Tx1
Alice
(has BTC wants LTC)
Bob
(has LTC wants BTC)
time
t1
A can use Tx2
after 𝑡1to get
refund
Published to LTC
Published to BTC
Unpublished /
Sent directly to user
Legend
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
BTC LTC
Tx2
𝑠𝑖𝑔𝑛 𝑠𝑘 𝐵, 𝐓𝐱𝟐
Tx1
t1
Alice
(has BTC wants LTC)
Bob
(has LTC wants BTC)
time
A can use Tx2
after 𝑡1to get
refund
t2
Published to LTC
Published to BTC
Unpublished /
Sent directly to user
Legend
s  𝑟𝑎𝑛𝑑𝑜𝑚()
Tx1  if (𝐻 𝑖𝑛𝑝𝑢𝑡 = 𝐻 𝑠 ∧ ∃𝑠𝑖𝑔 𝐵 ∨
Tx3  if (𝐻 𝑖𝑛𝑝𝑢𝑡 = 𝐻 𝑠 ∧ ∃𝑠𝑖𝑔 𝐴 ∨
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
s  𝑟𝑎𝑛𝑑𝑜𝑚()
Tx1  if (𝐻 𝑖𝑛𝑝𝑢𝑡 = 𝐻 𝑠 ∧ ∃𝑠𝑖𝑔 𝐵 ∨
BTC LTC
Tx2
𝑠𝑖𝑔𝑛 𝑠𝑘 𝐵, 𝐓𝐱𝟐
Tx1
Tx3  if (𝐻 𝑖𝑛𝑝𝑢𝑡 = 𝐻 𝑠 ∧ ∃𝑠𝑖𝑔 𝐴 ∨
Tx4
𝑠𝑖𝑔𝑛 𝑠𝑘 𝐴, 𝐓𝐱𝟒
t1
Alice
(has BTC wants LTC)
Bob
(has LTC wants BTC)
t2
time
A can use Tx2
after 𝑡1to get
refund
Published to LTC
Published to BTC
Unpublished /
Sent directly to user
Legend
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
s  𝑟𝑎𝑛𝑑𝑜𝑚()
Tx1  if (𝐻 𝑖𝑛𝑝𝑢𝑡 = 𝐻 𝑠 ∧ ∃𝑠𝑖𝑔 𝐵 ∨
BTC LTC
Tx2
𝑠𝑖𝑔𝑛 𝑠𝑘 𝐵, 𝐓𝐱𝟐
Tx1
Tx3  if (𝐻 𝑖𝑛𝑝𝑢𝑡 = 𝐻 𝑠 ∧ ∃𝑠𝑖𝑔 𝐴 ∨
Tx4
𝑠𝑖𝑔𝑛 𝑠𝑘 𝐴, 𝐓𝐱𝟒
Tx5 (spends Tx3 revealing s)
t1
Alice
(has BTC wants LTC)
Bob
(has LTC wants BTC)
t2
Tx3
time
A must spend
Tx3 before 𝑡2,
otherwise B
can claim
refund;
B must spend
Tx1 before 𝑡1,
otherwise A
can claim
refund
Published to LTC
Published to BTC
Unpublished /
Sent directly to user
Legend
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
s  𝑟𝑎𝑛𝑑𝑜𝑚()
Tx1  if (𝐻 𝑖𝑛𝑝𝑢𝑡 = 𝐻 𝑠 ∧ ∃𝑠𝑖𝑔 𝐵 ∨
BTC LTC
Tx2
𝑠𝑖𝑔𝑛 𝑠𝑘 𝐵, 𝐓𝐱𝟐
Tx1
Tx3  if (𝐻 𝑖𝑛𝑝𝑢𝑡 = 𝐻 𝑠 ∧ ∃𝑠𝑖𝑔 𝐴 ∨
Tx4
𝑠𝑖𝑔𝑛 𝑠𝑘 𝐴, 𝐓𝐱𝟒
Tx5 (spends Tx3 revealing s)
Tx6 (spends Tx1 using s)
t1
Alice
(has BTC wants LTC)
Bob
(has LTC wants BTC)
t2
Tx3
time
Swap
completed!
Published to LTC
Published to BTC
Unpublished /
Sent directly to user
Legend
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
Interledger
Source:
Thomas, Stefan, and Evan Schwartz. "A protocol
for interledger payments." URL
https://interledger. org/interledger. pdf (2015).
• „Ledger-provided“ escrows
• Lockbox  unlock by proof that receiver
has received payment
• Must be implemented on-chain
• Atomic Mode:
• Two-Phase Commit with N notaries
as coordinators (PBFT, …)
 3f + 1 honest notaries required
• Global timeout
• „Federated“
• Universal mode: hash locking
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
Atomic Cross-Chain Swaps – Pro‘s / Con‘s
+ Atomicity
• Swap only performed if both parties perform the necessary Tx on the respective chains
+ Both parties can withdraw funds after time limit in case of failure
- Funds locked until swap complete or time lock passed
• DoS attacks possible
- Sender and Receiver must monitor both chains
• N chains  N running clients
• Alternatively: Federated constructions (e.g. Interledger)
• Potential use case for SPV-Proofs / NiPoPoWs
- Requires timely action from both parties
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
Atomic Cross-Chain Swaps - Properties
• StatelessTransferred Information
• Cryptographic (although other types also applicable)Validation
• Bi-directionalDirection
• OptionalTTP
• ProbabilisticFinality Guarantees
• Sender + Receiver online
Party Availability
Requirements
• Limited to the least expressive chain‘s scriptScript Expressiveness
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
Chain Relays
• System inside chain A is able to read, interpret and validate
events/state of chain B.
 Idea: prove that a transaction occurred on chain A to release funds
on chain B.
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
BTC Relay
• Smart Contract on ETH validating BTC
headers (like SPV Clients)
• Headers fed to SC
• Transactions in BTC can then be validated
• Can notify swap contract that BTC has been
transferred
• Validation must be possible on-chain
• E.g. not feasible for Scrypt
• Native support?
Source: http://btcrelay.org/
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
BTC Relay – BTC Swap
Ethereum
Bitcoin
BTC Swap
Has BTC, wants ETH Has ETH, wants BTC
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
BTC Relay – BTC Swap
Ethereum
1) Bob sends
 ETH
 Alice s ETH account
 his BTC address
 agreed exchange info
to escrow contract
Bitcoin
BTC Swap
Has BTC, wants ETH Has ETH, wants BTC
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
BTC Relay – BTC Swap
Ethereum
1) Bob sends
 ETH
 Alice s ETH account
 his BTC address
 agreed exchange info
to escrow contract
Bitcoin
BTC Swap
2) Alice sends BTC to Bob’s address (TxBTC)
Has BTC, wants ETH Has ETH, wants BTC
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
BTC Relay – BTC Swap
Ethereum
1) Bob sends
 ETH
 Alice s ETH account
 his BTC address
 agreed exchange info
to escrow contract
Bitcoin
BTC Swap
3) Alice calls
btcrelay.relayTx(TxBTC, addrBTCSwap)
2) Alice sends BTC to Bob’s address (TxBTC)
Has BTC, wants ETH Has ETH, wants BTC
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
BTC Relay – BTC Swap
Ethereum
1) Bob sends
 ETH
 Alice s ETH account
 his BTC address
 agreed exchange info
to escrow contract
Bitcoin
BTC Swap
3) Alice calls
btcrelay.relayTx(TxBTC, addrBTCSwap)
2) Alice sends BTC to Bob’s address (TxBTC)
4) BTC Relay verifies TxBTC was
performed in Bitcoin
Has BTC, wants ETH Has ETH, wants BTC
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
BTC Relay – BTC Swap
Ethereum
1) Bob sends
 ETH
 Alice s ETH account
 his BTC address
 agreed exchange info
to escrow contract
Bitcoin
BTC Swap
3) Alice calls
btcrelay.relayTx(TxBTC, addrBTCSwap)
2) Alice sends BTC to Bob’s address (TxBTC)
4) BTC Relay verifies TxBTC was
performed in Bitcoin
5) BTC Relay invokes
processTransaction() in
BTC Swap
Has BTC, wants ETH Has ETH, wants BTC
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
BTC Relay – BTC Swap
Ethereum
1) Bob sends
 ETH
 Alice s ETH account
 his BTC address
 agreed exchange info
to escrow contract
Bitcoin
BTC Swap
3) Alice calls
btcrelay.relayTx(TxBTC, addrBTCSwap)
2) Alice sends BTC to Bob’s address (TxBTC)
4) BTC Relay verifies TxBTC was
performed in Bitcoin
5) BTC Relay invokes
processTransaction() in
BTC Swap
6) BTC Swap
releases payment to
Alice
Has BTC, wants ETH Has ETH, wants BTC
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
Chain Relays – Pro‘s / Con‘s
+ “Non-interactive”
• Publicly verifiable computations in Smart Contracts
+ Multi-purpose
• More use cases than 1:1 asset exchange
• Events on chain A can trigger complex processes on chain B (e.g. for bribing miners [McCory et al. ‘18])
- Relay contract must contain all headers of the connected chain
• Ongoing research to reduce storage requirements / simplify proofing mechanism
- Sufficient incentive for users to submit block headers necessary
• At least to cover gas costs
• Working fee model necessary
- Currently no freshness guarantees
• i.e., BTC relay may fall far behind Bitcoin
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
Chain Relays - Properties
• StatelessTransferred Information
• CryptographicValidation
• UnidirectionalDirection
• NoneTTP
• ProbabilisticFinality Guarantees
• Contract deployed & available, Receiver online
Party Availability
Requirements
• „Turing complete“Script Expressiveness
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
Meta-Layer Protocols
• Introduce a second communication layer
• Abstraction of blockchain-specific properties
• Rely on game theoretic incentives
• Interactions between different actors/roles
• Utilize described mechanisms to integrate external chains
• Notary schemes, chain relays, atomic swaps,…
 „Bridges“
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
Polkadot
• One of Parity‘s flagship projects
• Two chain types:
• Para(llel)chains – globally-coherent dynamic data structures/blockchains
• Relay chain(s) – base communication/synchronization layer
• Relay Chain consensus:
• Initially: permissioned, i.e., 3f+1 BFT algorithm (e.g. HoneyBadgerBFT,
Tendermint, …)
• Planned: Delegated Proof-of-Stake (DPoS)
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
Polkadot - Relay Chains and Parachains
Source:
Wood, Gavin. "Polkadot: Vision for a heterogeneous multi-chain framework." URL
https://github.com/polkadot-io/polkadot-white-paper/raw/master/PolkaDotPaper.pdf (2016).
Relay Chain Parachain
n1
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
Relay Chain Parachain
mn
Polkadot - Relay Chains and Parachains
Source:
Wood, Gavin. "Polkadot: Vision for a heterogeneous multi-chain framework." URL
https://github.com/polkadot-io/polkadot-white-paper/raw/master/PolkaDotPaper.pdf (2016).Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
Polkadot - Relay Chains and Parachains
Source:
Wood, Gavin. "Polkadot: Vision for a heterogeneous multi-chain framework." URL
https://github.com/polkadot-io/polkadot-white-paper/raw/master/PolkaDotPaper.pdf (2016).
Chain
Relay Chain
connects to
m
n
Parachain
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
Polkadot - Relay Chains and Parachains
Source:
Wood, Gavin. "Polkadot: Vision for a heterogeneous multi-chain framework." URL
https://github.com/polkadot-io/polkadot-white-paper/raw/master/PolkaDotPaper.pdf (2016).
Chain
Relay Chain
connects to
m
n
Parachain
Transaction
Interchain On-chain
contains
1n
triggers
11
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
Polkadot - Actors
• Validator
1. Validates parachain transactions/blocks
2. Agrees on interchain TX  relay chain
validation
• Stake slashed in case of misbehaviour
• Nominator
• Can provide stake for validator
• Collator
• Collects parachain TX and sends block
candidates to validators
• Fisherman
• Monitors validators for misbehaviour / Reports
to other validators
• Clients/Light Clients
Source:
Wood, Gavin. "Polkadot: Vision for a heterogeneous multi-chain framework." URL
https://github.com/polkadot-io/polkadot-white-paper/raw/master/PolkaDotPaper.pdf (2016).Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
Polkadot - Actors
• Relay Chain:
• Validator
1. Validates parachain transactions/blocks
2. Agrees on interchain TX  relay chain
validation
• Stake slashed in case of misbehaviour
• Nominator
• Can provide stake for validator
• Parachain
• Collator
• Collects parachain TX and sends block candidates
to validators
• Fisherman
• Monitors validators for misbehaviour / Reports
to other validators
• Clients/Light Clients
Participant
ValidatorNominator FishermanCollator
Relay node
Para-node
stakes for
nm
monitors / reports failure
n m
provides parachain
blocks
n m
validates/
slashes
n
m
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
Polkadot – Domain Overview (simplified)
Chain
Relay Chain Parachain
Participant
ValidatorNominator FishermanCollator
Transaction
Interchain
Transaction
Parachain
Transaction
triggers
11
Relay node
Para-node
has
1
connects to
m
n
n
1 1
n
stakes for
nm
monitors / reports failure
n m
provides parachain
blocks
n m
Participant/Transaction relations
omitted for simplicity
validates/
slashes
n
m
n
FIFO Transaction
Queue
contains
n
1
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
Polkadot - Challenges
• Game theoretic incentives not sufficiently studied
• Modelling of incentives and potential attacks necessary
• High communication complexity
• Extent of necessary overhead unclear
• A lot of technical details still not clearly defined
• How to maintain information on asset state after cross-chain TX?
• Consensus finality  what happens if parachains fork? Or relay chain forks?
• Address/account scheme
• Privacy features
• ….
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
Cosmos
• Cosmos Hub and Zones (child blockchains)
• Each Zone can become a hub in turn
• Zones run Tendermint BFT (3f + 1)
• Fixed known set of validators
• Cross-chain communication similar to two-
way-peg
• Bridges to other chains necessary (e.g. ETH)
• Permissioned setup
• Tested with 65 validator nodes
• Initially 100, scale up to 300 within 10 years
Source:
Kwon, Jae, and Buchman, Ethan. „Cosmos: A Network of Distributed
Ledgers“. URL
https://github.com/cosmos/cosmos/blob/master/WHITEPAPER.md (2016)
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
Outlook
• Rapidly increasing number of projects promising „Multi-blockchain protocols“
• Often limited technical details provided  unclear how exactly communication will be
facilitated.
• Many rely on versions of atomic swaps or chain relays under a (semi-) centralized setup
• Active development
• 1:1 Bridges between Ethereum and other networks in development
• Lightning cross-chain swaps between BTC and LTC
• Overlay protocols / Colored Coins
• …
• No “truly decentralized” solution yet
 Alarming shift towards centralized approaches
Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
Questions?
Alexei Zamyatin
a.zamyatin@imperial.ac.uk
PGP ID: 0x5485B999
PGP FP: 2F5F E92D CDAC 15B0 84A6 9FE9 9018 A958 5485 B999
@alexeiZamyatin

More Related Content

PDF
Intro. to Lightning Network (Bitcoin/Litecoin) - Blockchain Developers Malaysia
 
PDF
Introduction to Lightning Network
PPTX
Technology of Lightning Network in Tel Aviv, Israel
PDF
Lightning Network
PPTX
Hyperledger Consensus Algorithms
PDF
Ethereum VM and DSLs for Smart Contracts (updated on May 12th 2015)
PPTX
Webinar in English for the Token Bridge between RSK and Ethereum
PDF
Bitcoins Math
Intro. to Lightning Network (Bitcoin/Litecoin) - Blockchain Developers Malaysia
 
Introduction to Lightning Network
Technology of Lightning Network in Tel Aviv, Israel
Lightning Network
Hyperledger Consensus Algorithms
Ethereum VM and DSLs for Smart Contracts (updated on May 12th 2015)
Webinar in English for the Token Bridge between RSK and Ethereum
Bitcoins Math

What's hot (10)

PPTX
Blockchain. A Guide For Beginners
PPTX
Consensus Algorithms - Nakov at CryptoBlockCon - Las Vegas (2018)
ODP
Intro to Blockchain - And, by the way, what the heck is proof-of-work?
PDF
Hyperchains
PDF
Blockchain Interoperability using Cosmos Interblockchain Communication
PDF
Weaving the ILP Fabric into Bigchain DB
PPTX
A research-oriented introduction to the cryptographic currencies (starting wi...
PPTX
Consensus Algorithms - Nakov @ jProfessionals - Jan 2018
ODP
Proof-of-Stake & Its Improvements (San Francisco Bitcoin Devs Hackathon)
PPTX
Introduction to Blockchain & development
Blockchain. A Guide For Beginners
Consensus Algorithms - Nakov at CryptoBlockCon - Las Vegas (2018)
Intro to Blockchain - And, by the way, what the heck is proof-of-work?
Hyperchains
Blockchain Interoperability using Cosmos Interblockchain Communication
Weaving the ILP Fabric into Bigchain DB
A research-oriented introduction to the cryptographic currencies (starting wi...
Consensus Algorithms - Nakov @ jProfessionals - Jan 2018
Proof-of-Stake & Its Improvements (San Francisco Bitcoin Devs Hackathon)
Introduction to Blockchain & development
Ad

Similar to Towards a Generalised Blockchain Fabric @ CodeBlock 2018 (20)

PDF
Upgrading the Bitcoin protocol - Simone Bronzini - Codemotion Rome 2018
PDF
Blockchain - a formal introduction
ODP
Blockchan For Developers
PDF
Interoperability in Blockchain
PPTX
BlockchainConf.tech - Build a private blockchain workshop
PPTX
Blockchain Hyper Ledger Fabric : Bangkok Conference
PDF
Architecture of the Hyperledger Blockchain Fabric - Christian Cachin - IBM Re...
PDF
Blockchain, Hyperledger, DeFi, Web 3.0 - understanding and concepts
PPTX
Deploy a blockchain web-app with Hyperledger Fabric 1.4 - Concepts & Code
PDF
Deployablockchainwebappwithhyperledgerfabricpresentation 190820170703
PDF
IRJET- Study of Blockchain and its Concepts
PPTX
Block chain introduction to the world and how we can utilise it
PDF
Blockchain IoT Night / 25th Oct 2017
PDF
An introduction to blockchain and hyperledger v ru
PPTX
Block chain introduction to the world and how we can utilise it
PDF
Lecture 8 Hyperledger Fabric 2022f.pdf
PPSX
Blockchain HyperLedger Fabric Internals - Clavent
PPTX
Designing Quality-Driven Blockchain Networks
 
PPTX
Blockchain for Python Developers - Pyjamas Conf 2020
PPTX
Blockchain Intro to Hyperledger Fabric
Upgrading the Bitcoin protocol - Simone Bronzini - Codemotion Rome 2018
Blockchain - a formal introduction
Blockchan For Developers
Interoperability in Blockchain
BlockchainConf.tech - Build a private blockchain workshop
Blockchain Hyper Ledger Fabric : Bangkok Conference
Architecture of the Hyperledger Blockchain Fabric - Christian Cachin - IBM Re...
Blockchain, Hyperledger, DeFi, Web 3.0 - understanding and concepts
Deploy a blockchain web-app with Hyperledger Fabric 1.4 - Concepts & Code
Deployablockchainwebappwithhyperledgerfabricpresentation 190820170703
IRJET- Study of Blockchain and its Concepts
Block chain introduction to the world and how we can utilise it
Blockchain IoT Night / 25th Oct 2017
An introduction to blockchain and hyperledger v ru
Block chain introduction to the world and how we can utilise it
Lecture 8 Hyperledger Fabric 2022f.pdf
Blockchain HyperLedger Fabric Internals - Clavent
Designing Quality-Driven Blockchain Networks
 
Blockchain for Python Developers - Pyjamas Conf 2020
Blockchain Intro to Hyperledger Fabric
Ad

Recently uploaded (20)

PDF
Computing-Curriculum for Schools in Ghana
PDF
grade 11-chemistry_fetena_net_5883.pdf teacher guide for all student
PPTX
human mycosis Human fungal infections are called human mycosis..pptx
PDF
Anesthesia in Laparoscopic Surgery in India
PPTX
Tissue processing ( HISTOPATHOLOGICAL TECHNIQUE
PPTX
Microbial diseases, their pathogenesis and prophylaxis
PDF
Black Hat USA 2025 - Micro ICS Summit - ICS/OT Threat Landscape
PDF
The Lost Whites of Pakistan by Jahanzaib Mughal.pdf
PDF
Abdominal Access Techniques with Prof. Dr. R K Mishra
PPTX
master seminar digital applications in india
PDF
A GUIDE TO GENETICS FOR UNDERGRADUATE MEDICAL STUDENTS
PDF
Supply Chain Operations Speaking Notes -ICLT Program
PPTX
202450812 BayCHI UCSC-SV 20250812 v17.pptx
 
PPTX
1st Inaugural Professorial Lecture held on 19th February 2020 (Governance and...
PDF
RMMM.pdf make it easy to upload and study
PDF
Module 4: Burden of Disease Tutorial Slides S2 2025
PPTX
school management -TNTEU- B.Ed., Semester II Unit 1.pptx
PPTX
Pharmacology of Heart Failure /Pharmacotherapy of CHF
PPTX
IMMUNITY IMMUNITY refers to protection against infection, and the immune syst...
PDF
Saundersa Comprehensive Review for the NCLEX-RN Examination.pdf
Computing-Curriculum for Schools in Ghana
grade 11-chemistry_fetena_net_5883.pdf teacher guide for all student
human mycosis Human fungal infections are called human mycosis..pptx
Anesthesia in Laparoscopic Surgery in India
Tissue processing ( HISTOPATHOLOGICAL TECHNIQUE
Microbial diseases, their pathogenesis and prophylaxis
Black Hat USA 2025 - Micro ICS Summit - ICS/OT Threat Landscape
The Lost Whites of Pakistan by Jahanzaib Mughal.pdf
Abdominal Access Techniques with Prof. Dr. R K Mishra
master seminar digital applications in india
A GUIDE TO GENETICS FOR UNDERGRADUATE MEDICAL STUDENTS
Supply Chain Operations Speaking Notes -ICLT Program
202450812 BayCHI UCSC-SV 20250812 v17.pptx
 
1st Inaugural Professorial Lecture held on 19th February 2020 (Governance and...
RMMM.pdf make it easy to upload and study
Module 4: Burden of Disease Tutorial Slides S2 2025
school management -TNTEU- B.Ed., Semester II Unit 1.pptx
Pharmacology of Heart Failure /Pharmacotherapy of CHF
IMMUNITY IMMUNITY refers to protection against infection, and the immune syst...
Saundersa Comprehensive Review for the NCLEX-RN Examination.pdf

Towards a Generalised Blockchain Fabric @ CodeBlock 2018

  • 1. Towards a Generalised Blockchain Fabric Code Block 2018 Alexei Zamyatin
  • 2. Motivation Different Properties Privacy Scalability Security Expressiveness Transparency Consensus Finality Challenge: Secure, privacy preserving, scalable and decentralized cross-chain communication Today: Over 1500 heterogeneous cryptocurrencies Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 3. Why not simply agree on a single standard? Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 4. Why Decentralization? Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 5. Why Decentralization? Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 6. Why Decentralization? X Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 7. Why Decentralization? Miners Developers P2P Network Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 8. Cross-Blockchain Communication Today • Assumption: (Most) permissionless blockchains are decentralized • How about the communication between these systems? • Centralized liquidity providers necessary • „Trusted“ 3rd parties (exchanges, …) Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 9. Transfer via Liquidity Providers Liquidity Provider (LP) Bob‘s BTC Wallet Bob‘s BTC Account Bob‘s ETH Account Alice‘s ETH Wallet LP‘s BTC Wallet LP‘s ETH Wallet LP fee Tx fee Tx fee BTC‘s P2P Network ETH‘s P2P NetworkTowards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 10. Properties Relevant for Interoperability Interoperability Privacy Scalability Security Expressiveness Transparency Consensus Finality (Simplified) Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 11. (Non-Exhaustive Example!)Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 12. General Categorization of Approaches 1. Centralized Exchanges • ShapeShift, … 2. Notary Schemes • Liquid, Interledger, Comit Network 3. Atomic Cross-Chain Swaps • Pegged Sidechains and Cross-chain Payment Channels (Lightning) 4. Chain Relays • BTCRelay (BTC-ETH), PeaceRelay (ETC-ETH), Project Alchemy (ZEC-ETH) 5. Merged Mining • PoW reuse, Drivechains 6. Meta-layer constructions • Polkadot, Cosmos 7. Sharding • Aspen, Elastico 8. Based on Trusted Execution Environments • Tesseract, Teechan Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 13. General Categorization of Approaches 1. Centralized Exchanges • ShapeShift, … 2. Notary Schemes (Trust N/M) • Liquid, Interledger, Comit Network 3. Atomic Cross-Chain Swaps • Pegged Sidechains and Cross-chain Payment Channels (Lightning) 4. Chain Relays • BTCRelay (BTC-ETH), PeaceRelay (ETC-ETH), Project Alchemy (ZEC-ETH) 5. Merged Mining • PoW reuse, Drivechains 6. Meta-layer protocols • Polkadot, Cosmos 7. Sharding • Aspen, Elastico 8. Based on Trusted Execution Environments • Tesseract, Teechan Covered in today‘s session Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 14. Atomic Cross-Chain Swaps • Operations on chain A and chain B have the same „trigger“ • E.g. revealing of a hash preimage • Also referred to as Hash Locking  Idea: Lock funds on A, while unlocking corresponding funds on B Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 15. BTC LTC Alice (has BTC wants LTC) Bob (has LTC wants BTC) time No broadcast  No effect Published to LTC Published to BTC Unpublished / Sent directly to user Legend Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 16. s  𝑟𝑎𝑛𝑑𝑜𝑚() Tx1  if (𝐻 𝑖𝑛𝑝𝑢𝑡 = 𝐻 𝑠 ∧ ∃𝑠𝑖𝑔 𝐵 ∨ BTC LTC Alice (has BTC wants LTC) Bob (has LTC wants BTC) time No broadcast  No effect Published to LTC Published to BTC Unpublished / Sent directly to user Legend Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 17. s  𝑟𝑎𝑛𝑑𝑜𝑚() Tx1  if (𝐻 𝑖𝑛𝑝𝑢𝑡 = 𝐻 𝑠 ∧ ∃𝑠𝑖𝑔 𝐵 ∨ BTC LTC Alice (has BTC wants LTC) Bob (has LTC wants BTC) time t1 No broadcast  No effect Published to LTC Published to BTC Unpublished / Sent directly to user Legend Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 18. s  𝑟𝑎𝑛𝑑𝑜𝑚() Tx1  if (𝐻 𝑖𝑛𝑝𝑢𝑡 = 𝐻 𝑠 ∧ ∃𝑠𝑖𝑔 𝐵 ∨ BTC LTC Tx2 𝑠𝑖𝑔𝑛 𝑠𝑘 𝐵, 𝐓𝐱𝟐 Alice (has BTC wants LTC) Bob (has LTC wants BTC) time t1 No broadcast  No effect Published to LTC Published to BTC Unpublished / Sent directly to user Legend Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 19. s  𝑟𝑎𝑛𝑑𝑜𝑚() Tx1  if (𝐻 𝑖𝑛𝑝𝑢𝑡 = 𝐻 𝑠 ∧ ∃𝑠𝑖𝑔 𝐵 ∨ BTC LTC Tx2 𝑠𝑖𝑔𝑛 𝑠𝑘 𝐵, 𝐓𝐱𝟐 Tx1 Alice (has BTC wants LTC) Bob (has LTC wants BTC) time t1 A can use Tx2 after 𝑡1to get refund Published to LTC Published to BTC Unpublished / Sent directly to user Legend Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 20. BTC LTC Tx2 𝑠𝑖𝑔𝑛 𝑠𝑘 𝐵, 𝐓𝐱𝟐 Tx1 t1 Alice (has BTC wants LTC) Bob (has LTC wants BTC) time A can use Tx2 after 𝑡1to get refund t2 Published to LTC Published to BTC Unpublished / Sent directly to user Legend s  𝑟𝑎𝑛𝑑𝑜𝑚() Tx1  if (𝐻 𝑖𝑛𝑝𝑢𝑡 = 𝐻 𝑠 ∧ ∃𝑠𝑖𝑔 𝐵 ∨ Tx3  if (𝐻 𝑖𝑛𝑝𝑢𝑡 = 𝐻 𝑠 ∧ ∃𝑠𝑖𝑔 𝐴 ∨ Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 21. s  𝑟𝑎𝑛𝑑𝑜𝑚() Tx1  if (𝐻 𝑖𝑛𝑝𝑢𝑡 = 𝐻 𝑠 ∧ ∃𝑠𝑖𝑔 𝐵 ∨ BTC LTC Tx2 𝑠𝑖𝑔𝑛 𝑠𝑘 𝐵, 𝐓𝐱𝟐 Tx1 Tx3  if (𝐻 𝑖𝑛𝑝𝑢𝑡 = 𝐻 𝑠 ∧ ∃𝑠𝑖𝑔 𝐴 ∨ Tx4 𝑠𝑖𝑔𝑛 𝑠𝑘 𝐴, 𝐓𝐱𝟒 t1 Alice (has BTC wants LTC) Bob (has LTC wants BTC) t2 time A can use Tx2 after 𝑡1to get refund Published to LTC Published to BTC Unpublished / Sent directly to user Legend Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 22. Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 23. s  𝑟𝑎𝑛𝑑𝑜𝑚() Tx1  if (𝐻 𝑖𝑛𝑝𝑢𝑡 = 𝐻 𝑠 ∧ ∃𝑠𝑖𝑔 𝐵 ∨ BTC LTC Tx2 𝑠𝑖𝑔𝑛 𝑠𝑘 𝐵, 𝐓𝐱𝟐 Tx1 Tx3  if (𝐻 𝑖𝑛𝑝𝑢𝑡 = 𝐻 𝑠 ∧ ∃𝑠𝑖𝑔 𝐴 ∨ Tx4 𝑠𝑖𝑔𝑛 𝑠𝑘 𝐴, 𝐓𝐱𝟒 Tx5 (spends Tx3 revealing s) t1 Alice (has BTC wants LTC) Bob (has LTC wants BTC) t2 Tx3 time A must spend Tx3 before 𝑡2, otherwise B can claim refund; B must spend Tx1 before 𝑡1, otherwise A can claim refund Published to LTC Published to BTC Unpublished / Sent directly to user Legend Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 24. s  𝑟𝑎𝑛𝑑𝑜𝑚() Tx1  if (𝐻 𝑖𝑛𝑝𝑢𝑡 = 𝐻 𝑠 ∧ ∃𝑠𝑖𝑔 𝐵 ∨ BTC LTC Tx2 𝑠𝑖𝑔𝑛 𝑠𝑘 𝐵, 𝐓𝐱𝟐 Tx1 Tx3  if (𝐻 𝑖𝑛𝑝𝑢𝑡 = 𝐻 𝑠 ∧ ∃𝑠𝑖𝑔 𝐴 ∨ Tx4 𝑠𝑖𝑔𝑛 𝑠𝑘 𝐴, 𝐓𝐱𝟒 Tx5 (spends Tx3 revealing s) Tx6 (spends Tx1 using s) t1 Alice (has BTC wants LTC) Bob (has LTC wants BTC) t2 Tx3 time Swap completed! Published to LTC Published to BTC Unpublished / Sent directly to user Legend Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 25. Interledger Source: Thomas, Stefan, and Evan Schwartz. "A protocol for interledger payments." URL https://interledger. org/interledger. pdf (2015). • „Ledger-provided“ escrows • Lockbox  unlock by proof that receiver has received payment • Must be implemented on-chain • Atomic Mode: • Two-Phase Commit with N notaries as coordinators (PBFT, …)  3f + 1 honest notaries required • Global timeout • „Federated“ • Universal mode: hash locking Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 26. Atomic Cross-Chain Swaps – Pro‘s / Con‘s + Atomicity • Swap only performed if both parties perform the necessary Tx on the respective chains + Both parties can withdraw funds after time limit in case of failure - Funds locked until swap complete or time lock passed • DoS attacks possible - Sender and Receiver must monitor both chains • N chains  N running clients • Alternatively: Federated constructions (e.g. Interledger) • Potential use case for SPV-Proofs / NiPoPoWs - Requires timely action from both parties Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 27. Atomic Cross-Chain Swaps - Properties • StatelessTransferred Information • Cryptographic (although other types also applicable)Validation • Bi-directionalDirection • OptionalTTP • ProbabilisticFinality Guarantees • Sender + Receiver online Party Availability Requirements • Limited to the least expressive chain‘s scriptScript Expressiveness Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 28. Chain Relays • System inside chain A is able to read, interpret and validate events/state of chain B.  Idea: prove that a transaction occurred on chain A to release funds on chain B. Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 29. BTC Relay • Smart Contract on ETH validating BTC headers (like SPV Clients) • Headers fed to SC • Transactions in BTC can then be validated • Can notify swap contract that BTC has been transferred • Validation must be possible on-chain • E.g. not feasible for Scrypt • Native support? Source: http://btcrelay.org/ Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 30. BTC Relay – BTC Swap Ethereum Bitcoin BTC Swap Has BTC, wants ETH Has ETH, wants BTC Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 31. BTC Relay – BTC Swap Ethereum 1) Bob sends  ETH  Alice s ETH account  his BTC address  agreed exchange info to escrow contract Bitcoin BTC Swap Has BTC, wants ETH Has ETH, wants BTC Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 32. BTC Relay – BTC Swap Ethereum 1) Bob sends  ETH  Alice s ETH account  his BTC address  agreed exchange info to escrow contract Bitcoin BTC Swap 2) Alice sends BTC to Bob’s address (TxBTC) Has BTC, wants ETH Has ETH, wants BTC Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 33. BTC Relay – BTC Swap Ethereum 1) Bob sends  ETH  Alice s ETH account  his BTC address  agreed exchange info to escrow contract Bitcoin BTC Swap 3) Alice calls btcrelay.relayTx(TxBTC, addrBTCSwap) 2) Alice sends BTC to Bob’s address (TxBTC) Has BTC, wants ETH Has ETH, wants BTC Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 34. BTC Relay – BTC Swap Ethereum 1) Bob sends  ETH  Alice s ETH account  his BTC address  agreed exchange info to escrow contract Bitcoin BTC Swap 3) Alice calls btcrelay.relayTx(TxBTC, addrBTCSwap) 2) Alice sends BTC to Bob’s address (TxBTC) 4) BTC Relay verifies TxBTC was performed in Bitcoin Has BTC, wants ETH Has ETH, wants BTC Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 35. BTC Relay – BTC Swap Ethereum 1) Bob sends  ETH  Alice s ETH account  his BTC address  agreed exchange info to escrow contract Bitcoin BTC Swap 3) Alice calls btcrelay.relayTx(TxBTC, addrBTCSwap) 2) Alice sends BTC to Bob’s address (TxBTC) 4) BTC Relay verifies TxBTC was performed in Bitcoin 5) BTC Relay invokes processTransaction() in BTC Swap Has BTC, wants ETH Has ETH, wants BTC Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 36. BTC Relay – BTC Swap Ethereum 1) Bob sends  ETH  Alice s ETH account  his BTC address  agreed exchange info to escrow contract Bitcoin BTC Swap 3) Alice calls btcrelay.relayTx(TxBTC, addrBTCSwap) 2) Alice sends BTC to Bob’s address (TxBTC) 4) BTC Relay verifies TxBTC was performed in Bitcoin 5) BTC Relay invokes processTransaction() in BTC Swap 6) BTC Swap releases payment to Alice Has BTC, wants ETH Has ETH, wants BTC Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 37. Chain Relays – Pro‘s / Con‘s + “Non-interactive” • Publicly verifiable computations in Smart Contracts + Multi-purpose • More use cases than 1:1 asset exchange • Events on chain A can trigger complex processes on chain B (e.g. for bribing miners [McCory et al. ‘18]) - Relay contract must contain all headers of the connected chain • Ongoing research to reduce storage requirements / simplify proofing mechanism - Sufficient incentive for users to submit block headers necessary • At least to cover gas costs • Working fee model necessary - Currently no freshness guarantees • i.e., BTC relay may fall far behind Bitcoin Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 38. Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 39. Chain Relays - Properties • StatelessTransferred Information • CryptographicValidation • UnidirectionalDirection • NoneTTP • ProbabilisticFinality Guarantees • Contract deployed & available, Receiver online Party Availability Requirements • „Turing complete“Script Expressiveness Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 40. Meta-Layer Protocols • Introduce a second communication layer • Abstraction of blockchain-specific properties • Rely on game theoretic incentives • Interactions between different actors/roles • Utilize described mechanisms to integrate external chains • Notary schemes, chain relays, atomic swaps,…  „Bridges“ Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 41. Polkadot • One of Parity‘s flagship projects • Two chain types: • Para(llel)chains – globally-coherent dynamic data structures/blockchains • Relay chain(s) – base communication/synchronization layer • Relay Chain consensus: • Initially: permissioned, i.e., 3f+1 BFT algorithm (e.g. HoneyBadgerBFT, Tendermint, …) • Planned: Delegated Proof-of-Stake (DPoS) Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 42. Polkadot - Relay Chains and Parachains Source: Wood, Gavin. "Polkadot: Vision for a heterogeneous multi-chain framework." URL https://github.com/polkadot-io/polkadot-white-paper/raw/master/PolkaDotPaper.pdf (2016). Relay Chain Parachain n1 Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 43. Relay Chain Parachain mn Polkadot - Relay Chains and Parachains Source: Wood, Gavin. "Polkadot: Vision for a heterogeneous multi-chain framework." URL https://github.com/polkadot-io/polkadot-white-paper/raw/master/PolkaDotPaper.pdf (2016).Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 44. Polkadot - Relay Chains and Parachains Source: Wood, Gavin. "Polkadot: Vision for a heterogeneous multi-chain framework." URL https://github.com/polkadot-io/polkadot-white-paper/raw/master/PolkaDotPaper.pdf (2016). Chain Relay Chain connects to m n Parachain Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 45. Polkadot - Relay Chains and Parachains Source: Wood, Gavin. "Polkadot: Vision for a heterogeneous multi-chain framework." URL https://github.com/polkadot-io/polkadot-white-paper/raw/master/PolkaDotPaper.pdf (2016). Chain Relay Chain connects to m n Parachain Transaction Interchain On-chain contains 1n triggers 11 Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 46. Polkadot - Actors • Validator 1. Validates parachain transactions/blocks 2. Agrees on interchain TX  relay chain validation • Stake slashed in case of misbehaviour • Nominator • Can provide stake for validator • Collator • Collects parachain TX and sends block candidates to validators • Fisherman • Monitors validators for misbehaviour / Reports to other validators • Clients/Light Clients Source: Wood, Gavin. "Polkadot: Vision for a heterogeneous multi-chain framework." URL https://github.com/polkadot-io/polkadot-white-paper/raw/master/PolkaDotPaper.pdf (2016).Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 47. Polkadot - Actors • Relay Chain: • Validator 1. Validates parachain transactions/blocks 2. Agrees on interchain TX  relay chain validation • Stake slashed in case of misbehaviour • Nominator • Can provide stake for validator • Parachain • Collator • Collects parachain TX and sends block candidates to validators • Fisherman • Monitors validators for misbehaviour / Reports to other validators • Clients/Light Clients Participant ValidatorNominator FishermanCollator Relay node Para-node stakes for nm monitors / reports failure n m provides parachain blocks n m validates/ slashes n m Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 48. Polkadot – Domain Overview (simplified) Chain Relay Chain Parachain Participant ValidatorNominator FishermanCollator Transaction Interchain Transaction Parachain Transaction triggers 11 Relay node Para-node has 1 connects to m n n 1 1 n stakes for nm monitors / reports failure n m provides parachain blocks n m Participant/Transaction relations omitted for simplicity validates/ slashes n m n FIFO Transaction Queue contains n 1 Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 49. Polkadot - Challenges • Game theoretic incentives not sufficiently studied • Modelling of incentives and potential attacks necessary • High communication complexity • Extent of necessary overhead unclear • A lot of technical details still not clearly defined • How to maintain information on asset state after cross-chain TX? • Consensus finality  what happens if parachains fork? Or relay chain forks? • Address/account scheme • Privacy features • …. Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 50. Cosmos • Cosmos Hub and Zones (child blockchains) • Each Zone can become a hub in turn • Zones run Tendermint BFT (3f + 1) • Fixed known set of validators • Cross-chain communication similar to two- way-peg • Bridges to other chains necessary (e.g. ETH) • Permissioned setup • Tested with 65 validator nodes • Initially 100, scale up to 300 within 10 years Source: Kwon, Jae, and Buchman, Ethan. „Cosmos: A Network of Distributed Ledgers“. URL https://github.com/cosmos/cosmos/blob/master/WHITEPAPER.md (2016) Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 51. Outlook • Rapidly increasing number of projects promising „Multi-blockchain protocols“ • Often limited technical details provided  unclear how exactly communication will be facilitated. • Many rely on versions of atomic swaps or chain relays under a (semi-) centralized setup • Active development • 1:1 Bridges between Ethereum and other networks in development • Lightning cross-chain swaps between BTC and LTC • Overlay protocols / Colored Coins • … • No “truly decentralized” solution yet  Alarming shift towards centralized approaches Towards a Generalised Blockchain Fabric - Code Block 18 - Alexei Zamyatin
  • 52. Questions? Alexei Zamyatin a.zamyatin@imperial.ac.uk PGP ID: 0x5485B999 PGP FP: 2F5F E92D CDAC 15B0 84A6 9FE9 9018 A958 5485 B999 @alexeiZamyatin