Top Banner
Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and Vassilis Zikas, Fair and Robust Multi-Party Computation using a Global Transaction Ledger, EUROCRYPT 2016.
176

Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

May 13, 2020

Download

Documents

dariahiddleston
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

Cryptographyon the Blockchain

IACR Summer School on Blockchain Techs

Vassilis ZikasRPI

Aggelos Kiayias, Hong-Shen Zhou, and Vassilis Zikas, Fair and Robust Multi-Party Computation using a Global Transaction Ledger, EUROCRYPT 2016.

Page 2: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

Bitcoin

Page 3: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

What is bitcoin and how does it work?

Bitcoin

Page 4: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

What is bitcoin and how does it work?

Is it secure?

(in restricted models)

Bitcoin

Page 5: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

What is bitcoin and how does it work?

Is it secure?

(in restricted models)

What do we get from it?

Bitcoin

Page 6: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

What is bitcoin and how does it work?

Is it secure?

(in restricted models)

What do we get from it?

Bitcoin

Page 7: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

What Crypto can get from Bitcoin?

Page 8: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

What Crypto can get from Bitcoin?

In this talk“Bitcoin = Ledger-based cryptocurrency”

Page 9: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

What Crypto can get from Bitcoin?

In this talk“Bitcoin = Ledger-based cryptocurrency”

A public transaction ledger

Some economic stuff …

Page 10: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

What Crypto can get from Bitcoin?

A bulletin board with a filter on what gets

written there

In this talk“Bitcoin = Ledger-based cryptocurrency”

A public transaction ledger

Some economic stuff …

Page 11: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

What Crypto can get from Bitcoin?

People (good or bad) want money

A bulletin board with a filter on what gets

written there

In this talk“Bitcoin = Ledger-based cryptocurrency”

A public transaction ledger

Some economic stuff …

Page 12: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

The Public Transaction Ledger“What is exactly the problem that bitcoin solves?” AK, 2016

Page 13: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

The Public Transaction Ledger

The core security goal of Bitcoin is to ensure that all parties establish a common and irreversible view

of the sequence of transactions

“What is exactly the problem that bitcoin solves?” AK, 2016

Page 14: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

“Backbone” [GarayKiayiasLeonardos15]

The Public Transaction Ledger

The core security goal of Bitcoin is to ensure that all parties establish a common and irreversible view

of the sequence of transactions

“What is exactly the problem that bitcoin solves?” AK, 2016

Page 15: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

“Backbone” [GarayKiayiasLeonardos15]

The Public Transaction Ledger

The core security goal of Bitcoin is to ensure that all parties establish a common and irreversible view

of the sequence of transactions

This goal can be captured as an ideal Transaction-Ledger Functionality

“What is exactly the problem that bitcoin solves?” AK, 2016

Page 16: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

“Backbone” [GarayKiayiasLeonardos15]

The Public Transaction Ledger

The core security goal of Bitcoin is to ensure that all parties establish a common and irreversible view

of the sequence of transactions

This goal can be captured as an ideal Transaction-Ledger Functionality

“If we had a trusted third party instead of the Bitcoin network, how would we expect it to behave?”

“What is exactly the problem that bitcoin solves?” AK, 2016

Page 17: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

Crypto On Blockchain

Outline

• The functionality offered by blockchains

• Leveraging Security Loss with Coins … in Secure Function Evaluation (SFE)

• A formal cryptographic (UC) model for security proofs

Page 18: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

Crypto On Blockchain

Outline

• The functionality offered by blockchains

• Leveraging Security Loss with Coins … in Secure Function Evaluation (SFE)

• A formal cryptographic (UC) model for security proofs

Page 19: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

The Public Transaction Ledger

StateSt

Gledger

Page 20: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

The Public Transaction Ledger

GetState

“State”

StateSt

Gledger

Page 21: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

The Public Transaction Ledger

GetState

“State”

StateSt

(Submit, x)

Gledger

Page 22: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

The Public Transaction Ledger

GetState

“State”

StateSt||x

(Submit, x)

Gledger

Page 23: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

The Public Transaction Ledger

GetState

“State”

StateSt||x

(Submit, x)

Gledger

• In reality: Not a Bulletin Board• Inputs (transactions) are filtered

Page 24: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

The Public Transaction Ledger

GetState

“State”

StateSt

(Submit, x)

Gledger

• In reality: Not a Bulletin Board• Inputs (transactions) are filtered

Page 25: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

The Public Transaction Ledger

GetState

“State”

StateSt

(Submit, x)Validate(.)

x

Gledger

• In reality: Not a Bulletin Board• Inputs (transactions) are filtered

Page 26: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

The Public Transaction Ledger

GetState

“State”

StateSt

(Submit, x)“State”Validate(.)

x

Gledger

• In reality: Not a Bulletin Board• Inputs (transactions) are filtered

Page 27: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

The Public Transaction Ledger

GetState

“State”

StateSt

(Submit, x)“State”Validate(.)

x

NoYes

Gledger

• In reality: Not a Bulletin Board• Inputs (transactions) are filtered

Page 28: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

The Public Transaction Ledger

GetState

“State”

StateSt

(Submit, x)“State”Validate(.)

x

NoYesx

Gledger

• In reality: Not a Bulletin Board• Inputs (transactions) are filtered

Page 29: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

The Public Transaction Ledger

Validate(.)

GetState

“State”

StateSt||x

(Submit, x)“State” x

NoYesx

Gledger

• In reality: Not a Bulletin Board• Inputs (transactions) are filtered

Page 30: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

The Public Transaction Ledger

Validate(.)

GetState

“State”

StateSt||x

(Submit, x)“State” x

NoYesx

Gledger

• In reality: Not a Bulletin Board• Inputs (transactions) are filtered• The order in which transactions in

“State” are inserted might be adversarial … but not too adversarial

Page 31: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

The Public Transaction Ledger

Validate(.)

GetState

“State”

StateSt||x

(Submit, x)“State” x

NoYesx

Gledger

Can reorder the recently inserted transactions

Page 32: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

The Public Transaction Ledger

Validate(.)

GetState

“State”

StateSt||x

(Submit, x)“State” x

NoYesx

Gledger

Can reorder the recently inserted transactions

Page 33: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

The Public Transaction Ledger & Time

Gledger

Validate(.)

GetState

“State”

State

NoYes

Buffer

Can reorder the recently inserted transactions

Page 34: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

The Public Transaction Ledger & Time

Gledger

Validate(.)

GetState

“State”

State(Submit, x)x

NoYes

Buffer

Can reorder the recently inserted transactions

Page 35: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

The Public Transaction Ledger & Time

Gledger

Validate(.)

GetState

“State”

State(Submit, x)x

NoYes

