SlideShare a Scribd company logo
1 of 19
Download to read offline
ꜩꜩChallenges in blockchain
certification
Diego Olivier Fernandez Pons
Tezos Southeast Asia (Singapore)
diego@tezos.org.sg
November 19, 2018
1 / 19
Tezos seen from the application side
Tezos network
Tezos
node
Smart Contracts
functions / stored procedures
Desktop or Web application
Language independent
Remote Procedure Call
JSON over HTTP
For the application developer, a blockchain like Tezos is a
webservice with functions to be called via a web API.
2 / 19
Tezos seen from the core developer side
P2P layer
Distributed computation
Distributed database
Virtual machine
Contracts
Languages
x = f (3)
x = f (4)
Safe and fast computation of f
Validation that the business logic of f is correct
Expression of business logic of f
write x = 3 or x = 4 ?
f(4) -> 4f(3) -> 3
For the core developer, Tezos is a very complex piece of software.
3 / 19
Challenges in the P2P layer
Communication protocols are difficult to code
Error prone code : the Tezos network was down for a couple
of hours because of messages with nothing but 0 were sent
Attacks : The system needs to be protected against
impersonation, message deletion and DDoS
Optimization : Protocols need to be optimized for the type
of messages that are sent to reduce bandwith
The challenge is to automatically generate optimized code from a
specification proven correct.
4 / 19
Distributed computation
Compute at the entry points and broadcast the results ?
f (3)
f (4)
x = f (3)
x = f (4)
5 / 19
Distributed computation
Broadcast the function calls, elect a leader to compute and
broadcast the results ?
f (3)
f (4)
f (3)
f (4)
f (3)
f (4)
f (3)
f (4)
f (3)
f (4)
f (3)
f (4)
f (3)
f (4)
x = f (3)
x = f (4)
6 / 19
Distributed computation
Broadcast the function calls and compute on every node ?
f (3)
f (4)
f (3)
f (4)
f (3)
f (4)
f (3)
f (4)
f (3)
f (4)
f (3)
f (4)
f (3)
f (4)
x = f (3)
x = f (4)
7 / 19
Distributed computation
Challenges of distributed computations
Understand the consequences of each algorithm on the system
(liveness, latency, etc)
Formally prove the properties of the algorithms and their
variants
Automatically generate the code and its dependencies with
other layers (e.g. P2P layer for information broadcast) from a
specification
8 / 19
Distributed database
The state of the database needs to be consistent across all
nodes : one of the transactions (x = 3 or x = 4) need to be
discarded. The consensus algorithm makes sure that the network
converges on a single value.
x = 3
x = 4
?
9 / 19
Distributed database
Some results about consensus algorithms
Consensus in fault-tolerant distributed networks is impossible
[FLP 85] ⇒ Consensus ”algorithms” may not terminate.
Crash and hack-tolerance ⇒ nodes need to ”vote” and use
some form of majority rule to reach consensus
Paxos [Lamport 90] works well for closed networks : flexible,
variants for crash and hack tolerance, formally verified
Open networks are subject to sybil attacks : the majority rule
can be tricked by creating fake nodes controlled by an attacker
Nakamoto idea [2008]: in open networks, replace majority rule
by majority of computing power rule
Participating to the network consensus costs money
(computing power to create the data to be agreed upon)
Reaching consensus is rewarded with money (coins directly in
the data to be agreed upon)
10 / 19
Distributed database
Nakamoto conjecture
Consensus algorithm in an open network ⇒ internal currency
We wanted a consensus algorithm for an open distributed
database. We ended with a currency and all the problems that
go with it
All the hackers of the world will try to attack the system
All the speculators of the world will try to speculate on the
system coin
The challenges are to understand distributed consensus algorithms,
formally prove their properties and generate the corresponding
code from a formal specification.
11 / 19
Blockchains
Blockchain
Open distributed hack-tolerant databases with stored procedures
are called blockchains.
Until someone finds better consensus algorithms, replication of the
database across the network requires an internal currency to
reward nodes for reaching consensus.
The challenges are
Financial-systems grade security
Design a consensus algorithm that doesn’t require creating a
currency
12 / 19
Virtual machine
Poorly designed virtual machines are attack vectors for
blockchains.
EVM WASM Michelson
256 ints 32 / 64 ints Infinite precision ints
No data structures No data structures Persistent sets, maps, lists
Side effects Side effects No side effects
Purpose made Standard Purpose made
Ethereum Dfinity Tezos
The challenge is to understand the semantics of programs in
bytecode from unknown origin and prove properties about them,
to allow users to verify the 3rd party program they are going to call
does what it claims it does.
13 / 19
Contracts
Blockchains are per essence slow. As a result everything that can
be computed off-chain should be done so.
Bad
Contract : x -> sqrt x
App : () -> f 9
Good
Contract : x y -> if x * x = y then x else fail
App : () -> f (sqrt 9) 9
The better contract only checks a multiplication instead of
computing a square root with Newton algorithm.
14 / 19
Contracts
There are many computations that are faster to verify than to
compute
Sorting an array
Computing an algebraic number
Solving a SAT problem
Solving an NP-hard problem
The challenges are
Convert programs for the blockchain into an fast off-chain
computation and a slow on-chain verification.
Transforming the blockchain VM into the minimal language
that allows verifying the properties of the programs we are
interested in
15 / 19
Languages
The best language to describe the business logic in a
smart-contract depends on what you believe a smart-contract
should be and who is going to write it.
Ethereum Tezos
Universal distributed computer Automate simple (legal) contracts
Written in JavaScript / Python Written in DSLs
By any developer By specialized developers
The challenges are
Ensure contract semantics correspond to user expectation
Prove contract-specific properties
Certify their compilation end-to-end
Design DSLs for specific contract types
16 / 19
Cryptography
Financial-system grade security is supported by cryptography
Certified cryptographic primitives (HACL in F*)
Signed messages
Zero-knowledge proofs
Anonymous transactions
Interoperability with other systems
17 / 19
Zero-knowledge proofs
Zero-knowledge proofs allow proving that a given computation was
performed, without disclosing the details of the computation
A problem mathematically equivalent to the initial one, whose
solution can be verified but doesn’t allow easily going back to
the original problem (e.g. mapping into SAT)
Current state-of-the-art zk-SNARKs and zk-STARKs
Allows interoperation of existing systems with the blockchain
because existing systems can generate a proof the operations
they performed were properly done without revealing details.
Proof can be checked by blockchain before synchronizing
accounts.
18 / 19
Zero-knowledge proofs
The challenges are
End-to-end certified zero-knowledge proofs
zk-STARKs and zk-SNARKs use complex computer algebra
running on clusters of computers
Domain-specific zero-knowledge proofs
zk-STARKs and zk-SNARKs are generic and very complex
Can domain specific zero-knowledge proof be simpler ?
19 / 19

