Threshold Logical Clocks Manuel Vidigueira Distributed and - - PowerPoint PPT Presentation

threshold logical clocks
SMART_READER_LITE
LIVE PREVIEW

Threshold Logical Clocks Manuel Vidigueira Distributed and - - PowerPoint PPT Presentation

Threshold Logical Clocks Manuel Vidigueira Distributed and Decentralized Systems Lab (DEDIS) cole polytechnique fdrale de Lausanne (EPFL) Supervised by Bryan Ford and Ceyhun Alp Outline Motivation Threshold Logical Clocks


slide-1
SLIDE 1

Threshold Logical Clocks

Manuel Vidigueira

Distributed and Decentralized Systems Lab (DEDIS) École polytechnique fédérale de Lausanne (EPFL) Supervised by Bryan Ford and Ceyhun Alp

slide-2
SLIDE 2

Outline

  • Motivation
  • Threshold Logical Clocks (TLC)
  • Experimental Results
  • Using TLC
  • Conclusion

2

slide-3
SLIDE 3

Outline

  • Motivation
  • Threshold Logical Clocks (TLC)
  • Experimental Results
  • Using TLC
  • Conclusion

3

slide-4
SLIDE 4

Network models

Partially Synchronous

  • (Mostly) Asynchronous
  • Eventually it behaves

like a synchronous network

Synchronous

  • Synchronized clocks
  • Bounded message

transmission delay

  • Bounded processing

time

Asynchronous

  • No assumptions

4

More robust Easier to prove/analyse Can we get the best of both worlds?

slide-5
SLIDE 5

Measuring time in asynchronous systems

5

Meet tomorrow? TAlice: 00:00 Yes! TBob: 00:20 Meet today? TAlice: 00:10

Node clocks can be out of sync!

Alice Bob

Meet tomorrow? Meet today? Yes!

Messages are

  • rdered differently

Meet tomorrow? Yes! Meet today?

slide-6
SLIDE 6

Logical time: vector clocks

6

Alice Bob Same order (and correct)

Nodes keep track of how many messages they saw from others

Meet tomorrow? Yes! Meet today? Meet tomorrow? Yes! Meet today?

Meet tomorrow? A: 1, B: 0 Yes! A: 1, B: 1 Meet today? A: 2, B: 0

slide-7
SLIDE 7

Adversarial models

Crash-stop

  • Nodes only fail by

crashing

Byzantine

  • Nodes can do anything

(behave arbitrarily)

7

Stronger

slide-8
SLIDE 8

8

No tolerance of byzantine failures!

Meet tomorrow? A: 1, B: 0, ... Meet today? A: 2, B: 0, ... Yes! A: 2, B: 1, ... Alice Bob Eve Hey Bob... A: 2, B: 0, ... Messages arrive

  • ut of order

Meet tomorrow? Meet today? Yes! Meet tomorrow? Yes! Meet today?

slide-9
SLIDE 9

9

Alice Bob

Nodes can advance arbitrarily forward in time. No enforced group synchronization!

Everyone else Messages lost, delayed... A: 3 A: 3 A: 0 Local “time”

slide-10
SLIDE 10

Outline

  • Motivation
  • Threshold Logical Clocks (TLC)
  • Experimental Results
  • Using TLC
  • Conclusion

10

slide-11
SLIDE 11

11

Alice Bob

Threshold Logical Clocks

Idea:

  • Time is represented by a round number R
  • Nodes must have received a threshold T of messages to advance to the next

round and send another message.

R: 0 R: 1 R: 2 R: 3 (T = 2)

slide-12
SLIDE 12

Performance goals Security goals

TLC - Design goals

  • 3. Liveness

Honest nodes must be able to make progress (go to next round)

  • 4. Low latency

Rounds should be fast and use few round trips.

  • 5. Low bandwidth usage

Should scale to at least 100s of nodes

  • 1. Fully Asynchronous

No use of timeouts or synchronous assumptions.

  • 2. Byzantine Fault Tolerant