Buffer“State”

Can reorder the recently inserted transactions

Page 36: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

The Public Transaction Ledger & Time

Gledger

Validate(.)

GetState

“State”

State(Submit, x)x

NoYesx

Buffer“State”

Can reorder the recently inserted transactions

Page 37: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

The Public Transaction Ledger & Time

Gledger

Validate(.)

GetState

“State”

State(Submit, x)x

NoYesx

Buffer“State”

Can reorder the recently inserted transactions

x

Page 38: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

The Public Transaction Ledger & Time

Gledger

Validate(.)

GetState

“State”

State(Submit, x)x

NoYesx

Bufferx1,x2,…

“State”

Can reorder the recently inserted transactions

x

Page 39: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

The Public Transaction Ledger & Time

Gledger

Validate(.)

GetState

“State”

State(Submit, x)x

NoYesx

Bufferx1,x2,… = π(x1,…)

“State”

(Permute,π)

Can reorder the recently inserted transactions

x

Page 40: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

The Public Transaction Ledger & Time

Gledger

Validate(.)

GetState

“State”

State(Submit, x)“State” x

NoYesx

Buffer

(Permute,π)

time?

x1,x2,… = π(x1,…)

Can reorder the recently inserted transactions

x

Page 41: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

The Public Transaction Ledger & Time

Gledger

Validate(.)

GetState

“State”

State(Submit, x)“State” x

NoYesx

Buffer

(Permute,π)

time?

t

x1,x2,… = π(x1,…)

Can reorder the recently inserted transactions

x

Page 42: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

The Public Transaction Ledger & Time

Gledger

Validate(.)

GetState

“State”

State(Submit, x)“State” x

NoYesx

Bufferx1,x2,… = π(x1,…)

(Permute,π)

time?

t

Blockify(.) ?

Can reorder the recently inserted transactions

x

Page 43: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

The Public Transaction Ledger & Time

Gledger

Validate(.)

GetState

“State”

State(Submit, x)“State” x

NoYesx

Bufferx1,x2,… = π(x1,…)

(Permute,π)

xtime?

t

Blockify(.) ?

Can reorder the recently inserted transactions

x

Page 44: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

The Public Transaction Ledger & Time

Gledger

Validate(.)

GetState

“State”

State(Submit, x)“State” x

NoYesx

Buffer

(Permute,π)

xtime?

t

Blockify(.) ?

Can reorder the recently inserted transactions

x

Page 45: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

The Public Transaction Ledger & Time

Gledger

Validate(.)

GetState

“State”

State(Submit, x)“State” x

NoYesx

Buffer

(Permute,π)

x (B, t)time?

t

Blockify(.) ?

Can reorder the recently inserted transactions

x

Page 46: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

What Crypto can we get from Bitcoin?

A public transaction ledger

Some economic stuff …

People (good or bad) want money

A bulletin board with a filter on what gets

written there The Model

(Gledger, Gclock)-hybrid (G)UC protocols

Page 47: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

What Crypto can we get from Bitcoin?

A public transaction ledger

Some economic stuff …

People (good or bad) want money

A bulletin board with a filter on what gets

written there The Model

(Gledger, Gclock)-hybrid (G)UC protocols

• Compatibility with standard crypto-protocols (+ composition theorem)

Page 48: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

What Crypto can we get from Bitcoin?

A public transaction ledger

Some economic stuff …

People (good or bad) want money

A bulletin board with a filter on what gets

written there The Model

(Gledger, Gclock)-hybrid (G)UC protocols

• Compatibility with standard crypto-protocols (+ composition theorem)

• Cryptographically as useful as having access to (synchronous) stateful broadcast

Page 49: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

What Crypto can we get from Bitcoin?

A public transaction ledger

Some economic stuff …

People (good or bad) want money

A bulletin board with a filter on what gets

written there The Model

(Gledger, Gclock)-hybrid (G)UC protocols

• Compatibility with standard crypto-protocols (+ composition theorem)

• Cryptographically as useful as having access to (synchronous) stateful broadcast

“This cryptography has been around for a long time” JB 2016

Page 50: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

What Crypto can we get from Bitcoin?

A public transaction ledger

Some economic stuff …

People (good or bad) want money

A bulletin board with a filter on what gets

written there The Model

(Gledger, Gclock)-hybrid (G)UC protocols

• Compatibility with standard crypto-protocols (+ composition theorem)

• Cryptographically as useful as having access to (synchronous) stateful broadcast

“This cryptography has been around for a long time” JB 2016

Page 51: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

Crypto On Blockchain

Outline

• The functionality offered by blockchains

• Leveraging Security Loss with Coins … in Secure Function Evaluation (SFE)

• A formal cryptographic (UC) model for security proofs

Page 52: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

Crypto On Blockchain

Outline

• The functionality offered by blockchains

• Leveraging Security Loss with Coins … in Secure Function Evaluation (SFE)

• A formal cryptographic (UC) model for security proofs

Page 53: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

Secure Function Evaluation (SFE)

Goal: Parties P1,…,Pn with inputs x1,…,xn wish to compute a function f(x1,…,xn) securely

Page 54: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

Secure Function Evaluation (SFE)

F f

P1 P2 Pn

x1 x2 xnf(x)̅

f(x)̅ f(x)̅=y…

Ideal World

Page 55: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

Secure Function Evaluation (SFE)

F f

P1 P2 Pn

x1 x2 xnf(x)̅

f(x)̅ f(x)̅=y…

Ideal World

P1 P2 Pn…

Real World

Page 56: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

Secure Function Evaluation (SFE)

F f

P1 P2 Pn

x1 x2 xnf(x)̅

f(x)̅ f(x)̅=y…

Ideal World

P1 P2 Pn…

Real World≈

π1(x1) π2(x2) πn(xn)

Page 57: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

Secure Function Evaluation (SFE)

F f

P1 P2 Pn

x1 x2 xnf(x)̅

f(x)̅ f(x)̅=y…

Ideal World

P1 P2 Pn…

Real World≈

π1(x1) π2(x2) πn(xn)

Page 58: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

Secure Function Evaluation (SFE)

F f

P1 P2 Pn

x1 x2 xnf(x)̅

f(x)̅ f(x)̅=y…

Ideal World

P1 P2 Pn…

Real World≈

π1(x1) π2(x2) πn(xn)

???

Page 59: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

Secure Function Evaluation (SFE)

F f

P1 P2 Pn

x1 x2 xnf(x)̅

f(x)̅ f(x)̅=y…

Ideal World

P1 P2 Pn…

Real World≈

π1(x1) π2(x2) πn(xn)

???Protocol π is secure if for every adversary: • (privacy) Whatever the adversary learns he could compute by himself• (correctness) Honest (uncorrupted) parties learn their correct outputs

