Practical Garbled Circuit Optimizations Mike Rosulek Collaborators: - - PowerPoint PPT Presentation

practical garbled circuit optimizations
SMART_READER_LITE
LIVE PREVIEW

Practical Garbled Circuit Optimizations Mike Rosulek Collaborators: - - PowerPoint PPT Presentation

Practical Garbled Circuit Optimizations Mike Rosulek Collaborators: David Evans / Vlad Kolesnikov / Payman Mohassel / Samee Zahur Garbled circuit framework [Yao86] Garbled circuit framework [Yao86] 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 0 1 1


slide-1
SLIDE 1

Practical Garbled Circuit Optimizations

Mike Rosulek

Collaborators: David Evans / Vlad Kolesnikov / Payman Mohassel / Samee Zahur

slide-2
SLIDE 2

Garbled circuit framework [Yao86]

slide-3
SLIDE 3

Garbled circuit framework [Yao86]

0 0 0 0 1 1 1 0 0 1 1 0 0 0 0 0 1 1 1 0 1 1 1 0 0 0 0 0 1 1 1 0 0 1 1 0 0 0 0 0 1 1 1 0 0 1 1 0 0 0 0 0 1 1 1 0 1 1 1 1

slide-4
SLIDE 4

Garbled circuit framework [Yao86]

A0,A1 B0,B1 C0,C1 D0,D1 E0,E1 F0,F1 G0,G1 H0,H1 I0,I1

0 0 0 0 1 1 1 0 0 1 1 0 0 0 0 0 1 1 1 0 1 1 1 0 0 0 0 0 1 1 1 0 0 1 1 0 0 0 0 0 1 1 1 0 0 1 1 0 0 0 0 0 1 1 1 0 1 1 1 1

Garbling a circuit:

◮ Pick random labels W0,W1 on each wire

slide-5
SLIDE 5

Garbled circuit framework [Yao86]

A0,A1 B0,B1 C0,C1 D0,D1 E0,E1 F0,F1 G0,G1 H0,H1 I0,I1

A0 B0 E0 A0 B1 E1 A1 B0 E0 A1 B1 E0 A0 B0 F0 A0 B1 F1 A1 B0 F1 A1 B1 F0 C0 D0 G0 C0 D1 G1 C1 D0 G0 C1 D1 G0 F0 G0 H0 F0 G1 H1 F1 G0 H0 F1 G1 H0 E0 H0 I0 E0 H1 I1 E1 H0 I1 E1 H1 I1

Garbling a circuit:

◮ Pick random labels W0,W1 on each wire

slide-6
SLIDE 6

Garbled circuit framework [Yao86]

A0,A1 B0,B1 C0,C1 D0,D1 E0,E1 F0,F1 G0,G1 H0,H1 I0,I1

EA0,B0 (E0) EA0,B1 (E1) EA1,B0 (E0) EA1,B1 (E0) EA0,B0 (F0) EA0,B1 (F1) EA1,B0 (F1) EA1,B1 (F0) EC0,D0 (G0) EC0,D1 (G1) EC1,D0 (G0) EC1,D1 (G0) EF0,G0 (H0) EF0,G1 (H1) EF1,G0 (H0) EF1,G1 (H0) EE0,H0 (I0) EE0,H1 (I1) EE1,H0 (I1) EE1,H1 (I1)

Garbling a circuit:

◮ Pick random labels W0,W1 on each wire ◮ “Encrypt” truth table of each gate

slide-7
SLIDE 7

Garbled circuit framework [Yao86]

A0,A1 B0,B1 C0,C1 D0,D1 E0,E1 F0,F1 G0,G1 H0,H1 I0,I1

EA0,B0 (E0) EA0,B1 (E1) EA1,B0 (E0) EA1,B1 (E0) EA0,B0 (F0) EA0,B1 (F1) EA1,B0 (F1) EA1,B1 (F0) EC0,D0 (G0) EC0,D1 (G1) EC1,D0 (G0) EC1,D1 (G0) EF0,G0 (H0) EF0,G1 (H1) EF1,G0 (H0) EF1,G1 (H0) EE0,H0 (I0) EE0,H1 (I1) EE1,H0 (I1) EE1,H1 (I1)

Garbling a circuit:

◮ Pick random labels W0,W1 on each wire ◮ “Encrypt” truth table of each gate ◮ Garbled circuit ≡ all encrypted gates

slide-8
SLIDE 8

Garbled circuit framework [Yao86]

A0,A1 B0,B1 C0,C1 D0,D1 E0,E1 F0,F1 G0,G1 H0,H1 I0,I1

EA0,B0 (E0) EA0,B1 (E1) EA1,B0 (E0) EA1,B1 (E0) EA0,B0 (F0) EA0,B1 (F1) EA1,B0 (F1) EA1,B1 (F0) EC0,D0 (G0) EC0,D1 (G1) EC1,D0 (G0) EC1,D1 (G0) EF0,G0 (H0) EF0,G1 (H1) EF1,G0 (H0) EF1,G1 (H0) EE0,H0 (I0) EE0,H1 (I1) EE1,H0 (I1) EE1,H1 (I1)

Garbling a circuit:

◮ Pick random labels W0,W1 on each wire ◮ “Encrypt” truth table of each gate ◮ Garbled circuit ≡ all encrypted gates ◮ Garbled encoding ≡ one label per wire

slide-9
SLIDE 9

Garbled circuit framework [Yao86]

A0,A1 B0,B1 C0,C1 D0,D1 E0,E1 F0,F1 G0,G1 H0,H1 I0,I1

EA0,B0 (E0) EA0,B1 (E1) EA1,B0 (E0) EA1,B1 (E0) EA0,B0 (F0) EA0,B1 (F1) EA1,B0 (F1) EA1,B1 (F0) EC0,D0 (G0) EC0,D1 (G1) EC1,D0 (G0) EC1,D1 (G0) EF0,G0 (H0) EF0,G1 (H1) EF1,G0 (H0) EF1,G1 (H0) EE0,H0 (I0) EE0,H1 (I1) EE1,H0 (I1) EE1,H1 (I1)

Garbling a circuit:

◮ Pick random labels W0,W1 on each wire ◮ “Encrypt” truth table of each gate ◮ Garbled circuit ≡ all encrypted gates ◮ Garbled encoding ≡ one label per wire

Garbled evaluation:

◮ Only one ciphertext per

gate is decryptable

slide-10
SLIDE 10

Garbled circuit framework [Yao86]

A0,A1 B0,B1 C0,C1 D0,D1 E0,E1 F0,F1 G0,G1 H0,H1 I0,I1

EA0,B0 (E0) EA0,B1 (E1) EA1,B0 (E0) EA1,B1 (E0) EA0,B0 (F0) EA0,B1 (F1) EA1,B0 (F1) EA1,B1 (F0) EC0,D0 (G0) EC0,D1 (G1) EC1,D0 (G0) EC1,D1 (G0) EF0,G0 (H0) EF0,G1 (H1) EF1,G0 (H0) EF1,G1 (H0) EE0,H0 (I0) EE0,H1 (I1) EE1,H0 (I1) EE1,H1 (I1)

Garbling a circuit:

◮ Pick random labels W0,W1 on each wire ◮ “Encrypt” truth table of each gate ◮ Garbled circuit ≡ all encrypted gates ◮ Garbled encoding ≡ one label per wire

Garbled evaluation:

◮ Only one ciphertext per

gate is decryptable

◮ Result of decryption =

value on outgoing wire

slide-11
SLIDE 11

Garbled circuit framework [Yao86]

A0,A1 B0,B1 C0,C1 D0,D1 E0,E1 F0,F1 G0,G1 H0,H1 I0,I1

EA0,B0 (E0) EA0,B1 (E1) EA1,B0 (E0) EA1,B1 (E0) EA0,B0 (F0) EA0,B1 (F1) EA1,B0 (F1) EA1,B1 (F0) EC0,D0 (G0) EC0,D1 (G1) EC1,D0 (G0) EC1,D1 (G0) EF0,G0 (H0) EF0,G1 (H1) EF1,G0 (H0) EF1,G1 (H0) EE0,H0 (I0) EE0,H1 (I1) EE1,H0 (I1) EE1,H1 (I1)