More Related Content

Similar to Challenges in blockchain certification (Nov 19, 2018 for TPP2018)

Javascript toolset for Ethereum Smart Contract development
Javascript toolset for Ethereum Smart Contract developmentJavascript toolset for Ethereum Smart Contract development
Javascript toolset for Ethereum Smart Contract developmentBugSense
 
02 - Introduction to Hyperledger Fabric
02 - Introduction to Hyperledger Fabric  02 - Introduction to Hyperledger Fabric
02 - Introduction to Hyperledger Fabric Merlec Mpyana
 
tezos_hands-on-training.pdf
tezos_hands-on-training.pdftezos_hands-on-training.pdf
tezos_hands-on-training.pdfNeven6
 
Encode x Tezos Hack: Hands-on dApp Training
Encode x Tezos Hack: Hands-on dApp Training Encode x Tezos Hack: Hands-on dApp Training
Encode x Tezos Hack: Hands-on dApp Training KlaraOrban
 
Network Reference Model (Computer Networks) - Cybernetics Robo Academy
Network Reference Model  (Computer Networks) - Cybernetics Robo AcademyNetwork Reference Model  (Computer Networks) - Cybernetics Robo Academy
Network Reference Model (Computer Networks) - Cybernetics Robo AcademyTutulAhmed3
 
Cryptocurrency News Digest - Smart contract platforms – A Beginner's Guide on...
Cryptocurrency News Digest - Smart contract platforms – A Beginner's Guide on...Cryptocurrency News Digest - Smart contract platforms – A Beginner's Guide on...
Cryptocurrency News Digest - Smart contract platforms – A Beginner's Guide on...Crypto in California
 
DEF CON 27 - DANIEL ROMERO and MARIO RIVAS - why you should fear your mundane...
DEF CON 27 - DANIEL ROMERO and MARIO RIVAS - why you should fear your mundane...DEF CON 27 - DANIEL ROMERO and MARIO RIVAS - why you should fear your mundane...
DEF CON 27 - DANIEL ROMERO and MARIO RIVAS - why you should fear your mundane...Felipe Prado
 
Web Technology Management Lecture II
Web Technology Management Lecture IIWeb Technology Management Lecture II
Web Technology Management Lecture IIsopekmir
 
P4_tutorial.pdf
P4_tutorial.pdfP4_tutorial.pdf
P4_tutorial.pdfPramodhN3
 
Addressing New Challenges in Software Protection for .NET
Addressing New Challenges in Software Protection for .NETAddressing New Challenges in Software Protection for .NET
Addressing New Challenges in Software Protection for .NETLicensingLive! - SafeNet
 
The Decentralized Developer Toolbox by Petros Ring
The Decentralized Developer Toolbox by Petros RingThe Decentralized Developer Toolbox by Petros Ring
The Decentralized Developer Toolbox by Petros RingBlock 16
 
A Survey Report on DDOS Attacking Tools, Detection and Prevention Mechanisms
A Survey Report on DDOS Attacking Tools, Detection and Prevention MechanismsA Survey Report on DDOS Attacking Tools, Detection and Prevention Mechanisms
A Survey Report on DDOS Attacking Tools, Detection and Prevention MechanismsIRJET Journal
 
DEFCON 23 Why Nation-State Malwares Target Telco Networks - OMER COSKUN
DEFCON 23 Why Nation-State Malwares Target Telco Networks - OMER COSKUNDEFCON 23 Why Nation-State Malwares Target Telco Networks - OMER COSKUN
DEFCON 23 Why Nation-State Malwares Target Telco Networks - OMER COSKUNÖmer Coşkun
 
Defcon23 why nation-state_malware_target_telco_omercoskun
Defcon23 why nation-state_malware_target_telco_omercoskunDefcon23 why nation-state_malware_target_telco_omercoskun
Defcon23 why nation-state_malware_target_telco_omercoskunÖmer Coşkun
 