Page 60: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

Fair SFE

In fair SFE: If the adversary learns any information beyond (what is derived by) its inputs then every honest party should learn the output

Page 61: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

Fair SFE

In fair SFE: If the adversary learns any information beyond (what is derived by) its inputs then every honest party should learn the output

F f

P1 P2 Pn

y⊥⊥

Page 62: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

Fair SFE

In fair SFE: If the adversary learns any information beyond (what is derived by) its inputs then every honest party should learn the output

F f

P1 P2 Pn

y⊥⊥ ✘ (Unfair)

Page 63: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

Fair SFE

In fair SFE: If the adversary learns any information beyond (what is derived by) its inputs then every honest party should learn the output

F f

P1 P2 Pn

y⊥⊥

Fair SFE is impossible against corrupted majorities [Cleve86]

✘ (Unfair)

Page 64: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

Fair SFE

In fair SFE: If the adversary learns any information beyond (what is derived by) its inputs then every honest party should learn the output

F f

P1 P2 Pn

y⊥⊥

Fair SFE is impossible against corrupted majorities [Cleve86]

Security against corrupted majorities

Security with abort =

✘ (Unfair)

Page 65: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

Fair SFE

In fair SFE: If the adversary learns any information beyond (what is derived by) its inputs then every honest party should learn the output

F f

P1 P2 Pn

y⊥⊥

Fair SFE is impossible against corrupted majorities [Cleve86]

Security against corrupted majorities

Security with abort =

✘ (Unfair)

Discounted security

Page 66: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Fair(ness) Compensation

SFE with fair compensation: If the adversary learns any information beyond (what is derived by) its inputs then every honest party should learn the output or get compensated.

Idea [AndrychowiczDziembowskiMalinowskiMazurek14]: We can leverage unfairness with $$$

Page 67: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Fair(ness) Compensation

SFE with fair compensation: If the adversary learns any information beyond (what is derived by) its inputs then every honest party should learn the output or get compensated.

F f

P1 P2 Pn

y⊥⊥

!"" ✘ (Unfair)

Idea [AndrychowiczDziembowskiMalinowskiMazurek14]: We can leverage unfairness with $$$

Page 68: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Fair(ness) Compensation

SFE with fair compensation: If the adversary learns any information beyond (what is derived by) its inputs then every honest party should learn the output or get compensated.

+ -+

! ! #

F f

P1 P2 Pn

y⊥⊥

!"" ✘ (Unfair)

Idea [AndrychowiczDziembowskiMalinowskiMazurek14]: We can leverage unfairness with $$$

Page 69: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Fair(ness) Compensation

SFE with fair compensation: If the adversary learns any information beyond (what is derived by) its inputs then every honest party should learn the output or get compensated.

+ -+

! ! # ✔ (“fair”)

F f

P1 P2 Pn

y⊥⊥

!"" ✘ (Unfair)

Idea [AndrychowiczDziembowskiMalinowskiMazurek14]: We can leverage unfairness with $$$

Page 70: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Fair(ness) Comp.: Construction [BentovKumaresan14,15]

Tools 1/2 : Authenticated Additive Secret Sharing

PnP1

x=x1⊕ … ⊕ xn , (sk,vk)←KeyGen

[x]1 = x1,Sigsk(x1),vk [x]n = xn,Sigsk(xn),vk

Page 71: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Fair(ness) Comp.: Construction [BentovKumaresan14,15]

Tools 1/2 : Authenticated Additive Secret Sharing

PnP1

x=x1⊕ … ⊕ xn , (sk,vk)←KeyGen

[x]1 = x1,Sigsk(x1),vk [x]n = xn,Sigsk(xn),vk

• No n-1 parties have info on x • Together all n parties can recover x• No party can lie about its share

• Only x might be reconstructed!

Page 72: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Fair(ness) Comp.: Construction [BentovKumaresan14,15]

Tools 2/2 : Claim and Refund TransactionsS transfers q coins to R such that

Page 73: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Fair(ness) Comp.: Construction [BentovKumaresan14,15]

Tools 2/2 : Claim and Refund TransactionsS transfers q coins to R such that

• Time restriction τ

Page 74: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Fair(ness) Comp.: Construction [BentovKumaresan14,15]

Tools 2/2 : Claim and Refund TransactionsS transfers q coins to R such that

time• Time restriction τ

Page 75: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Fair(ness) Comp.: Construction [BentovKumaresan14,15]

Tools 2/2 : Claim and Refund TransactionsS transfers q coins to R such that

time τ R can claim

coins S can claim coins

• Time restriction τ

Page 76: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Fair(ness) Comp.: Construction [BentovKumaresan14,15]

Tools 2/2 : Claim and Refund TransactionsS transfers q coins to R such that

time τ R can claim

coins S can claim coins

• A predicate (relation) R(state,buffer,tx):• In order to spend the coins the receiver needs to

submit a tx satisfying R (at the point of validation).

• Time restriction τ

Page 77: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Fair(ness) Comp.: Construction [BentovKumaresan14,15]

Tools 2/2 : Claim and Refund TransactionsS transfers q coins to R such that

time τ R can claim

coins S can claim coins

• A predicate (relation) R(state,buffer,tx):• In order to spend the coins the receiver needs to

submit a tx satisfying R (at the point of validation).

• Time restriction τ

• Supported by Bitcoin scripting language• Captured by Validate(.)

Page 78: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Fair(ness) Comp.: Construction

Protocol Idea for computing y=f(x1,…,xn)1. Run SFE with unfair abort to compute n-out-of-n

authenticated sharing [y] of y=f(x1,…,xn)• E.g., Every Pi receives share [y]i such that

y=[y]1+…+[y]n and public signature on [y]i

[BentovKumaresan14,15]

Page 79: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Fair(ness) Comp.: Construction

Protocol Idea for computing y=f(x1,…,xn)

F f

P1 P2 Pn

x1 x2 xn[f(x)̅]1

[f(x)̅]2…

[f(x)̅]n

1. Run SFE with unfair abort to compute n-out-of-n authenticated sharing [y] of y=f(x1,…,xn)• E.g., Every Pi receives share [y]i such that

y=[y]1+…+[y]n and public signature on [y]i

[BentovKumaresan14,15]

Page 80: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Fair(ness) Comp.: Construction

Protocol Idea for computing y=f(x1,…,xn)

F f

P1 P2 Pn

x1 x2 xn[f(x)̅]1

[f(x)̅]2…

[f(x)̅]n

Abort at this point is fair

1. Run SFE with unfair abort to compute n-out-of-n authenticated sharing [y] of y=f(x1,…,xn)• E.g., Every Pi receives share [y]i such that