Garbling a circuit:

◮ Pick random labels W0,W1 on each wire ◮ “Encrypt” truth table of each gate ◮ Garbled circuit ≡ all encrypted gates ◮ Garbled encoding ≡ one label per wire

Garbled evaluation:

◮ Only one ciphertext per

gate is decryptable

◮ Result of decryption =

value on outgoing wire

slide-12
SLIDE 12

Garbled circuit framework [Yao86]

A0,A1 B0,B1 C0,C1 D0,D1 E0,E1 F0,F1 G0,G1 H0,H1 I0,I1

EA0,B0 (E0) EA0,B1 (E1) EA1,B0 (E0) EA1,B1 (E0) EA0,B0 (F0) EA0,B1 (F1) EA1,B0 (F1) EA1,B1 (F0) EC0,D0 (G0) EC0,D1 (G1) EC1,D0 (G0) EC1,D1 (G0) EF0,G0 (H0) EF0,G1 (H1) EF1,G0 (H0) EF1,G1 (H0) EE0,H0 (I0) EE0,H1 (I1) EE1,H0 (I1) EE1,H1 (I1)

Garbling a circuit:

◮ Pick random labels W0,W1 on each wire ◮ “Encrypt” truth table of each gate ◮ Garbled circuit ≡ all encrypted gates ◮ Garbled encoding ≡ one label per wire

Garbled evaluation:

◮ Only one ciphertext per

gate is decryptable

◮ Result of decryption =

value on outgoing wire

slide-13
SLIDE 13

Garbled circuit framework [Yao86]

A0,A1 B0,B1 C0,C1 D0,D1 E0,E1 F0,F1 G0,G1 H0,H1 I0,I1

EA0,B0 (E0) EA0,B1 (E1) EA1,B0 (E0) EA1,B1 (E0) EA0,B0 (F0) EA0,B1 (F1) EA1,B0 (F1) EA1,B1 (F0) EC0,D0 (G0) EC0,D1 (G1) EC1,D0 (G0) EC1,D1 (G0) EF0,G0 (H0) EF0,G1 (H1) EF1,G0 (H0) EF1,G1 (H0) EE0,H0 (I0) EE0,H1 (I1) EE1,H0 (I1) EE1,H1 (I1)

Garbling a circuit:

◮ Pick random labels W0,W1 on each wire ◮ “Encrypt” truth table of each gate ◮ Garbled circuit ≡ all encrypted gates ◮ Garbled encoding ≡ one label per wire

Garbled evaluation:

◮ Only one ciphertext per

gate is decryptable

◮ Result of decryption =

value on outgoing wire

slide-14
SLIDE 14

Applications: 2PC and more

x y

slide-15
SLIDE 15

Applications: 2PC and more

x y garbled circuit f garbled input x,

  • utput wire labels
slide-16
SLIDE 16

Applications: 2PC and more

x y garbled circuit f garbled input x,

  • utput wire labels

OT input wire labels y garbled y

slide-17
SLIDE 17

Applications: 2PC and more

x y garbled circuit f garbled input x,

  • utput wire labels

OT input wire labels y garbled y f (x,y)

slide-18
SLIDE 18

Applications: 2PC and more

x y garbled circuit f garbled input x,

  • utput wire labels

OT input wire labels y garbled y f (x,y) Private function evaluation, zero-knowledge proofs, encryption with key-dependent message security, randomized encodings, secure

  • utsourcing, one-time programs, . . .
slide-19
SLIDE 19

Applications: 2PC and more

x y garbled circuit f garbled input x,

  • utput wire labels

OT input wire labels y garbled y f (x,y) Private function evaluation, zero-knowledge proofs, encryption with key-dependent message security, randomized encodings, secure

  • utsourcing, one-time programs, . . .

Garbling is a fundamental primitive [BellareHoangRogaway12]

slide-20
SLIDE 20

Syntax [BellareHoangRogaway12]

Garble Encode Eval Decode f garbled circuit decoding info garbled input garbled

  • utput

encoding info x f (x)

slide-21
SLIDE 21

Syntax [BellareHoangRogaway12]

Garble Encode Eval Decode f garbled circuit F decoding info d garbled input X garbled

  • utput Y

encoding info e x f (x)

slide-22
SLIDE 22

Syntax [BellareHoangRogaway12]

Garble Encode Eval Decode f garbled circuit F decoding info d garbled input X garbled

  • utput Y

encoding info e x f (x) Security properties: Privacy: (F,X,d) reveals nothing beyond f (x) Obliviousness: (F,X) reveals nothing Authenticity: given (F,X), hard to find Y that decodes {f (x),⊥}

slide-23
SLIDE 23

Parameters to optimize

computation size hardness assumption

slide-24
SLIDE 24

Parameters to optimize

computation size hardness assumption

slide-25
SLIDE 25

Average bits per garbled gate

1λ 2λ 3λ 4λ 5λ 1986 1990 1999 2008 2009 2014 2015 DES AES SHA1 SHA256

slide-26
SLIDE 26

Average bits per garbled gate

1λ 2λ 3λ 4λ 5λ 1986 1990 1999 2008 2009 2014 2015

[BeaverMicaliRogaway] [NaorPinkasSumner] [KolesnikovSchneider] [PinkasSchneiderSmartWilliams] [KolesnikovMohasselRosulek] [ZahurRosulekEvans] [Yao,GoldreichMicaliWigderson]

DES AES SHA1 SHA256

slide-27
SLIDE 27

Average bits per garbled gate

1λ 2λ 3λ 4λ 5λ 1986 1990 1999 2008 2009 2014 2015

[BeaverMicaliRogaway] [NaorPinkasSumner] [KolesnikovSchneider] [PinkasSchneiderSmartWilliams] [KolesnikovMohasselRosulek] [ZahurRosulekEvans] [Yao,GoldreichMicaliWigderson]

DES AES SHA1 SHA256

Prediction: by 2026, all garbled circuits will have zero size.

slide-28
SLIDE 28

Murky beginnings [Yao86]

A0,A1 B0,B1 C0,C1

EA0,B0 (C0) EA0,B1 (C1) EA1,B0 (C0) EA1,B1 (C0)

◮ Position in this list leaks semantic value

slide-29
SLIDE 29

Murky beginnings [Yao86]

A0,A1 B0,B1 C0,C1

EA0,B0 (C0) EA0,B1 (C1) EA1,B0 (C0) EA1,B1 (C0)

◮ Position in this list leaks semantic value

slide-30
SLIDE 30

Murky beginnings [Yao86]

A0,A1 B0,B1 C0,C1

EA0,B0 (C0) EA0,B1 (C1) EA1,B0 (C0) EA1,B1 (C0)

◮ Position in this list leaks semantic value =⇒ permute ciphertexts

slide-31
SLIDE 31

Murky beginnings [Yao86]

A0,A1 B0,B1 C0,C1

EA0,B0 (C0) EA0,B1 (C1) EA1,B0 (C0) EA1,B1 (C0)

◮ Position in this list leaks semantic value =⇒ permute ciphertexts ◮ Need to detect [in]correct decryption

slide-32
SLIDE 32

Murky beginnings [Yao86]

A0,A1 B0,B1 C0,C1

EA0,B0 (C0) EA0,B1 (C1) EA1,B0 (C0) EA1,B1 (C0)

◮ Position in this list leaks semantic value =⇒ permute ciphertexts ◮ Need to detect [in]correct decryption ◮ (Apparently) no one knows exactly what Yao had in mind:

◮ EK0,K1 (M) = E(K0,S0),E(K1,S1) where S0 ⊕ S1 = M

[GoldreichMicaliWigderson87]

◮ EK0,K1 (M) = E(K1,E(K0,M))

[LindellPinkas09]

slide-33
SLIDE 33

Permute-and-Point [BeaverMicaliRogaway90]

A0,A1 B0,B1 C0,C1 EA0,B0 (C0) EA0,B1 (C1) EA1,B0 (C0) EA1,B1 (C0)