Chapter 5 introduction to computer communication networks
Chapter 5   introduction to computer communication networksChapter 5   introduction to computer communication networks
Chapter 5 introduction to computer communication networksN. A. Sutisna
 
[Call for code] IBM 블록체인을 활용하여 투명하게 구호기금 관리하기 - Hyperledger Fabric v1.1 by 맹개발
[Call for code] IBM 블록체인을 활용하여 투명하게 구호기금 관리하기 - Hyperledger Fabric v1.1 by 맹개발 [Call for code] IBM 블록체인을 활용하여 투명하게 구호기금 관리하기 - Hyperledger Fabric v1.1 by 맹개발
[Call for code] IBM 블록체인을 활용하여 투명하게 구호기금 관리하기 - Hyperledger Fabric v1.1 by 맹개발 Yunho Maeng
 
Towards a Design Philosophy for Interoperable Blockchain Systems
Towards a Design Philosophy for Interoperable Blockchain SystemsTowards a Design Philosophy for Interoperable Blockchain Systems
Towards a Design Philosophy for Interoperable Blockchain Systemseraser Juan José Calderón
 
Ethereum Block Chain
Ethereum Block ChainEthereum Block Chain
Ethereum Block ChainSanatPandoh
 

Similar to Challenges in blockchain certification (Nov 19, 2018 for TPP2018) (20)

Javascript toolset for Ethereum Smart Contract development
Javascript toolset for Ethereum Smart Contract developmentJavascript toolset for Ethereum Smart Contract development
Javascript toolset for Ethereum Smart Contract development
 
02 - Introduction to Hyperledger Fabric
02 - Introduction to Hyperledger Fabric  02 - Introduction to Hyperledger Fabric
02 - Introduction to Hyperledger Fabric
 
tezos_hands-on-training.pdf
tezos_hands-on-training.pdftezos_hands-on-training.pdf
tezos_hands-on-training.pdf
 
Encode x Tezos Hack: Hands-on dApp Training
Encode x Tezos Hack: Hands-on dApp Training Encode x Tezos Hack: Hands-on dApp Training
Encode x Tezos Hack: Hands-on dApp Training
 
Network Reference Model (Computer Networks) - Cybernetics Robo Academy
Network Reference Model  (Computer Networks) - Cybernetics Robo AcademyNetwork Reference Model  (Computer Networks) - Cybernetics Robo Academy
Network Reference Model (Computer Networks) - Cybernetics Robo Academy
 
Cryptocurrency News Digest - Smart contract platforms – A Beginner's Guide on...
Cryptocurrency News Digest - Smart contract platforms – A Beginner's Guide on...Cryptocurrency News Digest - Smart contract platforms – A Beginner's Guide on...
Cryptocurrency News Digest - Smart contract platforms – A Beginner's Guide on...
 
DEF CON 27 - DANIEL ROMERO and MARIO RIVAS - why you should fear your mundane...
DEF CON 27 - DANIEL ROMERO and MARIO RIVAS - why you should fear your mundane...DEF CON 27 - DANIEL ROMERO and MARIO RIVAS - why you should fear your mundane...
DEF CON 27 - DANIEL ROMERO and MARIO RIVAS - why you should fear your mundane...
 
Web Technology Management Lecture II
Web Technology Management Lecture IIWeb Technology Management Lecture II
Web Technology Management Lecture II
 
P4_tutorial.pdf
P4_tutorial.pdfP4_tutorial.pdf
P4_tutorial.pdf
 
Addressing New Challenges in Software Protection for .NET
Addressing New Challenges in Software Protection for .NETAddressing New Challenges in Software Protection for .NET
Addressing New Challenges in Software Protection for .NET
 
The Decentralized Developer Toolbox by Petros Ring
The Decentralized Developer Toolbox by Petros RingThe Decentralized Developer Toolbox by Petros Ring
The Decentralized Developer Toolbox by Petros Ring
 
All About Ethereum
All About EthereumAll About Ethereum
All About Ethereum
 
A Survey Report on DDOS Attacking Tools, Detection and Prevention Mechanisms
A Survey Report on DDOS Attacking Tools, Detection and Prevention MechanismsA Survey Report on DDOS Attacking Tools, Detection and Prevention Mechanisms
A Survey Report on DDOS Attacking Tools, Detection and Prevention Mechanisms
 
DEFCON 23 Why Nation-State Malwares Target Telco Networks - OMER COSKUN
DEFCON 23 Why Nation-State Malwares Target Telco Networks - OMER COSKUNDEFCON 23 Why Nation-State Malwares Target Telco Networks - OMER COSKUN
DEFCON 23 Why Nation-State Malwares Target Telco Networks - OMER COSKUN
 
Defcon23 why nation-state_malware_target_telco_omercoskun
Defcon23 why nation-state_malware_target_telco_omercoskunDefcon23 why nation-state_malware_target_telco_omercoskun
Defcon23 why nation-state_malware_target_telco_omercoskun
 
Chapter 5 introduction to computer communication networks
Chapter 5   introduction to computer communication networksChapter 5   introduction to computer communication networks
Chapter 5 introduction to computer communication networks
 
.Netframework
.Netframework.Netframework
.Netframework
 