y=[y]1+…+[y]n and public signature on [y]i

[BentovKumaresan14,15]

Page 81: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Fair(ness) Comp.: Construction

2. Use the following reconstruction idea:

2.1. Every Pi transfers 1 bitcoin to every Pj with the restriction: • Pj can claim (spend) this coin in round ρij if it submits to

the ledger his valid share (and signature) by round ρij • if Pj has not claimed this coin by the end of round ρij,

then the coin is “refunded” to Pi (i.e., after round ρij, Pi can spend this coin himself).

Protocol Idea for computing y=f(x1,…,xn) [BentovKumaresan14,15]

Page 82: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Fair(ness) Comp.: Construction

2. Use the following reconstruction idea:

2.1. Every Pi transfers 1 bitcoin to every Pj with the restriction: • Pj can claim (spend) this coin in round ρij if it submits to

the ledger his valid share (and signature) by round ρij • if Pj has not claimed this coin by the end of round ρij,

then the coin is “refunded” to Pi (i.e., after round ρij, Pi can spend this coin himself).

2.2. Proceed in rounds in which the parties claim the coins from other parties by announcing their shares (and signatures)

Protocol Idea for computing y=f(x1,…,xn) [BentovKumaresan14,15]

Page 83: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Fair(ness) Comp.: Construction

Security (SFE with fair compensation): Follow the money …

• If the adversary announces all his shares then every party:• Sends n coins in phase two (one to each party)• Claims back n coins in phase three (one from each party)

• If a corrupted party Pj does not announce his share then every party • Sends n coins in phase two (one to each party)• Claims back

• n coins in phase three for announcing his shares• the coin that it had sent to Pj

Protocol Idea for computing y=f(x1,…,xn) [BentovKumaresan14,15]

Page 84: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

[BentovKumaresan14,15]Rethinking SFE w Fair(ness) Compensation

Time

Page 85: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

[BentovKumaresan14,15]Rethinking SFE w Fair(ness) Compensation

TimeProtocol Starts

Page 86: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

[BentovKumaresan14,15]Rethinking SFE w Fair(ness) Compensation

TimeProtocol StartsSharing is Output, Committed transactionsSeconds

Page 87: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

[BentovKumaresan14,15]Rethinking SFE w Fair(ness) Compensation

TimeProtocol StartsSharing is Output, Committed transactionsSeconds

1 hour Start reclaiming transactions

Page 88: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

[BentovKumaresan14,15]Rethinking SFE w Fair(ness) Compensation

TimeProtocol StartsSharing is Output, Committed transactionsSeconds

1 hour Start reclaiming transactions

output or compensation is settled several hours

Page 89: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

[BentovKumaresan14,15]Rethinking SFE w Fair(ness) Compensation

TimeProtocol StartsSharing is Output, Committed transactionsSeconds

1 hour Start reclaiming transactions

“several” = • [BentovKumaresan14] linear in players (n) • [BentovKumaresan15] constant

output or compensation is settled several hours

Page 90: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

[BentovKumaresan14,15]Rethinking SFE w Fair(ness) Compensation

TimeProtocol StartsSharing is Output, Committed transactionsSeconds

1 hour Start reclaiming transactions

“several” = • [BentovKumaresan14] linear in players (n) • [BentovKumaresan15] constant

What if the adversary aborts before making the committed transactions?

output or compensation is settled several hours

Page 91: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

[BentovKumaresan14,15]Rethinking SFE w Fair(ness) Compensation

TimeProtocol StartsSharing is Output, Committed transactionsSeconds

1 hour Start reclaiming transactions

“several” = • [BentovKumaresan14] linear in players (n) • [BentovKumaresan15] constant

What if the adversary aborts before making the committed transactions?

This can be confirmed here …

output or compensation is settled several hours

Page 92: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

[BentovKumaresan14,15]Rethinking SFE w Fair(ness) Compensation

TimeProtocol StartsSharing is Output, Committed transactionsSeconds

1 hour Start reclaiming transactions

“several” = • [BentovKumaresan14] linear in players (n) • [BentovKumaresan15] constant

What if the adversary aborts before making the committed transactions?

This can be confirmed here …

… and reclaimed here …

output or compensation is settled several hours

Page 93: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

[BentovKumaresan14,15]Rethinking SFE w Fair(ness) Compensation

TimeProtocol StartsSharing is Output, Committed transactionsSeconds

1 hour Start reclaiming transactions

“several” = • [BentovKumaresan14] linear in players (n) • [BentovKumaresan15] constant

What if the adversary aborts before making the committed transactions?

This can be confirmed here …

… and reclaimed here …

output or compensation is settled several hours

Page 94: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

[BentovKumaresan14,15]Rethinking SFE w Fair(ness) Compensation

TimeProtocol StartsSharing is Output, Committed transactionsSeconds

1 hour Start reclaiming transactions

“several” = • [BentovKumaresan14] linear in players (n) • [BentovKumaresan15] constant

What if the adversary aborts before making the committed transactions?

This can be confirmed here …

… and reclaimed here …

O(n)times

=O(n)hours

till output

output or compensation is settled several hours

Page 95: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

Rethinking SFE w Fair(ness) Compensation

SFE with fair compensation: If the adversary learns any information beyond (what is derived by) its inputs then every honest party should learn the output or get compensated.

P1 P2 Pn

y⊥⊥

!""+ -+

! ! #

✘ (Unfair)

✔ (“fair”)

F f

Page 96: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

Rethinking SFE w Fair(ness) Compensation

SFE with fair compensation: If the adversary learns any information beyond (what is derived by) its inputs then every honest party should learn the output or get compensated.

P1 P2 Pn

y⊥⊥

!""+ -+

! ! #+ +

$ $

✘ (Unfair)

✔ (“fair”)

F f

Page 97: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

Rethinking SFE w Fair(ness) Compensation

SFE with fair compensation: If the adversary learns any information beyond (what is derived by) its inputs then every honest party should learn the output or get compensated.

P1 P2 Pn

y⊥⊥

!""+ -+

! ! #+ +

$ $

DoS

%

+

✘ (Unfair)

✔ (“fair”)

F f

Page 98: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

Rethinking SFE w Fair(ness) Compensation

SFE with fair compensation: If the adversary learns any information beyond (what is derived by) its inputs then every honest party should learn the output or get compensated.

P1 P2 Pn

y⊥⊥

!""+ -+

! ! #+ +

$ $ ✘

DoS

%

+

✘ (Unfair)

✔ (“fair”)

F f

Page 99: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust(ness) Compensation

Page 100: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust(ness) Compensation

Fair SFE: If the adversary learns any information beyond (what is derived by) its inputs then every honest party should learn the output