slide-34
SLIDE 34

Permute-and-Point [BeaverMicaliRogaway90]

A•

0,A• 1

B•

0,B• 1

C•

0,C• 1

EA•

0,B• 0 (C•

0)

EA•

0,B• 1 (C•

1)

EA•

1,B• 0 (C•

0)

EA•

1,B• 1 (C•

0) ◮ Randomly assign (•,•) or (•,•)

to each pair of wire labels

◮ Include color in the wire label

(e.g., as last bit)

slide-35
SLIDE 35

Permute-and-Point [BeaverMicaliRogaway90]

A•

0,A• 1

B•

0,B• 1

C•

0,C• 1

  • • EA0,B0 (C•

0)

  • • EA0,B1 (C•

1)

  • • EA1,B0 (C•

0)

  • • EA1,B1 (C•

0) ◮ Randomly assign (•,•) or (•,•)

to each pair of wire labels

◮ Include color in the wire label

(e.g., as last bit)

◮ Order the 4 ciphertexts

canonically, by color of keys

slide-36
SLIDE 36

Permute-and-Point [BeaverMicaliRogaway90]

A•

0,A• 1

B•

0,B• 1

C•

0,C• 1

  • • EA0,B1 (C•

1)

  • • EA0,B0 (C•

0)

  • • EA1,B1 (C•

0)

  • • EA1,B0 (C•

0) ◮ Randomly assign (•,•) or (•,•)

to each pair of wire labels

◮ Include color in the wire label

(e.g., as last bit)

◮ Order the 4 ciphertexts

canonically, by color of keys

slide-37
SLIDE 37

Permute-and-Point [BeaverMicaliRogaway90]

A0,A•

1

B0,B•

1

C0,C1

  • • EA0,B1 (C1)
  • • EA0,B0 (C0)
  • • EA1,B1 (C0)
  • • EA1,B0 (C0)

◮ Randomly assign (•,•) or (•,•)

to each pair of wire labels

◮ Include color in the wire label

(e.g., as last bit)

◮ Order the 4 ciphertexts

canonically, by color of keys

◮ Evaluate by decrypting

ciphertext indexed by your colors

slide-38
SLIDE 38

Permute-and-Point [BeaverMicaliRogaway90]

A0,A•

1

B0,B•

1

C•

0,C1

  • • EA0,B1 (C1)
  • • EA0,B0 (C0)
  • • EA1,B1 (C•

0)

  • • EA1,B0 (C0)

◮ Randomly assign (•,•) or (•,•)

to each pair of wire labels

◮ Include color in the wire label

(e.g., as last bit)

◮ Order the 4 ciphertexts

canonically, by color of keys

◮ Evaluate by decrypting

ciphertext indexed by your colors

slide-39
SLIDE 39

Permute-and-Point [BeaverMicaliRogaway90]

A0,A•

1

B0,B•

1

C•

0,C1

  • • EA0,B1 (C1)
  • • EA0,B0 (C0)
  • • EA1,B1 (C•

0)

  • • EA1,B0 (C0)

◮ Randomly assign (•,•) or (•,•)

to each pair of wire labels

◮ Include color in the wire label

(e.g., as last bit)

◮ Order the 4 ciphertexts

canonically, by color of keys

◮ Evaluate by decrypting

ciphertext indexed by your colors Can use one-time-secure symmetric encryption!

slide-40
SLIDE 40

Computational cost of garbling

EA,B(C): cost to garble AES PRF(A,gateID) ⊕ PRF(B,gateID) ⊕ C ∼6s [extrapolated]

[NaorPinkasSumner99]

time from Fairplay [MNPS04]: PRF = SHA256

slide-41
SLIDE 41

Computational cost of garbling

2 hash ≫ 1 hash EA,B(C): cost to garble AES PRF(A,gateID) ⊕ PRF(B,gateID) ⊕ C ∼6s [extrapolated]

[NaorPinkasSumner99]

time from Fairplay [MNPS04]: PRF = SHA256

H(ABgateID) ⊕ C 0.15s

[LindellPinkasSmart08]

time from [sS12]; H = SHA256

slide-42
SLIDE 42

Computational cost of garbling

2 hash ≫ 1 hash ≫ 1 block cipher EA,B(C): cost to garble AES PRF(A,gateID) ⊕ PRF(B,gateID) ⊕ C ∼6s [extrapolated]

[NaorPinkasSumner99]

time from Fairplay [MNPS04]: PRF = SHA256

H(ABgateID) ⊕ C 0.15s

[LindellPinkasSmart08]

time from [sS12]; H = SHA256

AES256(AB,gateID) ⊕ C 0.12s

[shelatShen12]

slide-43
SLIDE 43

Computational cost of garbling

2 hash ≫ 1 hash ≫ 1 block cipher ≫ 1 block cipher w/o key schedule EA,B(C): cost to garble AES PRF(A,gateID) ⊕ PRF(B,gateID) ⊕ C ∼6s [extrapolated]

[NaorPinkasSumner99]

time from Fairplay [MNPS04]: PRF = SHA256

H(ABgateID) ⊕ C 0.15s

[LindellPinkasSmart08]

time from [sS12]; H = SHA256

AES256(AB,gateID) ⊕ C 0.12s

[shelatShen12]

AES(const,K) ⊕ K ⊕ C 0.0003s

where K = 2A ⊕ 4B ⊕ gateID

[BellareHoangKeelveedhiRogaway13]

slide-44
SLIDE 44

Scoreboard

size (×λ) garble cost eval cost assumption Classical large? 8 5 PKE P&P 4 4/8 1/2 hash/PRF

slide-45
SLIDE 45

Garbled Row Reduction [NaorPinkasSumner99]

A•

0,A• 1

B•

0B• 1

C•

0C• 1

  • • EA0,B1(C•

1)

  • • EA0,B0(C•

0)

  • • EA1,B1(C•

0)

  • • EA1,B0(C•

0)

slide-46
SLIDE 46

Garbled Row Reduction [NaorPinkasSumner99]

A•

0,A• 1

B•

0B• 1

C•

0C• 1

C0 ← {0,1}n C1 ← {0,1}n

  • • EA0,B1(C•

1)

  • • EA0,B0(C•

0)

  • • EA1,B1(C•

0)

  • • EA1,B0(C•

0)

slide-47
SLIDE 47

Garbled Row Reduction [NaorPinkasSumner99]

A•

0,A• 1

B•

0B• 1

C•

0C• 1

C0 ← {0,1}n C1 ← {0,1}n

  • • EA0,B1(C•

1)

  • • EA0,B0(C•

0)

  • • EA1,B1(C•

0)

  • • EA1,B0(C•

0) ◮ What wire label will be payload of 1st (••) ciphertext?

slide-48
SLIDE 48

Garbled Row Reduction [NaorPinkasSumner99]

A•

0,A• 1

B•

0B• 1

C•

0C• 1

C0 ← {0,1}n C1 = E−1

A0,B1(0n)

  • • EA0,B1(C•

1)

  • • EA0,B0(C•

0)

  • • EA1,B1(C•

0)

  • • EA1,B0(C•

0) ◮ What wire label will be payload of 1st (••) ciphertext? ◮ Choose that label so that 1st ciphertext is 0n

slide-49
SLIDE 49

Garbled Row Reduction [NaorPinkasSumner99]

A•

0,A• 1

B•

0B• 1

C•

0C• 1

C0 ← {0,1}n C1 = E−1

A0,B1(0n)

  • 0n
  • • EA0,B0(C•

0)

  • • EA1,B1(C•

0)

  • • EA1,B0(C•

0) ◮ What wire label will be payload of 1st (••) ciphertext? ◮ Choose that label so that 1st ciphertext is 0n

slide-50
SLIDE 50

Garbled Row Reduction [NaorPinkasSumner99]

A•

0,A• 1

B•

0B• 1

C•

0C• 1

C0 ← {0,1}n C1 = E−1

A0,B1(0n)

  • • EA0,B0(C•

0)

  • • EA1,B1(C•

0)

  • • EA1,B0(C•

0) ◮ What wire label will be payload of 1st (••) ciphertext? ◮ Choose that label so that 1st ciphertext is 0n ◮ No need to include 1st ciphertext in garbled gate