[Call for code] IBM 블록체인을 활용하여 투명하게 구호기금 관리하기 - Hyperledger Fabric v1.1 by 맹개발
[Call for code] IBM 블록체인을 활용하여 투명하게 구호기금 관리하기 - Hyperledger Fabric v1.1 by 맹개발 [Call for code] IBM 블록체인을 활용하여 투명하게 구호기금 관리하기 - Hyperledger Fabric v1.1 by 맹개발
[Call for code] IBM 블록체인을 활용하여 투명하게 구호기금 관리하기 - Hyperledger Fabric v1.1 by 맹개발
 
Towards a Design Philosophy for Interoperable Blockchain Systems
Towards a Design Philosophy for Interoperable Blockchain SystemsTowards a Design Philosophy for Interoperable Blockchain Systems
Towards a Design Philosophy for Interoperable Blockchain Systems
 
Ethereum Block Chain
Ethereum Block ChainEthereum Block Chain
Ethereum Block Chain
 

More from Jun Furuse

Tezos 008 Edo protocol
Tezos 008 Edo protocolTezos 008 Edo protocol
Tezos 008 Edo protocolJun Furuse
 
Plebeia, a new storage for Tezos blockchain state
Plebeia, a new storage for Tezos blockchain statePlebeia, a new storage for Tezos blockchain state
Plebeia, a new storage for Tezos blockchain stateJun Furuse
 
SCaml update 2020-06
SCaml update 2020-06SCaml update 2020-06
SCaml update 2020-06Jun Furuse
 
Tezso and on-chain governanace: towards "Kyoto amendment"
Tezso  and on-chain governanace: towards "Kyoto amendment"Tezso  and on-chain governanace: towards "Kyoto amendment"
Tezso and on-chain governanace: towards "Kyoto amendment"Jun Furuse
 
Comparison of Proof of Stakes
Comparison of Proof of StakesComparison of Proof of Stakes
Comparison of Proof of StakesJun Furuse
 
SCaml compiler
SCaml compilerSCaml compiler
SCaml compilerJun Furuse
 
SCaml compiler
SCaml compilerSCaml compiler
SCaml compilerJun Furuse
 
Blockchain and Smart Contract Simulation
Blockchain and Smart Contract SimulationBlockchain and Smart Contract Simulation
Blockchain and Smart Contract SimulationJun Furuse
 
Blockchain and formal verification (Japanese)
Blockchain and formal verification (Japanese)Blockchain and formal verification (Japanese)
Blockchain and formal verification (Japanese)Jun Furuse
 
Blockchain and Formal verification (English)
Blockchain and Formal verification (English)Blockchain and Formal verification (English)
Blockchain and Formal verification (English)Jun Furuse
 
Tezos Hands on 2019-06-15 Exercise (Japanese)
Tezos Hands on 2019-06-15 Exercise (Japanese)Tezos Hands on 2019-06-15 Exercise (Japanese)
Tezos Hands on 2019-06-15 Exercise (Japanese)Jun Furuse
 
Tezos Hands on 2019-06-15 (Japanese)
Tezos Hands on 2019-06-15 (Japanese)Tezos Hands on 2019-06-15 (Japanese)
Tezos Hands on 2019-06-15 (Japanese)Jun Furuse
 
Tezos and its formal verification (Japanese)
Tezos and its formal verification (Japanese)Tezos and its formal verification (Japanese)
Tezos and its formal verification (Japanese)Jun Furuse
 
Tezos hands-on : Tezos exercise
Tezos hands-on : Tezos exerciseTezos hands-on : Tezos exercise
Tezos hands-on : Tezos exerciseJun Furuse
 
Tezos hands-on : Tezos overview
Tezos hands-on : Tezos overviewTezos hands-on : Tezos overview
Tezos hands-on : Tezos overviewJun Furuse
 
Tezos: Self-amending crypt ledger (Japanese)
Tezos: Self-amending crypt ledger (Japanese)Tezos: Self-amending crypt ledger (Japanese)
Tezos: Self-amending crypt ledger (Japanese)Jun Furuse
 
ブロックチェーンと形式検証
ブロックチェーンと形式検証ブロックチェーンと形式検証
ブロックチェーンと形式検証Jun Furuse
 
Recent tezos core developments
Recent tezos core developmentsRecent tezos core developments
Recent tezos core developmentsJun Furuse
 
OCamlOScope: a New OCaml API Search
OCamlOScope: a New OCaml API SearchOCamlOScope: a New OCaml API Search
OCamlOScope: a New OCaml API SearchJun Furuse
 

More from Jun Furuse (20)

Tezos 008 Edo protocol
Tezos 008 Edo protocolTezos 008 Edo protocol
Tezos 008 Edo protocol
 
Plebeia, a new storage for Tezos blockchain state
Plebeia, a new storage for Tezos blockchain statePlebeia, a new storage for Tezos blockchain state
Plebeia, a new storage for Tezos blockchain state
 
SCaml update 2020-06
SCaml update 2020-06SCaml update 2020-06
SCaml update 2020-06
 
Tezso and on-chain governanace: towards "Kyoto amendment"
Tezso  and on-chain governanace: towards "Kyoto amendment"Tezso  and on-chain governanace: towards "Kyoto amendment"
Tezso and on-chain governanace: towards "Kyoto amendment"
 