Page 101: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust(ness) Compensation

Fair SFE: If the adversary learns any information beyond (what is derived by) its inputs then every honest party should learn the output

SFE with fair compensation: If the adversary learns any information beyond (what is derived by) its inputs then every honest party should learn the output or get compensated

Page 102: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust(ness) Compensation

Fair SFE: If the adversary learns any information beyond (what is derived by) its inputs then every honest party should learn the output

SFE with fair compensation: If the adversary learns any information beyond (what is derived by) its inputs then every honest party should learn the output or get compensated

robust

(fast …)

Page 103: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust(ness) Compensation

Fair SFE: If the adversary learns any information beyond (what is derived by) its inputs then every honest party should learn the output

SFE with fair compensation: If the adversary learns any information beyond (what is derived by) its inputs then every honest party should learn the output or get compensated

robust

How can we get robustness?

(fast …)

Page 104: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : Construction

S transfers q coins to R such thatTools 1/3 : Special Transaction

Page 105: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : Construction

S transfers q coins to R such that• Time restriction (τ-, τ+)

Tools 1/3 : Special Transaction

Page 106: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : Construction

S transfers q coins to R such that

time• Time restriction (τ-, τ+)

Tools 1/3 : Special Transaction

Page 107: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : Construction

S transfers q coins to R such that

time τ- τ+

coins are blocked

R can claim coins

S can claim coins

• Time restriction (τ-, τ+)

Tools 1/3 : Special Transaction

Page 108: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : Construction

S transfers q coins to R such that

time τ- τ+

coins are blocked

R can claim coins

S can claim coins

• Link: A reference ref such that only a transaction with the same reference can spend the q coins

• Time restriction (τ-, τ+)

Tools 1/3 : Special Transaction

Page 109: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : Construction

S transfers q coins to R such that

time τ- τ+

coins are blocked

R can claim coins

S can claim coins

• Link: A reference ref such that only a transaction with the same reference can spend the q coins

• A predicate (relation) R(state,buffer,tx):• In order to spend the coins the receiver needs to

submit a tx satisfying R (at the point of validation).

• Time restriction (τ-, τ+)

Tools 1/3 : Special Transaction

Page 110: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : Construction

S transfers q coins to R such that

time τ- τ+

coins are blocked

R can claim coins

S can claim coins

• Link: A reference ref such that only a transaction with the same reference can spend the q coins

• A predicate (relation) R(state,buffer,tx):• In order to spend the coins the receiver needs to

submit a tx satisfying R (at the point of validation).

• Time restriction (τ-, τ+)

Tools 1/3 : Special Transaction

Page 111: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : Construction

S transfers q coins to R such that

time τ- τ+

coins are blocked

R can claim coins

S can claim coins

• Link: A reference ref such that only a transaction with the same reference can spend the q coins

• A predicate (relation) R(state,buffer,tx):• In order to spend the coins the receiver needs to

submit a tx satisfying R (at the point of validation).(τ-,τ+), ref, R

• Time restriction (τ-, τ+)

Tools 1/3 : Special Transaction

Page 112: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : ConstructionTools 2/3 : Semi-honest SFEAn SFE protocol which is secure when parties follow their instructions

Page 113: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : ConstructionTools 2/3 : Semi-honest SFEAn SFE protocol which is secure when parties follow their instructions

Example: A Summation protocol

Sum Protocol II

· · ·

x1

x11

x12

· · · x1n

x2

x21

x22

· · · x2n

............

xn xn1 xn2 · · · xnn

y1

y2

· · · yn y =

nX

i=1

yi

P1 P2 Pn

P1

P2

Pn

Page 114: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : ConstructionTools 2/3 : Semi-honest SFEAn SFE protocol which is secure when parties follow their instructions

Example: A Summation protocol

Sum Protocol II

· · ·

x1

x11

x12

· · · x1n

x2

x21

x22

· · · x2n

............

xn xn1 xn2 · · · xnn

y1

y2

· · · yn y =

nX

i=1

yi

P1 P2 Pn

P1

P2

Pn

x1 =nM

j=1

x1j

Page 115: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : ConstructionTools 2/3 : Semi-honest SFEAn SFE protocol which is secure when parties follow their instructions

Example: A Summation protocol

Sum Protocol II

· · ·

x1

x11

x12

· · · x1n

x2

x21

x22

· · · x2n

............

xn xn1 xn2 · · · xnn

y1

y2

· · · yn y =

nX

i=1

yi

P1 P2 Pn

P1

P2

Pn

x1 =nM

j=1

x1j

x2 =nM

j=1

x2j

xn =nM

j=1

xnj

Page 116: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : ConstructionTools 2/3 : Semi-honest SFEAn SFE protocol which is secure when parties follow their instructions

Example: A Summation protocol

Sum Protocol II

· · ·

x1

x11

x12

· · · x1n

x2

x21

x22

· · · x2n

............

xn xn1 xn2 · · · xnn

y1

y2

· · · yn y =

nX

i=1

yi

P1 P2 Pn

P1

P2

Pn

x1 =nM

j=1

x1j

x2 =nM

j=1

x2j

xn =nM

j=1

xnj

y =nM

i=1

yi

Page 117: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : ConstructionTools 2/3 : Semi-honest SFEAn SFE protocol which is secure when parties follow their instructions

Example: A Summation protocol

Secure (private) against arbitrary many colluding parties

Sum Protocol II

· · ·

x1

x11

x12

· · · x1n

x2

x21

x22

· · · x2n

............

xn xn1 xn2 · · · xnn

y1

y2

· · · yn y =

nX

i=1

yi

P1 P2 Pn

P1

P2

Pn

x1 =nM

j=1

x1j

x2 =nM

j=1

x2j

xn =nM

j=1

xnj

y =nM

i=1

yi

Page 118: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : ConstructionTools 2/3 : Semi-honest SFEAn SFE protocol which is secure when parties follow their instructions

Assuming a public key infrastructure (commitments/encryption/signatures) there exists a semi-honest SFE protocol π for every function which

• Uses only public communication• Tolerates arbitrary many semi-honest parties• Terminates in constant rounds

Page 119: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

Compile a semi-honest SFE protocol π into (malicious) secure

SFE with Robust Compen. : ConstructionTools 3/3 : The GMW Compiler

Page 120: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

Compile a semi-honest SFE protocol π into (malicious) secure

SFE with Robust Compen. : Construction

Round 0: Setup generation (+ commitments to randomness)

Round 1: Every Pi commits to its input

Rounds 2 … ρπ + 1: Execute π round-by-round so that in each round every party proves (in ZK) that he follows π

Tools 3/3 : The GMW Compiler

Page 121: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

Compile a semi-honest SFE protocol π into (malicious) secure