slide-51
SLIDE 51

Garbled Row Reduction [NaorPinkasSumner99]

A•

0,A• 1

B•

0B• 1

C•

0C• 1

C0 ← {0,1}n C1 = E−1

A0,B1(0n)

  • • EA0,B0(C•

0)

  • • EA1,B1(C•

0)

  • • EA1,B0(C•

0) ◮ What wire label will be payload of 1st (••) ciphertext? ◮ Choose that label so that 1st ciphertext is 0n ◮ No need to include 1st ciphertext in garbled gate ◮ Evaluate as before, but imagine ciphertext 0n if you got ••.

slide-52
SLIDE 52

Scoreboard

size (×λ) garble cost eval cost assumption Classical large? 8 5 PKE P&P 4 4/8 1/2 hash/PRF GRR3 3 4/8 1/2 hash/PRF

slide-53
SLIDE 53

Free XOR [KolesnikovSchneider08]

A0,A1 B0,B1 C0,C1

slide-54
SLIDE 54

Free XOR [KolesnikovSchneider08]

A,A ⊕ ∆A B,B ⊕ ∆B C,C ⊕ ∆C

◮ Wire’s offset ≡ XOR of its two labels

slide-55
SLIDE 55

Free XOR [KolesnikovSchneider08]

A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆

◮ Wire’s offset ≡ XOR of its two labels ◮ Choose all wires to have same (secret) offset ∆

slide-56
SLIDE 56

Free XOR [KolesnikovSchneider08]

A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ C ← {0,1}n

◮ Wire’s offset ≡ XOR of its two labels ◮ Choose all wires to have same (secret) offset ∆

slide-57
SLIDE 57

Free XOR [KolesnikovSchneider08]

A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ C := A ⊕ B A

  • false

⊕ B

  • false

= A ⊕ B

  • false

◮ Wire’s offset ≡ XOR of its two labels ◮ Choose all wires to have same (secret) offset ∆ ◮ Choose false output = false input ⊕ false input

slide-58
SLIDE 58

Free XOR [KolesnikovSchneider08]

A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ C := A ⊕ B A

  • false

⊕ B ⊕ ∆

  • true

= A ⊕ B ⊕ ∆

  • true

◮ Wire’s offset ≡ XOR of its two labels ◮ Choose all wires to have same (secret) offset ∆ ◮ Choose false output = false input ⊕ false input ◮ Evaluate by xoring input wire labels (no crypto)

slide-59
SLIDE 59

Free XOR [KolesnikovSchneider08]

A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ C := A ⊕ B A ⊕ ∆

  • true

⊕ B

  • false

= A ⊕ B ⊕ ∆

  • true

◮ Wire’s offset ≡ XOR of its two labels ◮ Choose all wires to have same (secret) offset ∆ ◮ Choose false output = false input ⊕ false input ◮ Evaluate by xoring input wire labels (no crypto)

slide-60
SLIDE 60

Free XOR [KolesnikovSchneider08]

A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ C := A ⊕ B A ⊕ ∆

  • true

⊕ B ⊕ ∆

  • true

= A ⊕ B

  • false

◮ Wire’s offset ≡ XOR of its two labels ◮ Choose all wires to have same (secret) offset ∆ ◮ Choose false output = false input ⊕ false input ◮ Evaluate by xoring input wire labels (no crypto)

slide-61
SLIDE 61

Freedom at a cost. . .

A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ EA

,B

(C ) EA

,B⊕∆(C ⊕ ∆)

EA⊕∆,B (C ) EA⊕∆,B⊕∆(C )

◮ Still need to garble and gates

slide-62
SLIDE 62

Freedom at a cost. . .

A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ C ← {0,1}n EA

,B

(C ) EA

,B⊕∆(C ⊕ ∆)

EA⊕∆,B (C ) EA⊕∆,B⊕∆(C )

◮ Still need to garble and gates ◮ Compatible with garbled row-reduction

slide-63
SLIDE 63

Freedom at a cost. . .

A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ C := E−1

A,B(0n)

EA

,B

(C ) EA

,B⊕∆(C ⊕ ∆)

EA⊕∆,B (C ) EA⊕∆,B⊕∆(C )

◮ Still need to garble and gates ◮ Compatible with garbled row-reduction

slide-64
SLIDE 64

Freedom at a cost. . .

A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ EA

,B

(C ) EA

,B⊕∆(C ⊕ ∆)

EA⊕∆,B (C ) EA⊕∆,B⊕∆(C )

◮ Still need to garble and gates ◮ Compatible with garbled row-reduction ◮ Secret ∆ used in key and payload of ciphertexts!

slide-65
SLIDE 65

Freedom at a cost. . .

A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ EA

,B

(C ) EA

,B⊕∆(C ⊕ ∆)

EA⊕∆,B (C ) EA⊕∆,B⊕∆(C )

◮ Still need to garble and gates ◮ Compatible with garbled row-reduction ◮ Secret ∆ used in key and payload of ciphertexts! ◮ Requires related-key + circularity assumption [ChoiKatzKumaresanZhou12]

slide-66
SLIDE 66

Scoreboard

size (×λ) garble cost eval cost assumption XOR AND XOR AND XOR AND Classical large? 8 5 PKE P&P 4 4 4/8 4/8 1/2 1/2 PRF/hash GRR3 3 3 4/8 4/8 1/2 1/2 PRF/hash Free XOR 3 4 1

  • circ. hash
slide-67
SLIDE 67

Row reduction ++ [PinkasSchneiderSmartWilliams09]

Garbled gates with only 2 ciphertexts! A0,A1 B0,B1 C0,C1

slide-68
SLIDE 68

Row reduction ++ [PinkasSchneiderSmartWilliams09]

Garbled gates with only 2 ciphertexts!

◮ Evaluator can know exactly one of:

K1 = E−1

A0,B0(0n)

K2 = E−1

A0,B1(0n)

K3 = E−1

A1,B0(0n)

K4 = E−1

A1,B1(0n)

A0,A1 B0,B1 C0,C1

slide-69
SLIDE 69

Row reduction ++ [PinkasSchneiderSmartWilliams09]

Garbled gates with only 2 ciphertexts!

◮ Evaluator can know exactly one of:

K1 = E−1

A0,B0(0n) learn C0

K2 = E−1

A0,B1(0n) learn C1

K3 = E−1

A1,B0(0n) learn C0

K4 = E−1

A1,B1(0n) learn C0

A0,A1 B0,B1 C0,C1

slide-70
SLIDE 70

Row reduction ++ [PinkasSchneiderSmartWilliams09]

Garbled gates with only 2 ciphertexts!

◮ Evaluator can know exactly one of:

K1 = E−1

A0,B0(0n) learn C0

K2 = E−1

A0,B1(0n) learn C1

K3 = E−1

A1,B0(0n) learn C0

K4 = E−1

A1,B1(0n) learn C0

A0,A1 B0,B1 C0,C1

(1, K1) (3, K3) (4, K4)

(1,K1), (3,K3), (4,K4)

slide-71
SLIDE 71

Row reduction ++ [PinkasSchneiderSmartWilliams09]

Garbled gates with only 2 ciphertexts!

◮ Evaluator can know exactly one of:

K1 = E−1

A0,B0(0n) learn C0

K2 = E−1

A0,B1(0n) learn C1

K3 = E−1

A1,B0(0n) learn C0

K4 = E−1

A1,B1(0n) learn C0

A0,A1 B0,B1 C0,C1

(1, K1) (3, K3) (4, K4)

P = uniq deg-2 poly thru (1,K1), (3,K3), (4,K4)

slide-72
SLIDE 72

Row reduction ++ [PinkasSchneiderSmartWilliams09]

Garbled gates with only 2 ciphertexts!

◮ Evaluator can know exactly one of:

K1 = E−1

A0,B0(0n) learn C0

K2 = E−1

A0,B1(0n) learn C1

K3 = E−1

A1,B0(0n) learn C0

K4 = E−1