Comparison of Proof of Stakes
Comparison of Proof of StakesComparison of Proof of Stakes
Comparison of Proof of Stakes
 
SCaml compiler
SCaml compilerSCaml compiler
SCaml compiler
 
SCaml compiler
SCaml compilerSCaml compiler
SCaml compiler
 
Blockchain and Smart Contract Simulation
Blockchain and Smart Contract SimulationBlockchain and Smart Contract Simulation
Blockchain and Smart Contract Simulation
 
Blockchain and formal verification (Japanese)
Blockchain and formal verification (Japanese)Blockchain and formal verification (Japanese)
Blockchain and formal verification (Japanese)
 
Blockchain and Formal verification (English)
Blockchain and Formal verification (English)Blockchain and Formal verification (English)
Blockchain and Formal verification (English)
 
Tezos Hands on 2019-06-15 Exercise (Japanese)
Tezos Hands on 2019-06-15 Exercise (Japanese)Tezos Hands on 2019-06-15 Exercise (Japanese)
Tezos Hands on 2019-06-15 Exercise (Japanese)
 
Tezos Hands on 2019-06-15 (Japanese)
Tezos Hands on 2019-06-15 (Japanese)Tezos Hands on 2019-06-15 (Japanese)
Tezos Hands on 2019-06-15 (Japanese)
 
Tezos and its formal verification (Japanese)
Tezos and its formal verification (Japanese)Tezos and its formal verification (Japanese)
Tezos and its formal verification (Japanese)
 
Tezos hands-on : Tezos exercise
Tezos hands-on : Tezos exerciseTezos hands-on : Tezos exercise
Tezos hands-on : Tezos exercise
 
Tezos hands-on : Tezos overview
Tezos hands-on : Tezos overviewTezos hands-on : Tezos overview
Tezos hands-on : Tezos overview
 
Tezos: Self-amending crypt ledger (Japanese)
Tezos: Self-amending crypt ledger (Japanese)Tezos: Self-amending crypt ledger (Japanese)
Tezos: Self-amending crypt ledger (Japanese)
 
ブロックチェーンと形式検証
ブロックチェーンと形式検証ブロックチェーンと形式検証
ブロックチェーンと形式検証
 
Recent tezos core developments
Recent tezos core developmentsRecent tezos core developments
Recent tezos core developments
 
OCamlOScope: a New OCaml API Search
OCamlOScope: a New OCaml API SearchOCamlOScope: a New OCaml API Search
OCamlOScope: a New OCaml API Search
 
Um2010
Um2010Um2010
Um2010
 

Recently uploaded

Harmful and Useful Microorganisms Presentation
Harmful and Useful Microorganisms PresentationHarmful and Useful Microorganisms Presentation
Harmful and Useful Microorganisms Presentationtahreemzahra82
 
Artificial Intelligence In Microbiology by Dr. Prince C P
Artificial Intelligence In Microbiology by Dr. Prince C PArtificial Intelligence In Microbiology by Dr. Prince C P
Artificial Intelligence In Microbiology by Dr. Prince C PPRINCE C P
 
Spermiogenesis or Spermateleosis or metamorphosis of spermatid
Spermiogenesis or Spermateleosis or metamorphosis of spermatidSpermiogenesis or Spermateleosis or metamorphosis of spermatid
Spermiogenesis or Spermateleosis or metamorphosis of spermatidSarthak Sekhar Mondal
 
Is RISC-V ready for HPC workload? Maybe?
Is RISC-V ready for HPC workload? Maybe?Is RISC-V ready for HPC workload? Maybe?
Is RISC-V ready for HPC workload? Maybe?Patrick Diehl
 
Bentham & Hooker's Classification. along with the merits and demerits of the ...
Bentham & Hooker's Classification. along with the merits and demerits of the ...Bentham & Hooker's Classification. along with the merits and demerits of the ...
Bentham & Hooker's Classification. along with the merits and demerits of the ...Nistarini College, Purulia (W.B) India
 
Neurodevelopmental disorders according to the dsm 5 tr
Neurodevelopmental disorders according to the dsm 5 trNeurodevelopmental disorders according to the dsm 5 tr
Neurodevelopmental disorders according to the dsm 5 trssuser06f238
 
Welcome to GFDL for Take Your Child To Work Day
Welcome to GFDL for Take Your Child To Work DayWelcome to GFDL for Take Your Child To Work Day
Welcome to GFDL for Take Your Child To Work DayZachary Labe
 
Twin's paradox experiment is a meassurement of the extra dimensions.pptx
Twin's paradox experiment is a meassurement of the extra dimensions.pptxTwin's paradox experiment is a meassurement of the extra dimensions.pptx
Twin's paradox experiment is a meassurement of the extra dimensions.pptxEran Akiva Sinbar
 
Grafana in space: Monitoring Japan's SLIM moon lander in real time
Grafana in space: Monitoring Japan's SLIM moon lander  in real timeGrafana in space: Monitoring Japan's SLIM moon lander  in real time
Grafana in space: Monitoring Japan's SLIM moon lander in real timeSatoshi NAKAHIRA
 
Call Us ≽ 9953322196 ≼ Call Girls In Mukherjee Nagar(Delhi) |
Call Us ≽ 9953322196 ≼ Call Girls In Mukherjee Nagar(Delhi) |Call Us ≽ 9953322196 ≼ Call Girls In Mukherjee Nagar(Delhi) |
Call Us ≽ 9953322196 ≼ Call Girls In Mukherjee Nagar(Delhi) |aasikanpl
 