SFE with Robust Compen. : Construction

Round 0: Setup generation (+ commitments to randomness)

Round 1: Every Pi commits to its input

Rounds 2 … ρπ + 1: Execute π round-by-round so that in each round every party proves (in ZK) that he follows π

Security (with abort)

• Privacy: The parties see the following: - Setup- Commitments- Messages from π

• Correctness:- If ZKPs succeed then

the parties are indeed following π

- Else abort

Tools 3/3 : The GMW Compiler

Page 122: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : ConstructionIdea: Use “GMW”-like compiler on the Ledger

Page 123: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : ConstructionIdea: Use “GMW”-like compiler on the Ledger

Round 0: Setup generation (+ commitments to randomness)

Round 1: Every Pi commits to its input

Rounds 2 … ρπ + 1: Execute π round-by-round so that in each round every party proves (in ZK) that he follows π

GMW

Page 124: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : ConstructionIdea: Use “GMW”-like compiler on the Ledger

Round 0: Setup generation (+ commitments to randomness)

Round 1: Every Pi commits to its input

Rounds 2 … ρπ + 1: Execute π round-by-round so that in each round every party proves (in ZK) that he follows π

GMWRound 0: Setup generation (+ commitments to randomness)

Round 1: Do nothing

Round 2: Every Pi commits to its input and broadcasts his view of the public setup.

Rounds 3 … ρπ + 2: Execute π round-by-round so that in each round every party proves (in NIZK) that he follows π

GMW’:

Page 125: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : ConstructionIdea: Use “GMW”-like compiler on the Ledger

Round 0: Setup generation (+ commitments to randomness)

Round 1: Do nothing

Round 2: Every Pi commits to its input and broadcasts his view of the public setup.

Rounds 3 … ρπ + 2: Execute π round-by-round so that in each round every party proves (in NIZK) that the follows π

GMW’:

Page 126: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : ConstructionIdea: Use “GMW”-like compiler on the Ledger

Round 0: Setup generation (+ commitments to randomness)

Round 1: Do nothing

Round 2: Every Pi commits to its input and broadcasts his view of the public setup.

Rounds 3 … ρπ + 2: Execute π round-by-round so that in each round every party proves (in NIZK) that the follows π

GMW’: SFE with Robust Compensation

Page 127: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : ConstructionIdea: Use “GMW”-like compiler on the Ledger

Round 0: Setup generation (+ commitments to randomness)

Round 1: Do nothing

Round 2: Every Pi commits to its input and broadcasts his view of the public setup.

Rounds 3 … ρπ + 2: Execute π round-by-round so that in each round every party proves (in NIZK) that the follows π

GMW’: SFE with Robust Compensation

Page 128: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : ConstructionIdea: Use “GMW”-like compiler on the Ledger

Round 0: Setup generation (+ commitments to randomness)

Round 1: Do nothing

Round 2: Every Pi commits to its input and broadcasts his view of the public setup.

Rounds 3 … ρπ + 2: Execute π round-by-round so that in each round every party proves (in NIZK) that the follows π

Round 0: Setup generation (+ commitments to randomness)

GMW’: SFE with Robust Compensation

Page 129: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : ConstructionIdea: Use “GMW”-like compiler on the Ledger

Round 0: Setup generation (+ commitments to randomness)

Round 1: Do nothing

Round 2: Every Pi commits to its input and broadcasts his view of the public setup.

Rounds 3 … ρπ + 2: Execute π round-by-round so that in each round every party proves (in NIZK) that the follows π

Round 0: Setup generation (+ commitments to randomness)

Round 1: Every party Pi makes n·ρπ + 1 special 1-coin transactions B(i,j,r):

• Pj can spend coin in round r• ref needs to have the protocol ID• R is true if the transaction which

spends the coin includes a valid r-round message for Pj

GMW’: SFE with Robust Compensation

Page 130: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : ConstructionIdea: Use “GMW”-like compiler on the Ledger

Round 0: Setup generation (+ commitments to randomness)

Round 1: Do nothing

Round 2: Every Pi commits to its input and broadcasts his view of the public setup.

Rounds 3 … ρπ + 2: Execute π round-by-round so that in each round every party proves (in NIZK) that the follows π

Round 0: Setup generation (+ commitments to randomness)

Round 1: Every party Pi makes n·ρπ + 1 special 1-coin transactions B(i,j,r):

• Pj can spend coin in round r• ref needs to have the protocol ID• R is true if the transaction which

spends the coin includes a valid r-round message for Pj

Rounds 3 … ρπ + 2: Execute GMW(π) round-by-round so that in each round r every party spends all its round r referenced coins by a transaction which includes the round r message in GMW(π).

GMW’: SFE with Robust Compensation

Page 131: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : ConstructionIdea: Use “GMW”-like compiler on the Ledger

Round 0: Setup generation (+ commitments to randomness)

Round 1: Do nothing

Round 2: Every Pi commits to its input and broadcasts his view of the public setup.

Rounds 3 … ρπ + 2: Execute π round-by-round so that in each round every party proves (in NIZK) that the follows π

Round 0: Setup generation (+ commitments to randomness)

Validate(.) executes the code of an extra party without inputs in GMW and rejects if abort.

Round 1: Every party Pi makes n·ρπ + 1 special 1-coin transactions B(i,j,r):

• Pj can spend coin in round r• ref needs to have the protocol ID• R is true if the transaction which

spends the coin includes a valid r-round message for Pj

Rounds 3 … ρπ + 2: Execute GMW(π) round-by-round so that in each round r every party spends all its round r referenced coins by a transaction which includes the round r message in GMW(π).

GMW’: SFE with Robust Compensation

Page 132: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : ConstructionSecurity with Robust Compensation. • Case 1: The adversary correctly makes all the

“committing” transactions in Round 1• If no party cheats then every party claims from

each of the other parties as many coins as he deposited by simply executing his protocol.

• If some party Pj cheats, then every party still claims all his coins as above + all the committed coins that Pj cannot spend as he did not execute his protocol.

Page 133: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : ConstructionSecurity with Robust Compensation. • Case 2: Some corrupted party does not make

(consistent) transactions in Round 1• e.g. aborts or commits to a different setup.

Page 134: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : ConstructionSecurity with Robust Compensation. • Case 2: Some corrupted party does not make

(consistent) transactions in Round 1• e.g. aborts or commits to a different setup.

… seems to have similar issue as before …

Page 135: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : ConstructionSecurity with Robust Compensation. • Case 2: Some corrupted party does not make

(consistent) transactions in Round 1• e.g. aborts or commits to a different setup.

… seems to have similar issue as before …

• Solution: The validation predicate can be changed as:• Separates the parties into “islands” of consistent