A1,B1(0n) learn C0

A0,A1 B0,B1 C0,C1

(2, K2) P(5) P(6)

P = uniq deg-2 poly thru (1,K1), (3,K3), (4,K4) (2,K2), (5,P(5)), (6,P(6))

slide-73
SLIDE 73

Row reduction ++ [PinkasSchneiderSmartWilliams09]

Garbled gates with only 2 ciphertexts!

◮ Evaluator can know exactly one of:

K1 = E−1

A0,B0(0n) learn C0

K2 = E−1

A0,B1(0n) learn C1

K3 = E−1

A1,B0(0n) learn C0

K4 = E−1

A1,B1(0n) learn C0

A0,A1 B0,B1 C0,C1

(2, K2) P(5) P(6)

P = uniq deg-2 poly thru (1,K1), (3,K3), (4,K4) Q = uniq deg-2 poly thru (2,K2), (5,P(5)), (6,P(6))

slide-74
SLIDE 74

Row reduction ++ [PinkasSchneiderSmartWilliams09]

Garbled gates with only 2 ciphertexts!

◮ Evaluator can know exactly one of:

K1 = E−1

A0,B0(0n) learn C0

K2 = E−1

A0,B1(0n) learn C1

K3 = E−1

A1,B0(0n) learn C0

K4 = E−1

A1,B1(0n) learn C0

A0,A1 B0,B1 C0,C1 C0 = P(0); C1 = Q(0)

P(0) Q(0)

P = uniq deg-2 poly thru (1,K1), (3,K3), (4,K4) Q = uniq deg-2 poly thru (2,K2), (5,P(5)), (6,P(6))

slide-75
SLIDE 75

Row reduction ++ [PinkasSchneiderSmartWilliams09]

Garbled gates with only 2 ciphertexts!

◮ Evaluator can know exactly one of:

K1 = E−1

A0,B0(0n) learn C0

K2 = E−1

A0,B1(0n) learn C1

K3 = E−1

A1,B0(0n) learn C0

K4 = E−1

A1,B1(0n) learn C0

A0,A1 B0,B1 C0,C1 C0 = P(0); C1 = Q(0) P(5) P(6)

P(0) Q(0) P(5) P(6)

P = uniq deg-2 poly thru (1,K1), (3,K3), (4,K4) Q = uniq deg-2 poly thru (2,K2), (5,P(5)), (6,P(6))

slide-76
SLIDE 76

Row reduction ++ [PinkasSchneiderSmartWilliams09]

Garbled gates with only 2 ciphertexts!

◮ Evaluator can know exactly one of:

K1 = E−1

A0,B0(0n) learn C0

K2 = E−1

A0,B1(0n) learn C1

K3 = E−1

A1,B0(0n) learn C0

K4 = E−1

A1,B1(0n) learn C0 ◮ Evaluate by interpolating poly thru

Ki, P(5) and P(6) A0,A1 B0,B1 C0,C1 C0 = P(0); C1 = Q(0) P(5) P(6)

P(5) P(6)

P = uniq deg-2 poly thru (1,K1), (3,K3), (4,K4) Q = uniq deg-2 poly thru (2,K2), (5,P(5)), (6,P(6))

slide-77
SLIDE 77

Row reduction ++ [PinkasSchneiderSmartWilliams09]

Garbled gates with only 2 ciphertexts!

◮ Evaluator can know exactly one of:

K1 = E−1

A0,B0(0n) learn C0

K2 = E−1

A0,B1(0n) learn C1

K3 = E−1

A1,B0(0n) learn C0

K4 = E−1

A1,B1(0n) learn C0 ◮ Evaluate by interpolating poly thru

Ki, P(5) and P(6) A0,A1 B0,B1 C0,C1 C0 = P(0); C1 = Q(0) P(5) P(6)

P(5) P(6)

P = uniq deg-2 poly thru (1,K1), (3,K3), (4,K4) Q = uniq deg-2 poly thru (2,K2), (5,P(5)), (6,P(6))

slide-78
SLIDE 78

Row reduction ++ [PinkasSchneiderSmartWilliams09]

Garbled gates with only 2 ciphertexts!

◮ Evaluator can know exactly one of:

K1 = E−1

A0,B0(0n) learn C0

K2 = E−1

A0,B1(0n) learn C1

K3 = E−1

A1,B0(0n) learn C0

K4 = E−1

A1,B1(0n) learn C0 ◮ Evaluate by interpolating poly thru

Ki, P(5) and P(6) A0,A1 B0,B1 C0,C1 C0 = P(0); C1 = Q(0) P(5) P(6)

(3, K3) P(5) P(6)

P = uniq deg-2 poly thru (1,K1), (3,K3), (4,K4) Q = uniq deg-2 poly thru (2,K2), (5,P(5)), (6,P(6))

slide-79
SLIDE 79

Row reduction ++ [PinkasSchneiderSmartWilliams09]

Garbled gates with only 2 ciphertexts!

◮ Evaluator can know exactly one of:

K1 = E−1

A0,B0(0n) learn C0

K2 = E−1

A0,B1(0n) learn C1

K3 = E−1

A1,B0(0n) learn C0

K4 = E−1

A1,B1(0n) learn C0 ◮ Evaluate by interpolating poly thru

Ki, P(5) and P(6) A0,A1 B0,B1 C0,C1 C0 = P(0); C1 = Q(0) P(5) P(6)

(3, K3) P(5) P(6)

P = uniq deg-2 poly thru (1,K1), (3,K3), (4,K4) Q = uniq deg-2 poly thru (2,K2), (5,P(5)), (6,P(6))

slide-80
SLIDE 80

Row reduction ++ [PinkasSchneiderSmartWilliams09]

Garbled gates with only 2 ciphertexts!

◮ Evaluator can know exactly one of:

K1 = E−1

A0,B0(0n) learn C0

K2 = E−1

A0,B1(0n) learn C1

K3 = E−1

A1,B0(0n) learn C0

K4 = E−1

A1,B1(0n) learn C0 ◮ Evaluate by interpolating poly thru

Ki, P(5) and P(6) A0,A1 B0,B1 C0,C1 C0 = P(0); C1 = Q(0) P(5) P(6)

P(0) (3, K3) P(5) P(6)

P = uniq deg-2 poly thru (1,K1), (3,K3), (4,K4) Q = uniq deg-2 poly thru (2,K2), (5,P(5)), (6,P(6))

slide-81
SLIDE 81

Row reduction ++ [PinkasSchneiderSmartWilliams09]

Garbled gates with only 2 ciphertexts!

◮ Evaluator can know exactly one of:

K1 = E−1

A0,B0(0n) learn C0

K2 = E−1

A0,B1(0n) learn C1

K3 = E−1

A1,B0(0n) learn C0

K4 = E−1

A1,B1(0n) learn C0 ◮ Evaluate by interpolating poly thru

Ki, P(5) and P(6) A0,A1 B0,B1 C0,C1 C0 = P(0); C1 = Q(0) P(5) P(6)

Q(0) (2, K2) P(5) P(6)

P = uniq deg-2 poly thru (1,K1), (3,K3), (4,K4) Q = uniq deg-2 poly thru (2,K2), (5,P(5)), (6,P(6))

slide-82
SLIDE 82

Row reduction ++ [PinkasSchneiderSmartWilliams09]

Garbled gates with only 2 ciphertexts!

◮ Evaluator can know exactly one of:

K1 = E−1

A0,B0(0n) learn C0

K2 = E−1

A0,B1(0n) learn C1

K3 = E−1

A1,B0(0n) learn C0

K4 = E−1

A1,B1(0n) learn C0 ◮ Evaluate by interpolating poly thru

Ki, P(5) and P(6)

◮ Incompatible with Free-XOR: can’t

ensure C0 ⊕ C1 = ∆ A0,A1 B0,B1 C0,C1 C0 = P(0); C1 = Q(0) P(5) P(6)

P(0) Q(0) (1, K1) (2, K2) (3, K3) (4, K4) P(5) P(6)

P = uniq deg-2 poly thru (1,K1), (3,K3), (4,K4) Q = uniq deg-2 poly thru (2,K2), (5,P(5)), (6,P(6))