Call Girls In Nihal Vihar Delhi ❤️8860477959 Looking Escorts In 24/7 Delhi NCR
Call Girls In Nihal Vihar Delhi ❤️8860477959 Looking Escorts In 24/7 Delhi NCRCall Girls In Nihal Vihar Delhi ❤️8860477959 Looking Escorts In 24/7 Delhi NCR
Call Girls In Nihal Vihar Delhi ❤️8860477959 Looking Escorts In 24/7 Delhi NCRlizamodels9
 
LIGHT-PHENOMENA-BY-CABUALDIONALDOPANOGANCADIENTE-CONDEZA (1).pptx
LIGHT-PHENOMENA-BY-CABUALDIONALDOPANOGANCADIENTE-CONDEZA (1).pptxLIGHT-PHENOMENA-BY-CABUALDIONALDOPANOGANCADIENTE-CONDEZA (1).pptx
LIGHT-PHENOMENA-BY-CABUALDIONALDOPANOGANCADIENTE-CONDEZA (1).pptxmalonesandreagweneth
 
Solution chemistry, Moral and Normal solutions
Solution chemistry, Moral and Normal solutionsSolution chemistry, Moral and Normal solutions
Solution chemistry, Moral and Normal solutionsHajira Mahmood
 
zoogeography of pakistan.pptx fauna of Pakistan
zoogeography of pakistan.pptx fauna of Pakistanzoogeography of pakistan.pptx fauna of Pakistan
zoogeography of pakistan.pptx fauna of Pakistanzohaibmir069
 
Behavioral Disorder: Schizophrenia & it's Case Study.pdf
Behavioral Disorder: Schizophrenia & it's Case Study.pdfBehavioral Disorder: Schizophrenia & it's Case Study.pdf
Behavioral Disorder: Schizophrenia & it's Case Study.pdfSELF-EXPLANATORY
 
THE ROLE OF PHARMACOGNOSY IN TRADITIONAL AND MODERN SYSTEM OF MEDICINE.pptx
THE ROLE OF PHARMACOGNOSY IN TRADITIONAL AND MODERN SYSTEM OF MEDICINE.pptxTHE ROLE OF PHARMACOGNOSY IN TRADITIONAL AND MODERN SYSTEM OF MEDICINE.pptx
THE ROLE OF PHARMACOGNOSY IN TRADITIONAL AND MODERN SYSTEM OF MEDICINE.pptxNandakishor Bhaurao Deshmukh
 
Speech, hearing, noise, intelligibility.pptx
Speech, hearing, noise, intelligibility.pptxSpeech, hearing, noise, intelligibility.pptx
Speech, hearing, noise, intelligibility.pptxpriyankatabhane
 
Call Girls in Munirka Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Munirka Delhi 💯Call Us 🔝8264348440🔝Call Girls in Munirka Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Munirka Delhi 💯Call Us 🔝8264348440🔝soniya singh
 
TOPIC 8 Temperature and Heat.pdf physics
TOPIC 8 Temperature and Heat.pdf physicsTOPIC 8 Temperature and Heat.pdf physics
TOPIC 8 Temperature and Heat.pdf physicsssuserddc89b
 

Recently uploaded (20)

Harmful and Useful Microorganisms Presentation
Harmful and Useful Microorganisms PresentationHarmful and Useful Microorganisms Presentation
Harmful and Useful Microorganisms Presentation
 
Artificial Intelligence In Microbiology by Dr. Prince C P
Artificial Intelligence In Microbiology by Dr. Prince C PArtificial Intelligence In Microbiology by Dr. Prince C P
Artificial Intelligence In Microbiology by Dr. Prince C P
 
Spermiogenesis or Spermateleosis or metamorphosis of spermatid
Spermiogenesis or Spermateleosis or metamorphosis of spermatidSpermiogenesis or Spermateleosis or metamorphosis of spermatid
Spermiogenesis or Spermateleosis or metamorphosis of spermatid
 
Is RISC-V ready for HPC workload? Maybe?
Is RISC-V ready for HPC workload? Maybe?Is RISC-V ready for HPC workload? Maybe?
Is RISC-V ready for HPC workload? Maybe?
 
Bentham & Hooker's Classification. along with the merits and demerits of the ...
Bentham & Hooker's Classification. along with the merits and demerits of the ...Bentham & Hooker's Classification. along with the merits and demerits of the ...
Bentham & Hooker's Classification. along with the merits and demerits of the ...
 
Neurodevelopmental disorders according to the dsm 5 tr
Neurodevelopmental disorders according to the dsm 5 trNeurodevelopmental disorders according to the dsm 5 tr
Neurodevelopmental disorders according to the dsm 5 tr
 
Welcome to GFDL for Take Your Child To Work Day
Welcome to GFDL for Take Your Child To Work DayWelcome to GFDL for Take Your Child To Work Day
Welcome to GFDL for Take Your Child To Work Day
 
Twin's paradox experiment is a meassurement of the extra dimensions.pptx
Twin's paradox experiment is a meassurement of the extra dimensions.pptxTwin's paradox experiment is a meassurement of the extra dimensions.pptx
Twin's paradox experiment is a meassurement of the extra dimensions.pptx
 