setups (depending on their Round-1 transactions).• For each island I⊆[n]: Compute the function among

parties in I (with all other parties’ input being 0)

Page 136: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : ConstructionIdea: Use “GMW”-like compiler on the Ledger

Round 0: Setup generation (+ commitments to randomness)

Round 1: Do nothing

Round 2: Every Pi commits to its input and broadcasts his view of the public setup.

Rounds 3 … ρπ + 2: Execute π round-by-round so that in each round every party proves (in NIZK) that the follows π

Round 0: Setup generation (+ commitments to randomness)

Round 1: Every party Pi makes n·ρπ + 1 special 1-coin transactions B(i,j,r):

• Pj can spend coin in round r• ref needs to have the protocol ID• R is true if the transaction which

spends the coin includes a valid r-round message for Pj

Rounds 2 … ρπ + 2: Execute GMW(π) round-by-round so that in each round r every party spends all its round r referenced coins by a transaction which includes the round r message in GMW(π).

GMW’: SFE with Robust Compensation

Page 137: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : ConstructionIdea: Use “GMW”-like compiler on the Ledger

Round 0: Setup generation (+ commitments to randomness)

Round 1: Do nothing

Round 2: Every Pi commits to its input and broadcasts his view of the public setup.

Rounds 3 … ρπ + 2: Execute π round-by-round so that in each round every party proves (in NIZK) that the follows π

Round 0: Setup generation (+ commitments to randomness)

Round 1: Every party Pi makes n·ρπ + 1 special 1-coin transactions B(i,j,r):

• Pj can spend coin in round r• ref needs to have the protocol ID• R is true if the transaction which

spends the coin includes a valid r-round message for Pj

Rounds 2 … ρπ + 2: Execute GMW(π) round-by-round so that in each round r every party spends all its round r referenced coins by a transaction which includes the round r message in GMW(π).

GMW’: SFE with Robust Compensation

Page 138: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : ConstructionSecurity with Robust Compensation. • Case 2: Some corrupted party does not make

(consistent) transaction in Round 1• e.g. aborts or commits to a different setup.

• All honest parties are on the same island• Corrupted parties can choose to play with the honest parties or

participate in a computation independent of honest inputs.

… seems to have similar issue as before …

• Solution: The validation predicate can be changed as:• Separates the parties into “islands” of consistent

setups (depending on their Round-1 transactions).• For each island I⊆[n]: Compute the function among

parties in I (with all other parties’ input being 0)

Page 139: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

Crypto On Blockchain

Outline

• The functionality offered by blockchains

• Leveraging Security Loss with Coins … in Secure Function Evaluation (SFE)

• A formal cryptographic (UC) model for security proofs

Page 140: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

A Formal Model: GUC

P1 P2 Pn…

Ideal World F f

P1 P2 Pn…

Real World

π1(x1) π2(x2) πn(xn)

Page 141: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

A Formal Model: GUC

P1 P2 Pn…

Ideal World F f

P1 P2 Pn…

Real World

π1(x1) π2(x2) πn(xn)

GLedger

GLedger

Page 142: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

A Formal Model: GUC

P1 P2 Pn…

Ideal World F f

P1 P2 Pn…

Real World

π1(x1) π2(x2) πn(xn)

GLedger

GLedger

???

Page 143: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

A Formal Model: GUC

P1 P2 Pn…

Ideal World F f

P1 P2 Pn…

Real World

π1(x1) π2(x2) πn(xn)

GLedger

GLedger

??? Should capture all properties we

want from π

Page 144: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

W(F f)

A Formal Model: GUC

P1 P2 Pn…

Ideal World F f

P1 P2 Pn…

Real World

π1(x1) π2(x2) πn(xn)

GLedger

GLedger

??? Should capture all properties we

want from π

Page 145: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

Benefits of this Modeling

Page 146: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

Benefits of this Modeling

• A single abstraction of the functionality offered by cryptocurrencies - Advanced transactions correspond to an advanced

validation predicate

• A definition of fair compensation as a (UC) functionality-wrapper forces us to be precise- An explicit formation of synchrony with a single global

clock (capturing what protocols assume in reality).

• Compatibility with standard (formal) analysis of crypto protocols

• A (universal) composition theorem

Page 147: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

W(F f)

A Formal Model: GUC

P1 P2 Pn…

Ideal World F f

P1 P2 Pn…

Real World

π1(x1) π2(x2) πn(xn)

GLedger

GLedger

???

Page 148: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

W(F f)

A Formal Model: GUC

P1 P2 Pn…

Ideal World F f

P1 P2 Pn…

Real World

π1(x1) π2(x2) πn(xn)

GLedger

GLedger

???

Page 149: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : FunctionalityA wrapper functionality W(F f) with three predicates:• (QInit, QDlvr, QAbrt)

Page 150: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : Functionality

Idea: The predicates are used to filter the adversarial influence• QInit(State,Walleti) = True iff the Walleti has enough

funds

• QDlvr(State, Walleti) = True iff it is OK to deliver to Pi

• E.g., if Pi does not “owe” money

• QAbrt(State, Walleti) = True iff it is OK for Pi to abort• E.g., if Pi has an increase of funds

A wrapper functionality W(F f) with three predicates:• (QInit, QDlvr, QAbrt)

Page 151: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : FunctionalityA wrapper functionality W(F f) with three predicates:• (QInit, QDlvr, QAbrt)

Phase 1: Resource Allocation

Gledger

F f

W(F f)

Page 152: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : FunctionalityA wrapper functionality W(F f) with three predicates:• (QInit, QDlvr, QAbrt)

Phase 1: Resource Allocation

Pi“allocate”

Gledger

F f

W(F f)

Page 153: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : FunctionalityA wrapper functionality W(F f) with three predicates:• (QInit, QDlvr, QAbrt)

Phase 1: Resource Allocation

Pi“allocate”

“allocate Pi”

Gledger

F f

W(F f)

Page 154: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : FunctionalityA wrapper functionality W(F f) with three predicates:• (QInit, QDlvr, QAbrt)

Phase 1: Resource Allocation

Pi“allocate”

“allocate Pi”

“r”

Gledger

F f

W(F f)

Page 155: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : FunctionalityA wrapper functionality W(F f) with three predicates:• (QInit, QDlvr, QAbrt)

Phase 1: Resource Allocation

Pi“allocate”

“allocate Pi”

“r”

Create (PKi, SKi) = Gen(r,1k)

Gledger

F f

W(F f)

Page 156: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : FunctionalityA wrapper functionality W(F f) with three predicates:• (QInit, QDlvr, QAbrt)

Phase 1: Resource Allocation

Pi“allocate”

“allocate Pi”

“r”