slide-83
SLIDE 83

Scoreboard

size (×λ) garble cost eval cost assumption XOR AND XOR AND XOR AND Classical large? 8 5 PKE P&P 4 4 4/8 4/8 1/2 1/2 hash/PRF GRR3 3 3 4/8 4/8 1/2 1/2 PRF/hash Free XOR 3 4 1

  • circ. hash

GRR2 2 2 4/8 4/8 1/2 1/2 PRF/hash

slide-84
SLIDE 84

FleXOR [KolesnikovMohasselRosulek14]

A,A ⊕ ∆1

slide-85
SLIDE 85

FleXOR [KolesnikovMohasselRosulek14]

A,A ⊕ ∆1 A∗,A∗ ⊕ ∆2

◮ Translate to a new wire offset

slide-86
SLIDE 86

FleXOR [KolesnikovMohasselRosulek14]

A,A ⊕ ∆1 A∗,A∗ ⊕ ∆2 0 0 1 1

◮ Translate to a new wire offset (unary a → a gate)

slide-87
SLIDE 87

FleXOR [KolesnikovMohasselRosulek14]

A,A ⊕ ∆1 A∗,A∗ ⊕ ∆2 A A∗ A ⊕ ∆1 A∗ ⊕ ∆2

◮ Translate to a new wire offset (unary a → a gate)

slide-88
SLIDE 88

FleXOR [KolesnikovMohasselRosulek14]

A,A ⊕ ∆1 A∗,A∗ ⊕ ∆2 EA (A∗ ) EA⊕∆1(A∗ ⊕ ∆2)

◮ Translate to a new wire offset (unary a → a gate)

slide-89
SLIDE 89

FleXOR [KolesnikovMohasselRosulek14]

A,A ⊕ ∆1 A∗,A∗ ⊕ ∆2 EA (A∗ ) EA⊕∆1(A∗ ⊕ ∆2) A∗ ← {0,1}n

◮ Translate to a new wire offset (unary a → a gate)

slide-90
SLIDE 90

FleXOR [KolesnikovMohasselRosulek14]

A,A ⊕ ∆1 A∗,A∗ ⊕ ∆2 EA (A∗ ) EA⊕∆1(A∗ ⊕ ∆2) A∗ := E−1

A (0n) ◮ Translate to a new wire offset (unary a → a gate)

slide-91
SLIDE 91

FleXOR [KolesnikovMohasselRosulek14]

A,A ⊕ ∆1 A∗,A∗ ⊕ ∆2 0n EA⊕∆1(A∗ ⊕ ∆2) A∗ := E−1

A (0n) ◮ Translate to a new wire offset (unary a → a gate)

slide-92
SLIDE 92

FleXOR [KolesnikovMohasselRosulek14]

A,A ⊕ ∆1 A∗,A∗ ⊕ ∆2 EA⊕∆1(A∗ ⊕ ∆2) A∗ := E−1

A (0n) ◮ Translate to a new wire offset (unary a → a gate) using 1 ciphertext

slide-93
SLIDE 93

FleXOR [KolesnikovMohasselRosulek14]

A,A ⊕ ∆1 A∗,A∗ ⊕ ∆2

∆1 → ∆2

EA⊕∆1(A∗ ⊕ ∆2) A∗ := E−1

A (0n) ◮ Translate to a new wire offset (unary a → a gate) using 1 ciphertext

slide-94
SLIDE 94

FleXOR [KolesnikovMohasselRosulek14]

A,A ⊕ ∆A B,B ⊕ ∆B C,C ⊕ ∆C

slide-95
SLIDE 95

FleXOR [KolesnikovMohasselRosulek14]

A,A ⊕ ∆A B,B ⊕ ∆B C,C ⊕ ∆C

∆A → ∆C ∆B → ∆C

◮ Adjust inputs to target offset ∆C (1 ciphertext each)

slide-96
SLIDE 96

FleXOR [KolesnikovMohasselRosulek14]

free A,A ⊕ ∆A B,B ⊕ ∆B C,C ⊕ ∆C

∆A → ∆C ∆B → ∆C

◮ Adjust inputs to target offset ∆C (1 ciphertext each), then XOR is free

slide-97
SLIDE 97

FleXOR [KolesnikovMohasselRosulek14]

free A,A ⊕ ∆A B,B ⊕ ∆C C,C ⊕ ∆C

∆A → ∆C

◮ Adjust inputs to target offset ∆C (1 ciphertext each), then XOR is free ◮ If input wire already suitable, no need to adjust

slide-98
SLIDE 98

FleXOR [KolesnikovMohasselRosulek14]

free A,A ⊕ ∆A B,B ⊕ ∆C C,C ⊕ ∆C

∆A → ∆C

◮ Adjust inputs to target offset ∆C (1 ciphertext each), then XOR is free ◮ If input wire already suitable, no need to adjust ◮ Total cost: 0, 1 or 2 depending on how many {∆A,∆B,∆C} distinct.

slide-99
SLIDE 99

FleXOR [KolesnikovMohasselRosulek14]

free A,A ⊕ ∆A B,B ⊕ ∆C C,C ⊕ ∆C

∆A → ∆C

◮ Adjust inputs to target offset ∆C (1 ciphertext each), then XOR is free ◮ If input wire already suitable, no need to adjust ◮ Total cost: 0, 1 or 2 depending on how many {∆A,∆B,∆C} distinct.

Combinatorial optimization problem: Choose an offset for each wire, minimizing total cost of XOR gates

◮ Subj. to compatibility with 2-ciphertext row-reduction of AND gates ◮ (or) Subj. to removing circularity property of free-XOR

slide-100
SLIDE 100

Scoreboard

size (×λ) garble cost eval cost assumption XOR AND XOR AND XOR AND Classical large? 8 5 PKE P&P 4 4 4/8 4/8 1/2 1/2 hash/PRF GRR3 3 3 4/8 4/8 1/2 1/2 PRF/hash Free XOR 3 4 1

  • circ. hash

GRR2 2 2 4/8 4/8 1/2 1/2 PRF/hash FleXOR {0,1,2} 2 {0,1,2} 4 {0,1,2} 1

  • circ. hash
slide-101
SLIDE 101

Half Gates [ZahurRosulekEvans15]

What if garbler knows in advance the truth value on one input wire? A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆

slide-102
SLIDE 102

Half Gates [ZahurRosulekEvans15]

What if garbler knows in advance the truth value on one input wire? A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆

slide-103
SLIDE 103

Half Gates [ZahurRosulekEvans15]

What if garbler knows in advance the truth value on one input wire? A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ 0 0 1 0 if a = 0: unary gate b → 0

slide-104
SLIDE 104

Half Gates [ZahurRosulekEvans15]

What if garbler knows in advance the truth value on one input wire? A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ B C B ⊕ ∆ C if a = 0: unary gate b → 0

slide-105
SLIDE 105

Half Gates [ZahurRosulekEvans15]

What if garbler knows in advance the truth value on one input wire? A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ EB (C) EB⊕∆(C) if a = 0: unary gate b → 0

slide-106
SLIDE 106

Half Gates [ZahurRosulekEvans15]

What if garbler knows in advance the truth value on one input wire? A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆

slide-107
SLIDE 107

Half Gates [ZahurRosulekEvans15]

What if garbler knows in advance the truth value on one input wire? A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ 0 0 1 1 if a = 1: unary gate b → b

slide-108
SLIDE 108

Half Gates [ZahurRosulekEvans15]

What if garbler knows in advance the truth value on one input wire? A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ B C B ⊕ ∆ C ⊕ ∆ if a = 1: unary gate b → b

slide-109
SLIDE 109

Half Gates [ZahurRosulekEvans15]

What if garbler knows in advance the truth value on one input wire? A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ EB (C ) EB⊕∆(C ⊕ ∆) if a = 1: unary gate b → b

slide-110
SLIDE 110

Half Gates [ZahurRosulekEvans15]

What if garbler knows in advance the truth value on one input wire? A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ EB (C) EB⊕∆(C) if a = 0: unary gate b → 0 EB (C ) EB⊕∆(C ⊕ ∆) if a = 1: unary gate b → b