Grafana in space: Monitoring Japan's SLIM moon lander in real time
Grafana in space: Monitoring Japan's SLIM moon lander  in real timeGrafana in space: Monitoring Japan's SLIM moon lander  in real time
Grafana in space: Monitoring Japan's SLIM moon lander in real time
 
Call Us ≽ 9953322196 ≼ Call Girls In Mukherjee Nagar(Delhi) |
Call Us ≽ 9953322196 ≼ Call Girls In Mukherjee Nagar(Delhi) |Call Us ≽ 9953322196 ≼ Call Girls In Mukherjee Nagar(Delhi) |
Call Us ≽ 9953322196 ≼ Call Girls In Mukherjee Nagar(Delhi) |
 
Call Girls In Nihal Vihar Delhi ❤️8860477959 Looking Escorts In 24/7 Delhi NCR
Call Girls In Nihal Vihar Delhi ❤️8860477959 Looking Escorts In 24/7 Delhi NCRCall Girls In Nihal Vihar Delhi ❤️8860477959 Looking Escorts In 24/7 Delhi NCR
Call Girls In Nihal Vihar Delhi ❤️8860477959 Looking Escorts In 24/7 Delhi NCR
 
LIGHT-PHENOMENA-BY-CABUALDIONALDOPANOGANCADIENTE-CONDEZA (1).pptx
LIGHT-PHENOMENA-BY-CABUALDIONALDOPANOGANCADIENTE-CONDEZA (1).pptxLIGHT-PHENOMENA-BY-CABUALDIONALDOPANOGANCADIENTE-CONDEZA (1).pptx
LIGHT-PHENOMENA-BY-CABUALDIONALDOPANOGANCADIENTE-CONDEZA (1).pptx
 
Hot Sexy call girls in Moti Nagar,🔝 9953056974 🔝 escort Service
Hot Sexy call girls in  Moti Nagar,🔝 9953056974 🔝 escort ServiceHot Sexy call girls in  Moti Nagar,🔝 9953056974 🔝 escort Service
Hot Sexy call girls in Moti Nagar,🔝 9953056974 🔝 escort Service
 
Solution chemistry, Moral and Normal solutions
Solution chemistry, Moral and Normal solutionsSolution chemistry, Moral and Normal solutions
Solution chemistry, Moral and Normal solutions
 
zoogeography of pakistan.pptx fauna of Pakistan
zoogeography of pakistan.pptx fauna of Pakistanzoogeography of pakistan.pptx fauna of Pakistan
zoogeography of pakistan.pptx fauna of Pakistan
 
Behavioral Disorder: Schizophrenia & it's Case Study.pdf
Behavioral Disorder: Schizophrenia & it's Case Study.pdfBehavioral Disorder: Schizophrenia & it's Case Study.pdf
Behavioral Disorder: Schizophrenia & it's Case Study.pdf
 
THE ROLE OF PHARMACOGNOSY IN TRADITIONAL AND MODERN SYSTEM OF MEDICINE.pptx
THE ROLE OF PHARMACOGNOSY IN TRADITIONAL AND MODERN SYSTEM OF MEDICINE.pptxTHE ROLE OF PHARMACOGNOSY IN TRADITIONAL AND MODERN SYSTEM OF MEDICINE.pptx
THE ROLE OF PHARMACOGNOSY IN TRADITIONAL AND MODERN SYSTEM OF MEDICINE.pptx
 
Speech, hearing, noise, intelligibility.pptx
Speech, hearing, noise, intelligibility.pptxSpeech, hearing, noise, intelligibility.pptx
Speech, hearing, noise, intelligibility.pptx
 
Call Girls in Munirka Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Munirka Delhi 💯Call Us 🔝8264348440🔝Call Girls in Munirka Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Munirka Delhi 💯Call Us 🔝8264348440🔝
 
TOPIC 8 Temperature and Heat.pdf physics
TOPIC 8 Temperature and Heat.pdf physicsTOPIC 8 Temperature and Heat.pdf physics
TOPIC 8 Temperature and Heat.pdf physics
 