Create (PKi, SKi) = Gen(r,1k)PKi

Gledger

F f

W(F f)

Page 157: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : FunctionalityA wrapper functionality W(F f) with three predicates:• (QInit, QDlvr, QAbrt)

Phase 1: Resource Allocation

Pi“allocate”

“allocate Pi”

“r”

Create (PKi, SKi) = Gen(r,1k)PKi

Gledger

m,F mF f

W(F f)

Page 158: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : FunctionalityA wrapper functionality W(F f) with three predicates:• (QInit, QDlvr, QAbrt)

Phase 1: Resource Allocation

Pi“allocate”

“allocate Pi”

“r”

Create (PKi, SKi) = Gen(r,1k)PKi

Gledger

m,F mm for Simm F f

W(F f)

Page 159: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : Functionality

F f

Phase 2: Input

Pi

m,F mm for Simm

Gledger

A wrapper functionality W(F f) with three predicates:• (QInit, QDlvr, QAbrt)

W(F f)

Page 160: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : Functionality

F f

Phase 2: Input

Pi“Input, x”

m,F mm for Simm

Gledger

A wrapper functionality W(F f) with three predicates:• (QInit, QDlvr, QAbrt)

W(F f)

Page 161: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : Functionality

F f

Phase 2: Input

Pi“Input, x”

m,F m

getState

m for Simm

Gledger

A wrapper functionality W(F f) with three predicates:• (QInit, QDlvr, QAbrt)

W(F f)

Page 162: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : Functionality

F f

Phase 2: Input

Pi“Input, x”

m,F m

getStateState

m for Simm

Gledger

A wrapper functionality W(F f) with three predicates:• (QInit, QDlvr, QAbrt)

W(F f)

Page 163: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : Functionality

F f

Phase 2: Input

Pi“Input, x”

m,F m

getStateState

xQInit(State,PKi)

YesNo

m for Simm

Gledger

A wrapper functionality W(F f) with three predicates:• (QInit, QDlvr, QAbrt)

W(F f)

Page 164: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : Functionality

F f

Phase 2: Input

Pi“Input, x”

m,F m

getStateState

xQInit(State,PKi)

YesNox

m for Simm

Gledger

A wrapper functionality W(F f) with three predicates:• (QInit, QDlvr, QAbrt)

W(F f)

Page 165: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : Functionality

F f

Phase 2: Input

Pi“Input, x”

m,F m

getStateState

xQInit(State,PKi)

YesNox

m for Simm

Gledger

A wrapper functionality W(F f) with three predicates:• (QInit, QDlvr, QAbrt)

W(F f)

Page 166: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : Functionality

Phase 3: OutputPi

A wrapper functionality WP1,…,Pn(F f) with three predicates:• (QInit, QDlvr, QAbrt)

F f

Gledger W(F f)

m for Simmm,F m

Page 167: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : Functionality

Phase 3: OutputPi

Deliver, (f(x1),…,f(xn))

A wrapper functionality WP1,…,Pn(F f) with three predicates:• (QInit, QDlvr, QAbrt)

F f

Gledger W(F f)

m for Simmm,F m

Page 168: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : Functionality

Phase 3: OutputPi

Deliver, (f(x1),…,f(xn))

Ready for FairDeliver+

Corrupt outputs

A wrapper functionality WP1,…,Pn(F f) with three predicates:• (QInit, QDlvr, QAbrt)

F f

Gledger W(F f)

m for Simmm,F m

Page 169: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

SFE with Robust Compen. : Functionality

Phase 3: OutputPi

Deliver, (f(x1),…,f(xn))

Ready for FairDeliver+

Corrupt outputs

A wrapper functionality WP1,…,Pn(F f) with three predicates:• (QInit, QDlvr, QAbrt)

F f

Gledger

Deliver/Abort Pi

W(F f)

m for Simmm,F m

Page 170: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

getStateState

SFE with Robust Compen. : Functionality

Phase 3: OutputPi

Deliver, (f(x1),…,f(xn))

Ready for FairDeliver+

Corrupt outputs

A wrapper functionality WP1,…,Pn(F f) with three predicates:• (QInit, QDlvr, QAbrt)

F f

Gledger

Deliver/Abort Pi

W(F f)

m for Simmm,F m

Page 171: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

getStateState

SFE with Robust Compen. : Functionality

Phase 3: OutputPi

Deliver, (f(x1),…,f(xn))

Ready for FairDeliver+

Corrupt outputs

A wrapper functionality WP1,…,Pn(F f) with three predicates:• (QInit, QDlvr, QAbrt)

F f

Gledger

Deliver/Abort Pi

W(F f)

The adversary can deliver to Pi only if QDlvr(State, Pi)=True

The adversary can make Pi abort only if QAbrt(State, Pi)=True

m for Simmm,F m

Page 172: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

getStateState

SFE with Robust Compen. : Functionality

Phase 3: OutputPi

Deliver, (f(x1),…,f(xn))

Ready for FairDeliver+

Corrupt outputs

A wrapper functionality WP1,…,Pn(F f) with three predicates:• (QInit, QDlvr, QAbrt)

F f

Gledger

Deliver/Abort Pi

W(F f)

The adversary can deliver to Pi only if QDlvr(State, Pi)=True

The adversary can make Pi abort only if QAbrt(State, Pi)=True

m for Simmm,F m

? f(xi)/⊥

Page 173: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

W(F f)

A Formal Model: GUC

P1 P2 Pn…

Ideal World F f

P1 P2 Pn…

Real World

π1(x1) π2(x2) πn(xn)

GLedger

GLedger

???

Page 174: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

Take Away Message and Open Directions

Page 175: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

Take Away Message and Open Directions• Bitcoin opens new directions for cryptographic models

- Adding a reward/punishment mechanism restricts the set of likely attacks

- Limitations of crypto should be reconsidered (Impossibilities/Efficiencies)

• The choice of the model makes a difference when suggesting a solution- Safe strategy: Rectify the cryptographic model (Bonus:

compatibility)

Page 176: Cryptography on the Blockchain - bitcoinschool.gr · Cryptography on the Blockchain IACR Summer School on Blockchain Techs Vassilis Zikas RPI Aggelos Kiayias, Hong-Shen Zhou, and

Take Away Message and Open Directions• Bitcoin opens new directions for cryptographic models

- Adding a reward/punishment mechanism restricts the set of likely attacks

- Limitations of crypto should be reconsidered (Impossibilities/Efficiencies)

• The choice of the model makes a difference when suggesting a solution- Safe strategy: Rectify the cryptographic model (Bonus:

compatibility)

Future directions• A game theoretic analysis might allow us to improve

existing results • What more can we get from Bitcoin?• The right model for exploring its rational aspects?