slide-111
SLIDE 111

Half Gates [ZahurRosulekEvans15]

What if garbler knows in advance the truth value on one input wire? A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ EB (C ) EB⊕∆(C ⊕ a∆)

slide-112
SLIDE 112

Half Gates [ZahurRosulekEvans15]

What if garbler knows in advance the truth value on one input wire? A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ C ← {0,1}n EB (C ) EB⊕∆(C ⊕ a∆)

slide-113
SLIDE 113

Half Gates [ZahurRosulekEvans15]

What if garbler knows in advance the truth value on one input wire? A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ C := E−1

B (0n)

EB (C ) EB⊕∆(C ⊕ a∆)

slide-114
SLIDE 114

Half Gates [ZahurRosulekEvans15]

What if garbler knows in advance the truth value on one input wire? A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ C := E−1

B (0n)

0n EB⊕∆(C ⊕ a∆)

slide-115
SLIDE 115

Half Gates [ZahurRosulekEvans15]

What if garbler knows in advance the truth value on one input wire? A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ C := E−1

B (0n)

EB⊕∆(C ⊕ a∆)

Fine print: permute ciphertexts with permute-and-point.

slide-116
SLIDE 116

Half Gates [ZahurRosulekEvans15]

What if evaluator knows the truth value on one input wire? A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆

slide-117
SLIDE 117

Half Gates [ZahurRosulekEvans15]

What if evaluator knows the truth value on one input wire? A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆

slide-118
SLIDE 118

Half Gates [ZahurRosulekEvans15]

What if evaluator knows the truth value on one input wire? A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ Evaluator has B (knows false): ⇒ should obtain C (false)

slide-119
SLIDE 119

Half Gates [ZahurRosulekEvans15]

What if evaluator knows the truth value on one input wire? A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ EB(C) Evaluator has B (knows false): ⇒ should obtain C (false)

slide-120
SLIDE 120

Half Gates [ZahurRosulekEvans15]

What if evaluator knows the truth value on one input wire? A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ EB(C) Evaluator has B (knows false): ⇒ should obtain C (false) Evaluator has B ⊕ ∆ (knows true):

slide-121
SLIDE 121

Half Gates [ZahurRosulekEvans15]

What if evaluator knows the truth value on one input wire? A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ EB(C) Evaluator has B (knows false): ⇒ should obtain C (false) Evaluator has B ⊕ ∆ (knows true): ⇒ should be able to transfer truth value from “a” wire to “c” wire

slide-122
SLIDE 122

Half Gates [ZahurRosulekEvans15]

What if evaluator knows the truth value on one input wire? A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ EB (C ) EB⊕∆(A ⊕ C) Evaluator has B (knows false): ⇒ should obtain C (false) Evaluator has B ⊕ ∆ (knows true): ⇒ should be able to transfer truth value from “a” wire to “c” wire

◮ Suffices to learn A ⊕ C

slide-123
SLIDE 123

Half Gates [ZahurRosulekEvans15]

What if evaluator knows the truth value on one input wire? A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ EB (C ) EB⊕∆(A ⊕ C) Evaluator has B (knows false): ⇒ should obtain C (false) Evaluator has B ⊕ ∆ (knows true): ⇒ should be able to transfer truth value from “a” wire to “c” wire

◮ Suffices to learn A ⊕ C

slide-124
SLIDE 124

Half Gates [ZahurRosulekEvans15]

What if evaluator knows the truth value on one input wire? A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ EB (C ) EB⊕∆(A ⊕ C)

⊕ A ⊕ C

Evaluator has B (knows false): ⇒ should obtain C (false) Evaluator has B ⊕ ∆ (knows true): ⇒ should be able to transfer truth value from “a” wire to “c” wire

◮ Suffices to learn A ⊕ C

slide-125
SLIDE 125

Half Gates [ZahurRosulekEvans15]

What if evaluator knows the truth value on one input wire? A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ EB (C ) EB⊕∆(A ⊕ C)

⊕ A ⊕ C

Evaluator has B (knows false): ⇒ should obtain C (false) Evaluator has B ⊕ ∆ (knows true): ⇒ should be able to transfer truth value from “a” wire to “c” wire

◮ Suffices to learn A ⊕ C

slide-126
SLIDE 126

Half Gates [ZahurRosulekEvans15]

What if evaluator knows the truth value on one input wire? A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ EB (C ) EB⊕∆(A ⊕ C) C ← {0,1}n Evaluator has B (knows false): ⇒ should obtain C (false) Evaluator has B ⊕ ∆ (knows true): ⇒ should be able to transfer truth value from “a” wire to “c” wire

◮ Suffices to learn A ⊕ C

slide-127
SLIDE 127

Half Gates [ZahurRosulekEvans15]

What if evaluator knows the truth value on one input wire? A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ EB (C ) EB⊕∆(A ⊕ C) C := E−1

B (0n)

Evaluator has B (knows false): ⇒ should obtain C (false) Evaluator has B ⊕ ∆ (knows true): ⇒ should be able to transfer truth value from “a” wire to “c” wire

◮ Suffices to learn A ⊕ C

slide-128
SLIDE 128

Half Gates [ZahurRosulekEvans15]

What if evaluator knows the truth value on one input wire? A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ 0n EB⊕∆(A ⊕ C) C := E−1

B (0n)

Evaluator has B (knows false): ⇒ should obtain C (false) Evaluator has B ⊕ ∆ (knows true): ⇒ should be able to transfer truth value from “a” wire to “c” wire

◮ Suffices to learn A ⊕ C

slide-129
SLIDE 129

Half Gates [ZahurRosulekEvans15]

What if evaluator knows the truth value on one input wire? A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ EB⊕∆(A ⊕ C) C := E−1

B (0n)

Evaluator has B (knows false): ⇒ should obtain C (false) Evaluator has B ⊕ ∆ (knows true): ⇒ should be able to transfer truth value from “a” wire to “c” wire

◮ Suffices to learn A ⊕ C

slide-130
SLIDE 130

Half Gates [ZahurRosulekEvans15]

What if evaluator knows the truth value on one input wire? A,A ⊕ ∆ B,B ⊕ ∆ C,C ⊕ ∆ EB⊕∆(A ⊕ C) C := E−1

B (0n)

Evaluator has B (knows false): ⇒ should obtain C (false) Evaluator has B ⊕ ∆ (knows true): ⇒ should be able to transfer truth value from “a” wire to “c” wire

◮ Suffices to learn A ⊕ C

Fine print: no need for permute-and-point here

slide-131
SLIDE 131

Two halves make a whole!

a ∧ b

slide-132
SLIDE 132

Two halves make a whole!

a ∧ b = (a ⊕ r ⊕ r) ∧ b

◮ Garbler chooses random bit r

slide-133
SLIDE 133

Two halves make a whole!

a ∧ b = (a ⊕ r ⊕ r) ∧ b = [(a ⊕ r) ∧ b] ⊕ [r ∧ b]

◮ Garbler chooses random bit r

slide-134
SLIDE 134

Two halves make a whole!

a ∧ b = (a ⊕ r ⊕ r) ∧ b = [(a ⊕ r) ∧ b] ⊕ [r ∧ b]

◮ Garbler chooses random bit r ◮ Arrange for evaluator to learn a ⊕ r in the clear

slide-135
SLIDE 135

Two halves make a whole!

a ∧ b = (a ⊕ r ⊕ r) ∧ b = [(a ⊕ r) ∧ b]

  • ne input known to evaluator

⊕[r ∧ b]

◮ Garbler chooses random bit r ◮ Arrange for evaluator to learn a ⊕ r in the clear

slide-136
SLIDE 136

Two halves make a whole!

a ∧ b = (a ⊕ r ⊕ r) ∧ b = [(a ⊕ r) ∧ b] ⊕ [r ∧ b]

  • ne input known to garbler

◮ Garbler chooses random bit r ◮ Arrange for evaluator to learn a ⊕ r in the clear

slide-137
SLIDE 137

Two halves make a whole!