Can tolerate as many byzantine

  • r malicious nodes as possible

12

slide-13
SLIDE 13

TLC Interface

Round R

TLC

m S

Every round:

  • Provide a valid message m
  • Receive a set S of valid

messages (#S >= T)

A validation function fval filters bad messages

13

slide-14
SLIDE 14

What we want:

Round 0 Round 1 Round 2

TLC TLC

14

Real time m S

TLC

m S

TLC

m S

slide-15
SLIDE 15

TLC Interface

Two main parameters:

  • message threshold T
  • acknowledgement threshold A

Certified message:

  • appears in the set S of A different nodes (same round)

Every set S returned by TLC:

  • contains at least T different certified messages

15

(T,A) - TLC

slide-16
SLIDE 16

Simple TLC

Every round has a logical time associated to it (0, 1, 2…) Every round, each node: 1. Broadcasts its message, appending the round time 2. Broadcasts signed ACK for messages of that round 3. Waits for T messages where each has A different ACK 4. Delivers messages received and broadcast in that round 5. Increments round.

16

slide-17
SLIDE 17

Communication pattern

Broadcast O(N) Acknowledgements O(N2)

Simple TLC round split by trip time

Messages for one node

17

slide-18
SLIDE 18

Communication pattern

Broadcast O(N2) Acknowledgements O(N3)

~TLC round split by trip time

Messages for all nodes

18

slide-19
SLIDE 19

Threshold Witnessed TLC

Every round, each node: 1. Broadcasts its message, appending the round time 2. Sends signed ACK for messages of that round to their sender 3. Waits for A Acks for its message, aggregates signatures and sends certified message (message + signature). 4. Waits for T certified messages. 5. Delivers messages received and broadcast in that round 6. Increments round.

19

(T,A) - TLC

slide-20
SLIDE 20

Communication pattern

Broadcast O(N) Acknowledgements O(N) Threshold Witnessed TLC round split by trip time Messages for one node Rebroadcast O(N)

20

slide-21
SLIDE 21

Communication pattern

Broadcast O(N2) Acknowledgements O(N2) Threshold Witnessed TLC round split by trip time Messages for all nodes Rebroadcast O(N2)

21

slide-22
SLIDE 22

Outline

  • Motivation
  • Threshold Logical Clocks (TLC)
  • Experimental Results
  • Using TLC
  • Conclusion

22

slide-23
SLIDE 23

Implementation & Experimental Setup

Implementation

  • Go

○ Simple: ~420 lines ○ Threshold Witnessed: ~575 lines

  • Libraries:

○ Kyber crypto library ○ Onet network library

  • https://github.com/dedis/student_19_tlc

Deterlab setup

  • 10 physical machines
  • Network configuration:

○ 100 Mbps bandwidth ○ 200 ms round-trip latency ○ 1KB payloads

23

slide-24
SLIDE 24

Evaluation: Bandwidth

24

T = A = (n+1)/2 T = A = (2n+1)/3

slide-25
SLIDE 25

Evaluation: Round Time

25

T = A = (n+1)/2 T = A = (2n+1)/3

slide-26
SLIDE 26

Outline

  • Motivation
  • Threshold Logical Clocks (TLC)
  • Experimental Results
  • Using TLC
  • Conclusion

26

slide-27
SLIDE 27

Potential Applications

  • Threshold Cryptographic Signing
  • Threshold Cryptographic Randomness
  • Randomized Asynchronous Consensus

○ The communication logic is reduced to TLC time-steps. ○ Can be used for Byzantine consensus as well. ○ Details are currently in the works.

27

slide-28
SLIDE 28

Outline

  • Motivation
  • Threshold Logical Clocks (TLC)
  • Experimental Results
  • Using TLC
  • Conclusion

28

slide-29
SLIDE 29

Conclusion

  • Threshold Logical Clocks:

○ robust round based communication ○ group based notion of time ○ implementation with reduced bandwidth and latency ○ scales to 100s of nodes ○ many potential applications Round X

TLC

m S Thanks!

29