Challenges in blockchain certification (Nov 19, 2018 for TPP2018)

  • 1. ꜩꜩChallenges in blockchain certification Diego Olivier Fernandez Pons Tezos Southeast Asia (Singapore) diego@tezos.org.sg November 19, 2018 1 / 19
  • 2. Tezos seen from the application side Tezos network Tezos node Smart Contracts functions / stored procedures Desktop or Web application Language independent Remote Procedure Call JSON over HTTP For the application developer, a blockchain like Tezos is a webservice with functions to be called via a web API. 2 / 19
  • 3. Tezos seen from the core developer side P2P layer Distributed computation Distributed database Virtual machine Contracts Languages x = f (3) x = f (4) Safe and fast computation of f Validation that the business logic of f is correct Expression of business logic of f write x = 3 or x = 4 ? f(4) -> 4f(3) -> 3 For the core developer, Tezos is a very complex piece of software. 3 / 19
  • 4. Challenges in the P2P layer Communication protocols are difficult to code Error prone code : the Tezos network was down for a couple of hours because of messages with nothing but 0 were sent Attacks : The system needs to be protected against impersonation, message deletion and DDoS Optimization : Protocols need to be optimized for the type of messages that are sent to reduce bandwith The challenge is to automatically generate optimized code from a specification proven correct. 4 / 19
  • 5. Distributed computation Compute at the entry points and broadcast the results ? f (3) f (4) x = f (3) x = f (4) 5 / 19
  • 6. Distributed computation Broadcast the function calls, elect a leader to compute and broadcast the results ? f (3) f (4) f (3) f (4) f (3) f (4) f (3) f (4) f (3) f (4) f (3) f (4) f (3) f (4) x = f (3) x = f (4) 6 / 19
  • 7. Distributed computation Broadcast the function calls and compute on every node ? f (3) f (4) f (3) f (4) f (3) f (4) f (3) f (4) f (3) f (4) f (3) f (4) f (3) f (4) x = f (3) x = f (4) 7 / 19
  • 8. Distributed computation Challenges of distributed computations Understand the consequences of each algorithm on the system (liveness, latency, etc) Formally prove the properties of the algorithms and their variants Automatically generate the code and its dependencies with other layers (e.g. P2P layer for information broadcast) from a specification 8 / 19
  • 9. Distributed database The state of the database needs to be consistent across all nodes : one of the transactions (x = 3 or x = 4) need to be discarded. The consensus algorithm makes sure that the network converges on a single value. x = 3 x = 4 ? 9 / 19
  • 10. Distributed database Some results about consensus algorithms Consensus in fault-tolerant distributed networks is impossible [FLP 85] ⇒ Consensus ”algorithms” may not terminate. Crash and hack-tolerance ⇒ nodes need to ”vote” and use some form of majority rule to reach consensus Paxos [Lamport 90] works well for closed networks : flexible, variants for crash and hack tolerance, formally verified Open networks are subject to sybil attacks : the majority rule can be tricked by creating fake nodes controlled by an attacker Nakamoto idea [2008]: in open networks, replace majority rule by majority of computing power rule Participating to the network consensus costs money (computing power to create the data to be agreed upon) Reaching consensus is rewarded with money (coins directly in the data to be agreed upon) 10 / 19
  • 11. Distributed database Nakamoto conjecture Consensus algorithm in an open network ⇒ internal currency We wanted a consensus algorithm for an open distributed database. We ended with a currency and all the problems that go with it All the hackers of the world will try to attack the system All the speculators of the world will try to speculate on the system coin The challenges are to understand distributed consensus algorithms, formally prove their properties and generate the corresponding code from a formal specification. 11 / 19
  • 12. Blockchains Blockchain Open distributed hack-tolerant databases with stored procedures are called blockchains. Until someone finds better consensus algorithms, replication of the database across the network requires an internal currency to reward nodes for reaching consensus. The challenges are Financial-systems grade security Design a consensus algorithm that doesn’t require creating a currency 12 / 19
  • 13. Virtual machine Poorly designed virtual machines are attack vectors for blockchains. EVM WASM Michelson 256 ints 32 / 64 ints Infinite precision ints No data structures No data structures Persistent sets, maps, lists Side effects Side effects No side effects Purpose made Standard Purpose made Ethereum Dfinity Tezos The challenge is to understand the semantics of programs in bytecode from unknown origin and prove properties about them, to allow users to verify the 3rd party program they are going to call does what it claims it does. 13 / 19
  • 14. Contracts Blockchains are per essence slow. As a result everything that can be computed off-chain should be done so. Bad Contract : x -> sqrt x App : () -> f 9 Good Contract : x y -> if x * x = y then x else fail App : () -> f (sqrt 9) 9 The better contract only checks a multiplication instead of computing a square root with Newton algorithm. 14 / 19
  • 15. Contracts There are many computations that are faster to verify than to compute Sorting an array Computing an algebraic number Solving a SAT problem Solving an NP-hard problem The challenges are Convert programs for the blockchain into an fast off-chain computation and a slow on-chain verification. Transforming the blockchain VM into the minimal language that allows verifying the properties of the programs we are interested in 15 / 19
  • 16. Languages The best language to describe the business logic in a smart-contract depends on what you believe a smart-contract should be and who is going to write it. Ethereum Tezos Universal distributed computer Automate simple (legal) contracts Written in JavaScript / Python Written in DSLs By any developer By specialized developers The challenges are Ensure contract semantics correspond to user expectation Prove contract-specific properties Certify their compilation end-to-end Design DSLs for specific contract types 16 / 19
  • 17. Cryptography Financial-system grade security is supported by cryptography Certified cryptographic primitives (HACL in F*) Signed messages Zero-knowledge proofs Anonymous transactions Interoperability with other systems 17 / 19
  • 18. Zero-knowledge proofs Zero-knowledge proofs allow proving that a given computation was performed, without disclosing the details of the computation A problem mathematically equivalent to the initial one, whose solution can be verified but doesn’t allow easily going back to the original problem (e.g. mapping into SAT) Current state-of-the-art zk-SNARKs and zk-STARKs Allows interoperation of existing systems with the blockchain because existing systems can generate a proof the operations they performed were properly done without revealing details. Proof can be checked by blockchain before synchronizing accounts. 18 / 19
  • 19. Zero-knowledge proofs The challenges are End-to-end certified zero-knowledge proofs zk-STARKs and zk-SNARKs use complex computer algebra running on clusters of computers Domain-specific zero-knowledge proofs zk-STARKs and zk-SNARKs are generic and very complex Can domain specific zero-knowledge proof be simpler ? 19 / 19