a ∧ b = (a ⊕ r ⊕ r) ∧ b = [(a ⊕ r) ∧ b] ⊕ [r ∧ b]

  • ne input known to garbler

◮ Garbler chooses random bit r ◮ Arrange for evaluator to learn a ⊕ r in the clear ◮ Total cost = 2 “half gates” + 1 XOR gate = 2 ciphertexts

slide-138
SLIDE 138

Two halves make a whole!

a ∧ b = (a ⊕ r ⊕ r) ∧ b = [(a ⊕ r) ∧ b] ⊕ [r ∧ b]

  • ne input known to garbler

◮ Garbler chooses random bit r

◮ r = color bit of false wire label A

◮ Arrange for evaluator to learn a ⊕ r in the clear

◮ a ⊕ r = color bit of wire label evaluator gets (A or A ⊕ ∆)

◮ Total cost = 2 “half gates” + 1 XOR gate = 2 ciphertexts

slide-139
SLIDE 139

Scoreboard

size (×λ) garble cost eval cost assumption XOR AND XOR AND XOR AND Classical large? 8 5 PKE P&P 4 4 4/8 4/8 1/2 1/2 hash/PRF GRR3 3 3 4/8 4/8 1/2 1/2 PRF/hash Free XOR 3 4 1

  • circ. hash

GRR2 2 2 4/8 4/8 1/2 1/2 PRF/hash FleXOR {0,1,2} 2 {0,1,2} 4 {0,1,2} 1

  • circ. symm

HalfGates 2 4 2

  • circ. hash
slide-140
SLIDE 140

Scoreboard

size (×λ) garble cost eval cost assumption XOR AND XOR AND XOR AND Classical large? 8 5 PKE P&P 4 4 4/8 4/8 1/2 1/2 hash/PRF GRR3 3 3 4/8 4/8 1/2 1/2 PRF/hash Free XOR 3 4 1

  • circ. hash

GRR2 2 2 4/8 4/8 1/2 1/2 PRF/hash FleXOR {0,1,2} 2 {0,1,2} 4 {0,1,2} 1

  • circ. symm

HalfGates 2 4 2

  • circ. hash

[XYZ26]? < 2? ? ? ? ? ?

slide-141
SLIDE 141

Optimality

Every practical garbling scheme is combination of:

◮ Calls to symmetric primitive (can be modeled as random oracle) ◮ GF (2λ)-linear operations (xor, polynomial interpolation)

slide-142
SLIDE 142

Optimality

Every practical garbling scheme is combination of:

◮ Calls to symmetric primitive (can be modeled as random oracle) ◮ GF (2λ)-linear operations (xor, polynomial interpolation)

Teorem ([ZahurRosulekEvans15])

Garbling a single and gate requires 2 ciphertexts (2λ bits), if garbling scheme is “linear” in this sense.

slide-143
SLIDE 143

Optimality

Every practical garbling scheme is combination of:

◮ Calls to symmetric primitive (can be modeled as random oracle) ◮ GF (2λ)-linear operations (xor, polynomial interpolation)

Teorem ([ZahurRosulekEvans15])

Garbling a single and gate requires 2 ciphertexts (2λ bits), if garbling scheme is “linear” in this sense. Half-gates construction is size-optimal among schemes that: . . . use “known techniques” . . . work gate-by-gate in {xor,and,not} basis

slide-144
SLIDE 144

Ways forward?

1:

Consider larger “chunks” of circuit, beyond {xor,and,not} basis?

slide-145
SLIDE 145

Ways forward?

1:

Consider larger “chunks” of circuit, beyond {xor,and,not} basis?

2:

Discover some clever non-linear approach to garbling?

slide-146
SLIDE 146

Ways forward?

1:

Consider larger “chunks” of circuit, beyond {xor,and,not} basis?

2:

Discover some clever non-linear approach to garbling?

3:

Wait for break-even point for asymptotically superior methods?

slide-147
SLIDE 147

Ways forward?

1:

Consider larger “chunks” of circuit, beyond {xor,and,not} basis?

2:

Discover some clever non-linear approach to garbling?

3:

Wait for break-even point for asymptotically superior methods?

4:

Use weaker security when situation calls for it.

slide-148
SLIDE 148

ZK via garbled circuits [JawurekKerschbaumOrlandi13]

x,w x “∃w : R(x,w) = 1 ”

slide-149
SLIDE 149

ZK via garbled circuits [JawurekKerschbaumOrlandi13]

x,w x “∃w : R(x,w) = 1 ” garbled R(x,·)

slide-150
SLIDE 150

ZK via garbled circuits [JawurekKerschbaumOrlandi13]

x,w x “∃w : R(x,w) = 1 ” garbled R(x,·) OT input wire labels w garbled w

slide-151
SLIDE 151

ZK via garbled circuits [JawurekKerschbaumOrlandi13]

x,w x “∃w : R(x,w) = 1 ” garbled R(x,·) OT input wire labels w garbled w commit(garbled output)

slide-152
SLIDE 152

ZK via garbled circuits [JawurekKerschbaumOrlandi13]

x,w x “∃w : R(x,w) = 1 ” garbled R(x,·) OT input wire labels w garbled w commit(garbled output)

contains true wire label ⇒ prover knows valid w

slide-153
SLIDE 153

ZK via garbled circuits [JawurekKerschbaumOrlandi13]

x,w x “∃w : R(x,w) = 1 ” garbled R(x,·) OT input wire labels w garbled w commit(garbled output)

contains true wire label ⇒ prover knows valid w

  • pen garbled circuit
slide-154
SLIDE 154

ZK via garbled circuits [JawurekKerschbaumOrlandi13]

x,w x “∃w : R(x,w) = 1 ” garbled R(x,·) OT input wire labels w garbled w commit(garbled output)

contains true wire label ⇒ prover knows valid w

  • pen garbled circuit

correct GC ⇒ garbled

  • utput leaks nothing

about w

slide-155
SLIDE 155

ZK via garbled circuits [JawurekKerschbaumOrlandi13]

x,w x “∃w : R(x,w) = 1 ” garbled R(x,·) OT input wire labels w garbled w commit(garbled output)

contains true wire label ⇒ prover knows valid w

  • pen garbled circuit

correct GC ⇒ garbled

  • utput leaks nothing

about w

  • pen garbled output
slide-156
SLIDE 156

ZK via garbled circuits [JawurekKerschbaumOrlandi13]

x,w x “∃w : R(x,w) = 1 ” garbled R(x,·) OT input wire labels w garbled w commit(garbled output)

contains true wire label ⇒ prover knows valid w

  • pen garbled circuit

correct GC ⇒ garbled

  • utput leaks nothing

about w

  • pen garbled output

Prover knows entire input to garbled circuit!

slide-157
SLIDE 157

Privacy-free garbling [FrederiksenNielsenOrlandi15]

For this ZK protocol, garbled circuit does not require privacy property

◮ Only authenticity is needed ◮ Garbled circuits can be significantly smaller in this case

slide-158
SLIDE 158

Privacy-free garbling [FrederiksenNielsenOrlandi15]

For this ZK protocol, garbled circuit does not require privacy property

◮ Only authenticity is needed ◮ Garbled circuits can be significantly smaller in this case

size (×λ) garble cost eval cost assumption XOR AND XOR AND XOR AND Classical large? 8 5 PKE P&P 4 4 4/8 4/8 1/2 1/2 hash/PRF GRR3 3 3 4/8 4/8 1/2 1/2 hash/PRF Free XOR 3 4 1

  • circ. hash

GRR2 2 2 4/8 4/8 1/2 1/2 hash/PRF FleXOR {0,1,2} 2 {0,1,2} 4 {0,1,2} 1

  • circ. hash

HalfGates 2 4 2

  • circ. hash

PrivFree * 1 2 1

  • circ. hash
slide-159
SLIDE 159

A success story!

1λ 2λ 3λ 4λ 5λ 1986 1990 1999 2008 2009 2014 2015 DES AES SHA1 SHA256

◮ Reduction in size by 10x ◮ Reduction in computation by 10000x

slide-160
SLIDE 160

the end!