SlideShare a Scribd company logo
1 of 17
Download to read offline
Have Your Cake and Eat it too
Matthijs van den Bos
Both Privacy + Security with Zero Knowledge Notarisation in Corda
CordaCon 2019, London
Is there a problem?
In Corda:
Validating notaries get to see
everything
We want to share our
transaction details on a
need-to-know basis only.
What can we do right now?
Use a non-validating Notary
and/or
Confidential identities, etc.
These either solve it partially,
or introduce new issues.
We prefer to have our cake and eat it too!
Non-validating Notary: denial-of-state attack
Does NOT validate:
Smart contract rules, or signatures
DOES check if inputs are already
consumed
Attackers can consume any
unspent state they know ref of,
no matter who owns it.
Real owner will be denied use of the state for ever.
Do you want
to run this
risk?
So there is a trade-off
We want to share our transaction details on a
need-to-know basis only.
Trade-off:
non-validating: denial-of-state risk
validating: privacy
So can we have our cake
and eat it too?
Privacy Security
Solution 1: Ignore!
Pro: it's what we do now
Con: If you close your eyes and don’t
see a problem, a problem still sees you
Solution 2: Lawyer up!
Pro: will fix situation eventually
Con: resolution might not be fast
Con: during investigation you will
have to reveal everything
Con: (centralized) arbitration
needed
Con: undefined how to 'revert'
transactions
Solution 3: Trusted Hardware (SGX)
Pro: solves everything!
Con: vendor lock-in
Con: more complex development
Fact: need to trust vendor (current
security issues, backdoors)
Solution 4: ZKP (no knowledge - no problem)
Pro: solves everything as well
Con: also more complex development
Fact: need to trust global scientific
community
Extra bonus: verifier scalability
Non-validating Notary as base. Same privacy, same
checks.
Initiator creates a zero-knowledge proof that:
• for the id of the tx we want to verify,
• they know a matching tx data structure
• that satisfies the smart contract rules
• and that they know the matching signatures
The Notary verifies this proof and is convinced of these
facts.
This prevents Denial of State attack: attacker can no
longer spend a state that they do not own.
Zero-Knowledge Notarisation: Overview
/*
* Initiator ZK Notarisation flow
*/
ZKNotaryFlow.Client(SignedTx) {
// The tx we want notarised
val ftx = buildFilteredTx()
// Create proof that we know full tx + sigs
val proof = ZKProof(LedgerTx, sigs)
// Build ZK transaction
val zktx = ZKTx(ftx, proof)
val notarySig = notarise(zktx)
}
Custom Corda Notary + flows
/*
* Custom ZK Notary
*/
ZKNotaryServiceFlow {
// Normal checks
ftx.verify
// Verify ZKP
proof.verify(ftx.id)
signTxAndSend(ftx.id)
}
ZK Notarisation: the ZKP toolchain
Setup Once: Notary
1) Translates Corda smart
contract to C (manually at
the moment
😔
)
2) Compiles C code to
libsnark-compatible
R1CS using Pepper
3) Performs trusted setup
for libsnark (spoiler: it’s no
problem!)
4) Distributes prover key
Proving: Tx Initiator
1) From Corda, generates a
proof for tx with libsnark
using prover key, with tx
id as public input and
transaction data and
signatures as secret
input.
Secret input is a
serialised version of a full
LedgerTransaction
Verification: Notary
1) Verifies the proof with
libsnark using verifier
key, with only tx id as
input
Pseudo C contract
int prove(pub_tx_id, secret_tx_data) {
// Verify that the tx merkle root == tx.id
if (calculate_merkle_root(secret_tx_data) != pub_tx_id)
return 0;
// Example contract logic: only one input
if (get_input_count(secret_tx_data) != 1) return 0;
// More contract rules here
// Check required signatures
if (!required_sigs_present(secret_tx_data, pub_tx_id))
return 0;
return 1;
}
hash calculate_merkle_root(secret_tx_data) {
// multiple calls to SHA256 gadget
}
int required_sigs_present(secret_tx_data, pub_tx_id) {
// multiple calls to RSA signature verification gadget
}
Building a constraint system for contract code
is hard and error prone!
Either by hand, or using compiler like Pepper.
Prover performance:
Contract code will have to be simplified,
to prevent huge constraint systems.
You need hand crafted gadgets for heavy
computations. There are few, and interoperability is an
issue.
For wide adoption, this needs to be simplified.
All very nice, what's the catch?
NOT
Corda notarisation trade off: privacy vs. security.
We believe SGX and ZKP can be solutions.
Working on proof of concept for a Zero Knowledge Notary.
This provides both privacy AND security.
Next steps:
• Make more mature and performant
• Simplify toolchain:
• same contract code for non-zkp and zkp verification
• less ZKP tools
• Hopefully convince Corda team to incorporate it :-)
• More ZKP-friendly signature scheme in Corda
Yes, you can have your cake and eat it too!
Interested?
Want to help out?
Come talk to us!
Matthijs van den Bos
ING Bank | Distributed Ledger Technology Team
matthijs.van.den.bos@ing.com
Corda Slack: @mvdbos
Links:
• libsnark: https://github.com/scipr-lab/libsnark
• Pepper: https://github.com/pepper-project/pepper &
• Jsnark: https://github.com/akosba/jsnark
Contact details & links
Thank you!

More Related Content

What's hot

Hyperledger Fabric in a Nutshell
Hyperledger Fabric in a NutshellHyperledger Fabric in a Nutshell
Hyperledger Fabric in a NutshellDaniel Chan
 
Introduction to Corda Blockchain for Developers
Introduction to Corda Blockchain for DevelopersIntroduction to Corda Blockchain for Developers
Introduction to Corda Blockchain for DevelopersR3
 
Blockchain explained FIATA Congress 20180910
Blockchain explained FIATA Congress 20180910Blockchain explained FIATA Congress 20180910
Blockchain explained FIATA Congress 20180910Arnaud Le Hors
 
DevDay:Moving CorDapps from Pilot to Production, Dr. Duncan Wong
DevDay:Moving CorDapps from Pilot to Production, Dr. Duncan WongDevDay:Moving CorDapps from Pilot to Production, Dr. Duncan Wong
DevDay:Moving CorDapps from Pilot to Production, Dr. Duncan WongR3
 
DevDay: Integrating HQLAx on Corda into the Financial Markets Infrastructure,...
DevDay: Integrating HQLAx on Corda into the Financial Markets Infrastructure,...DevDay: Integrating HQLAx on Corda into the Financial Markets Infrastructure,...
DevDay: Integrating HQLAx on Corda into the Financial Markets Infrastructure,...R3
 
R3 Corda Simple Tutorial
R3 Corda Simple TutorialR3 Corda Simple Tutorial
R3 Corda Simple TutorialEric Lee
 
BizDay: Improving Remittances in the World's 2nd Largest Corridor, Digiledge
BizDay: Improving Remittances in the World's 2nd Largest Corridor, DigiledgeBizDay: Improving Remittances in the World's 2nd Largest Corridor, Digiledge
BizDay: Improving Remittances in the World's 2nd Largest Corridor, DigiledgeR3
 
Building Blockchain Application with Corda
Building Blockchain Application with CordaBuilding Blockchain Application with Corda
Building Blockchain Application with CordaMohammad Asif
 
Bitmark and Hyperledger Workshop: the Digital Assets and Property
Bitmark and Hyperledger Workshop: the Digital Assets and PropertyBitmark and Hyperledger Workshop: the Digital Assets and Property
Bitmark and Hyperledger Workshop: the Digital Assets and PropertyJollen Chen
 
Digital Assets and the Future of Capital Markets
Digital Assets and the Future of Capital MarketsDigital Assets and the Future of Capital Markets
Digital Assets and the Future of Capital MarketsR3
 
Hyperledger community update 20180528
Hyperledger community update 20180528Hyperledger community update 20180528
Hyperledger community update 20180528Arnaud Le Hors
 
Roles and skills of a corda architect a deep dive
Roles and skills of a corda architect  a deep diveRoles and skills of a corda architect  a deep dive
Roles and skills of a corda architect a deep diveBlockchain Council
 
Introducing r3 corda™ a distributed ledger designed for financial services
Introducing r3 corda™  a distributed ledger designed for financial servicesIntroducing r3 corda™  a distributed ledger designed for financial services
Introducing r3 corda™ a distributed ledger designed for financial servicesRazi Rais
 
Introduction of Hyperledger Fabric & Composer
Introduction of Hyperledger Fabric & Composer Introduction of Hyperledger Fabric & Composer
Introduction of Hyperledger Fabric & Composer Dr. Ketan Parmar
 
Defrag X Keynote: Deploying and managing Global Blockchain Network
Defrag X Keynote: Deploying and managing Global Blockchain NetworkDefrag X Keynote: Deploying and managing Global Blockchain Network
Defrag X Keynote: Deploying and managing Global Blockchain NetworkDuncan Johnston-Watt
 
Hyperledger fabric 20180528
Hyperledger fabric 20180528Hyperledger fabric 20180528
Hyperledger fabric 20180528Arnaud Le Hors
 
The Tokenization of Everything
The Tokenization of Everything The Tokenization of Everything
The Tokenization of Everything R3
 

What's hot (20)

What is corda
What is cordaWhat is corda
What is corda
 
Ethereum vs fabric vs corda
Ethereum vs fabric vs cordaEthereum vs fabric vs corda
Ethereum vs fabric vs corda
 
Hyperledger Fabric in a Nutshell
Hyperledger Fabric in a NutshellHyperledger Fabric in a Nutshell
Hyperledger Fabric in a Nutshell
 
Introduction to Corda Blockchain for Developers
Introduction to Corda Blockchain for DevelopersIntroduction to Corda Blockchain for Developers
Introduction to Corda Blockchain for Developers
 
Blockchain explained FIATA Congress 20180910
Blockchain explained FIATA Congress 20180910Blockchain explained FIATA Congress 20180910
Blockchain explained FIATA Congress 20180910
 
DevDay:Moving CorDapps from Pilot to Production, Dr. Duncan Wong
DevDay:Moving CorDapps from Pilot to Production, Dr. Duncan WongDevDay:Moving CorDapps from Pilot to Production, Dr. Duncan Wong
DevDay:Moving CorDapps from Pilot to Production, Dr. Duncan Wong
 
DevDay: Integrating HQLAx on Corda into the Financial Markets Infrastructure,...
DevDay: Integrating HQLAx on Corda into the Financial Markets Infrastructure,...DevDay: Integrating HQLAx on Corda into the Financial Markets Infrastructure,...
DevDay: Integrating HQLAx on Corda into the Financial Markets Infrastructure,...
 
R3 Corda Simple Tutorial
R3 Corda Simple TutorialR3 Corda Simple Tutorial
R3 Corda Simple Tutorial
 
BizDay: Improving Remittances in the World's 2nd Largest Corridor, Digiledge
BizDay: Improving Remittances in the World's 2nd Largest Corridor, DigiledgeBizDay: Improving Remittances in the World's 2nd Largest Corridor, Digiledge
BizDay: Improving Remittances in the World's 2nd Largest Corridor, Digiledge
 
Building Blockchain Application with Corda
Building Blockchain Application with CordaBuilding Blockchain Application with Corda
Building Blockchain Application with Corda
 
Bitmark and Hyperledger Workshop: the Digital Assets and Property
Bitmark and Hyperledger Workshop: the Digital Assets and PropertyBitmark and Hyperledger Workshop: the Digital Assets and Property
Bitmark and Hyperledger Workshop: the Digital Assets and Property
 
Digital Assets and the Future of Capital Markets
Digital Assets and the Future of Capital MarketsDigital Assets and the Future of Capital Markets
Digital Assets and the Future of Capital Markets
 
Hyperledger community update 20180528
Hyperledger community update 20180528Hyperledger community update 20180528
Hyperledger community update 20180528
 
Hyperledger
HyperledgerHyperledger
Hyperledger
 
Roles and skills of a corda architect a deep dive
Roles and skills of a corda architect  a deep diveRoles and skills of a corda architect  a deep dive
Roles and skills of a corda architect a deep dive
 
Introducing r3 corda™ a distributed ledger designed for financial services
Introducing r3 corda™  a distributed ledger designed for financial servicesIntroducing r3 corda™  a distributed ledger designed for financial services
Introducing r3 corda™ a distributed ledger designed for financial services
 
Introduction of Hyperledger Fabric & Composer
Introduction of Hyperledger Fabric & Composer Introduction of Hyperledger Fabric & Composer
Introduction of Hyperledger Fabric & Composer
 
Defrag X Keynote: Deploying and managing Global Blockchain Network
Defrag X Keynote: Deploying and managing Global Blockchain NetworkDefrag X Keynote: Deploying and managing Global Blockchain Network
Defrag X Keynote: Deploying and managing Global Blockchain Network
 
Hyperledger fabric 20180528
Hyperledger fabric 20180528Hyperledger fabric 20180528
Hyperledger fabric 20180528
 
The Tokenization of Everything
The Tokenization of Everything The Tokenization of Everything
The Tokenization of Everything
 

Similar to DevDay: Have Your Cake and Eat it Too, Privacy and Security with ZKP, ING

Primer to smart contracts, smart property, trustless asset management
Primer to smart contracts, smart property, trustless asset managementPrimer to smart contracts, smart property, trustless asset management
Primer to smart contracts, smart property, trustless asset managementTim Swanson
 
Privacy Preserving Paradigms of Blockchain Technology
Privacy Preserving Paradigms of Blockchain TechnologyPrivacy Preserving Paradigms of Blockchain Technology
Privacy Preserving Paradigms of Blockchain TechnologyGokul Alex
 
Kriptovaluták, hashbányászat és okoscicák
Kriptovaluták, hashbányászat és okoscicákKriptovaluták, hashbányászat és okoscicák
Kriptovaluták, hashbányászat és okoscicákhackersuli
 
Event Itnig - Smart Contracts by MarketPay, Juan Ignacio Pérez Sacristán
Event Itnig - Smart Contracts by MarketPay, Juan Ignacio Pérez SacristánEvent Itnig - Smart Contracts by MarketPay, Juan Ignacio Pérez Sacristán
Event Itnig - Smart Contracts by MarketPay, Juan Ignacio Pérez SacristánJuan Ignacio Pérez Sacristán
 
Blockchain Essentials and Blockchain on Azure
Blockchain Essentials and Blockchain on AzureBlockchain Essentials and Blockchain on Azure
Blockchain Essentials and Blockchain on AzureNuri Cankaya
 
BlockChain for the Banker
BlockChain for the BankerBlockChain for the Banker
BlockChain for the BankerBohdan Szymanik
 
Ethereum: From there to here, and ownards yonder
Ethereum: From there to here, and ownards yonderEthereum: From there to here, and ownards yonder
Ethereum: From there to here, and ownards yondergavofyork
 
Etherparty Pitch Dek
Etherparty Pitch DekEtherparty Pitch Dek
Etherparty Pitch Dekcraze3
 
Blockchain Technology and Cryptocurrency
Blockchain Technology and CryptocurrencyBlockchain Technology and Cryptocurrency
Blockchain Technology and CryptocurrencyAdityaSingh1213
 
Session 3 introduction blockchain by franco 22 januari
Session 3   introduction blockchain by franco 22 januariSession 3   introduction blockchain by franco 22 januari
Session 3 introduction blockchain by franco 22 januariArthur Janse
 
Blockchain Smart Contract v5
Blockchain   Smart Contract v5Blockchain   Smart Contract v5
Blockchain Smart Contract v5MD SAQUIB KHAN
 
From 7331 to legal : a selection of blockchain discussion topics
From 7331 to legal : a selection of blockchain discussion topicsFrom 7331 to legal : a selection of blockchain discussion topics
From 7331 to legal : a selection of blockchain discussion topicsKoen Vingerhoets
 
20190316 - CLBFest - 1337 to legal - Koen Vingerhoets
20190316 - CLBFest - 1337 to legal - Koen Vingerhoets20190316 - CLBFest - 1337 to legal - Koen Vingerhoets
20190316 - CLBFest - 1337 to legal - Koen VingerhoetsBrussels Legal Hackers
 
Smart contractjp smartcontract_about
Smart contractjp smartcontract_aboutSmart contractjp smartcontract_about
Smart contractjp smartcontract_aboutTomoaki Sato
 
Smart Contract: QA Role for Decentralized Platform
Smart Contract: QA Role for Decentralized PlatformSmart Contract: QA Role for Decentralized Platform
Smart Contract: QA Role for Decentralized PlatformMarco Andrade
 
AWIP Pink Innov Blockchain Workshop deck - May 23, 2019
AWIP Pink Innov Blockchain Workshop deck - May 23, 2019AWIP Pink Innov Blockchain Workshop deck - May 23, 2019
AWIP Pink Innov Blockchain Workshop deck - May 23, 2019Samantha Reynolds
 
What are Blockchain & Tokens and are they useful ?
What are Blockchain & Tokens and are they useful ?What are Blockchain & Tokens and are they useful ?
What are Blockchain & Tokens and are they useful ?Scott Carlson
 

Similar to DevDay: Have Your Cake and Eat it Too, Privacy and Security with ZKP, ING (20)

Primer to smart contracts, smart property, trustless asset management
Primer to smart contracts, smart property, trustless asset managementPrimer to smart contracts, smart property, trustless asset management
Primer to smart contracts, smart property, trustless asset management
 
Privacy Preserving Paradigms of Blockchain Technology
Privacy Preserving Paradigms of Blockchain TechnologyPrivacy Preserving Paradigms of Blockchain Technology
Privacy Preserving Paradigms of Blockchain Technology
 
Kriptovaluták, hashbányászat és okoscicák
Kriptovaluták, hashbányászat és okoscicákKriptovaluták, hashbányászat és okoscicák
Kriptovaluták, hashbányászat és okoscicák
 
Event Itnig - Smart Contracts by MarketPay, Juan Ignacio Pérez Sacristán
Event Itnig - Smart Contracts by MarketPay, Juan Ignacio Pérez SacristánEvent Itnig - Smart Contracts by MarketPay, Juan Ignacio Pérez Sacristán
Event Itnig - Smart Contracts by MarketPay, Juan Ignacio Pérez Sacristán
 
Blockchain Essentials and Blockchain on Azure
Blockchain Essentials and Blockchain on AzureBlockchain Essentials and Blockchain on Azure
Blockchain Essentials and Blockchain on Azure
 
BlockChain for the Banker
BlockChain for the BankerBlockChain for the Banker
BlockChain for the Banker
 
Ethereum: From there to here, and ownards yonder
Ethereum: From there to here, and ownards yonderEthereum: From there to here, and ownards yonder
Ethereum: From there to here, and ownards yonder
 
Etherparty Pitch Dek
Etherparty Pitch DekEtherparty Pitch Dek
Etherparty Pitch Dek
 
Blockchain.pptx
Blockchain.pptxBlockchain.pptx
Blockchain.pptx
 
Blockchain
BlockchainBlockchain
Blockchain
 
Blockchain Technology and Cryptocurrency
Blockchain Technology and CryptocurrencyBlockchain Technology and Cryptocurrency
Blockchain Technology and Cryptocurrency
 
Session 3 introduction blockchain by franco 22 januari
Session 3   introduction blockchain by franco 22 januariSession 3   introduction blockchain by franco 22 januari
Session 3 introduction blockchain by franco 22 januari
 
Blockchain Smart Contract v5
Blockchain   Smart Contract v5Blockchain   Smart Contract v5
Blockchain Smart Contract v5
 
bitcoin_presentation
bitcoin_presentationbitcoin_presentation
bitcoin_presentation
 
From 7331 to legal : a selection of blockchain discussion topics
From 7331 to legal : a selection of blockchain discussion topicsFrom 7331 to legal : a selection of blockchain discussion topics
From 7331 to legal : a selection of blockchain discussion topics
 
20190316 - CLBFest - 1337 to legal - Koen Vingerhoets
20190316 - CLBFest - 1337 to legal - Koen Vingerhoets20190316 - CLBFest - 1337 to legal - Koen Vingerhoets
20190316 - CLBFest - 1337 to legal - Koen Vingerhoets
 
Smart contractjp smartcontract_about
Smart contractjp smartcontract_aboutSmart contractjp smartcontract_about
Smart contractjp smartcontract_about
 
Smart Contract: QA Role for Decentralized Platform
Smart Contract: QA Role for Decentralized PlatformSmart Contract: QA Role for Decentralized Platform
Smart Contract: QA Role for Decentralized Platform
 
AWIP Pink Innov Blockchain Workshop deck - May 23, 2019
AWIP Pink Innov Blockchain Workshop deck - May 23, 2019AWIP Pink Innov Blockchain Workshop deck - May 23, 2019
AWIP Pink Innov Blockchain Workshop deck - May 23, 2019
 
What are Blockchain & Tokens and are they useful ?
What are Blockchain & Tokens and are they useful ?What are Blockchain & Tokens and are they useful ?
What are Blockchain & Tokens and are they useful ?
 

More from R3

Supporting trade finance with letters of credit on corda
Supporting trade finance with letters of credit on cordaSupporting trade finance with letters of credit on corda
Supporting trade finance with letters of credit on cordaR3
 
Corda Developer Bootcamp: Introduction to Corda
Corda Developer Bootcamp: Introduction to CordaCorda Developer Bootcamp: Introduction to Corda
Corda Developer Bootcamp: Introduction to CordaR3
 
Corda Developer Bootcamp: Tokens
Corda Developer Bootcamp: TokensCorda Developer Bootcamp: Tokens
Corda Developer Bootcamp: TokensR3
 
Corda Developer Bootcamp: Tokens
Corda Developer Bootcamp:  TokensCorda Developer Bootcamp:  Tokens
Corda Developer Bootcamp: TokensR3
 
Corda Developer Bootcamp: Accounts
Corda Developer Bootcamp: AccountsCorda Developer Bootcamp: Accounts
Corda Developer Bootcamp: AccountsR3
 
Insurance Round Table
Insurance Round TableInsurance Round Table
Insurance Round TableR3
 
BizDay: David E. Rutter Welcome Address
BizDay: David E. Rutter Welcome AddressBizDay: David E. Rutter Welcome Address
BizDay: David E. Rutter Welcome AddressR3
 
BizDay: Usage Based Insurance and Fleet Management, Infosys
BizDay: Usage Based Insurance and Fleet Management, InfosysBizDay: Usage Based Insurance and Fleet Management, Infosys
BizDay: Usage Based Insurance and Fleet Management, InfosysR3
 
BizDay: Designing the Future of Payments, Mastercard
BizDay: Designing the Future of Payments, MastercardBizDay: Designing the Future of Payments, Mastercard
BizDay: Designing the Future of Payments, MastercardR3
 
DevDay: Developer Updates: Visual Studio Code, Java 11 and OpenAPI (oh my), L...
DevDay: Developer Updates: Visual Studio Code, Java 11 and OpenAPI (oh my), L...DevDay: Developer Updates: Visual Studio Code, Java 11 and OpenAPI (oh my), L...
DevDay: Developer Updates: Visual Studio Code, Java 11 and OpenAPI (oh my), L...R3
 
DevDay: Getting Started with Tokens and Accounts, R3
DevDay: Getting Started with Tokens and Accounts, R3DevDay: Getting Started with Tokens and Accounts, R3
DevDay: Getting Started with Tokens and Accounts, R3R3
 
BizDay: Transition to DLT in RTGS payments, Accenture, SAP
BizDay: Transition to DLT in RTGS payments, Accenture, SAPBizDay: Transition to DLT in RTGS payments, Accenture, SAP
BizDay: Transition to DLT in RTGS payments, Accenture, SAPR3
 
BizDay: Connecting Construction & Insurance Ecosystem, Tinubu Square
BizDay: Connecting Construction & Insurance Ecosystem, Tinubu SquareBizDay: Connecting Construction & Insurance Ecosystem, Tinubu Square
BizDay: Connecting Construction & Insurance Ecosystem, Tinubu SquareR3
 
BizDay: The Wholesale Food Supply Chain is Ripe for Transformation, ripe.io
BizDay: The Wholesale Food Supply Chain is Ripe for Transformation, ripe.ioBizDay: The Wholesale Food Supply Chain is Ripe for Transformation, ripe.io
BizDay: The Wholesale Food Supply Chain is Ripe for Transformation, ripe.ioR3
 
BizDay: Fully Managed Corda Enterprise with Azure Blockchain Service, Microsoft
BizDay: Fully Managed Corda Enterprise with Azure Blockchain Service, MicrosoftBizDay: Fully Managed Corda Enterprise with Azure Blockchain Service, Microsoft
BizDay: Fully Managed Corda Enterprise with Azure Blockchain Service, MicrosoftR3
 
BizDay: Truck Wallet, Daimler, KI Decentralized
BizDay: Truck Wallet, Daimler, KI DecentralizedBizDay: Truck Wallet, Daimler, KI Decentralized
BizDay: Truck Wallet, Daimler, KI DecentralizedR3
 
BizDay: A View From Behind the Curtain, SIX Exchange
BizDay: A View From Behind the Curtain, SIX ExchangeBizDay: A View From Behind the Curtain, SIX Exchange
BizDay: A View From Behind the Curtain, SIX ExchangeR3
 
BizDay: Finteum Presentation
BizDay: Finteum PresentationBizDay: Finteum Presentation
BizDay: Finteum PresentationR3
 
BizDay: Using Tokens for Payment and Instant Settlement, R3
BizDay: Using Tokens for Payment and Instant Settlement, R3BizDay: Using Tokens for Payment and Instant Settlement, R3
BizDay: Using Tokens for Payment and Instant Settlement, R3R3
 
BizDay: Digital Micro-Lending and Debt Crowd Funding Platform, JVentures
BizDay: Digital Micro-Lending and Debt Crowd Funding Platform, JVenturesBizDay: Digital Micro-Lending and Debt Crowd Funding Platform, JVentures
BizDay: Digital Micro-Lending and Debt Crowd Funding Platform, JVenturesR3
 

More from R3 (20)

Supporting trade finance with letters of credit on corda
Supporting trade finance with letters of credit on cordaSupporting trade finance with letters of credit on corda
Supporting trade finance with letters of credit on corda
 
Corda Developer Bootcamp: Introduction to Corda
Corda Developer Bootcamp: Introduction to CordaCorda Developer Bootcamp: Introduction to Corda
Corda Developer Bootcamp: Introduction to Corda
 
Corda Developer Bootcamp: Tokens
Corda Developer Bootcamp: TokensCorda Developer Bootcamp: Tokens
Corda Developer Bootcamp: Tokens
 
Corda Developer Bootcamp: Tokens
Corda Developer Bootcamp:  TokensCorda Developer Bootcamp:  Tokens
Corda Developer Bootcamp: Tokens
 
Corda Developer Bootcamp: Accounts
Corda Developer Bootcamp: AccountsCorda Developer Bootcamp: Accounts
Corda Developer Bootcamp: Accounts
 
Insurance Round Table
Insurance Round TableInsurance Round Table
Insurance Round Table
 
BizDay: David E. Rutter Welcome Address
BizDay: David E. Rutter Welcome AddressBizDay: David E. Rutter Welcome Address
BizDay: David E. Rutter Welcome Address
 
BizDay: Usage Based Insurance and Fleet Management, Infosys
BizDay: Usage Based Insurance and Fleet Management, InfosysBizDay: Usage Based Insurance and Fleet Management, Infosys
BizDay: Usage Based Insurance and Fleet Management, Infosys
 
BizDay: Designing the Future of Payments, Mastercard
BizDay: Designing the Future of Payments, MastercardBizDay: Designing the Future of Payments, Mastercard
BizDay: Designing the Future of Payments, Mastercard
 
DevDay: Developer Updates: Visual Studio Code, Java 11 and OpenAPI (oh my), L...
DevDay: Developer Updates: Visual Studio Code, Java 11 and OpenAPI (oh my), L...DevDay: Developer Updates: Visual Studio Code, Java 11 and OpenAPI (oh my), L...
DevDay: Developer Updates: Visual Studio Code, Java 11 and OpenAPI (oh my), L...
 
DevDay: Getting Started with Tokens and Accounts, R3
DevDay: Getting Started with Tokens and Accounts, R3DevDay: Getting Started with Tokens and Accounts, R3
DevDay: Getting Started with Tokens and Accounts, R3
 
BizDay: Transition to DLT in RTGS payments, Accenture, SAP
BizDay: Transition to DLT in RTGS payments, Accenture, SAPBizDay: Transition to DLT in RTGS payments, Accenture, SAP
BizDay: Transition to DLT in RTGS payments, Accenture, SAP
 
BizDay: Connecting Construction & Insurance Ecosystem, Tinubu Square
BizDay: Connecting Construction & Insurance Ecosystem, Tinubu SquareBizDay: Connecting Construction & Insurance Ecosystem, Tinubu Square
BizDay: Connecting Construction & Insurance Ecosystem, Tinubu Square
 
BizDay: The Wholesale Food Supply Chain is Ripe for Transformation, ripe.io
BizDay: The Wholesale Food Supply Chain is Ripe for Transformation, ripe.ioBizDay: The Wholesale Food Supply Chain is Ripe for Transformation, ripe.io
BizDay: The Wholesale Food Supply Chain is Ripe for Transformation, ripe.io
 
BizDay: Fully Managed Corda Enterprise with Azure Blockchain Service, Microsoft
BizDay: Fully Managed Corda Enterprise with Azure Blockchain Service, MicrosoftBizDay: Fully Managed Corda Enterprise with Azure Blockchain Service, Microsoft
BizDay: Fully Managed Corda Enterprise with Azure Blockchain Service, Microsoft
 
BizDay: Truck Wallet, Daimler, KI Decentralized
BizDay: Truck Wallet, Daimler, KI DecentralizedBizDay: Truck Wallet, Daimler, KI Decentralized
BizDay: Truck Wallet, Daimler, KI Decentralized
 
BizDay: A View From Behind the Curtain, SIX Exchange
BizDay: A View From Behind the Curtain, SIX ExchangeBizDay: A View From Behind the Curtain, SIX Exchange
BizDay: A View From Behind the Curtain, SIX Exchange
 
BizDay: Finteum Presentation
BizDay: Finteum PresentationBizDay: Finteum Presentation
BizDay: Finteum Presentation
 
BizDay: Using Tokens for Payment and Instant Settlement, R3
BizDay: Using Tokens for Payment and Instant Settlement, R3BizDay: Using Tokens for Payment and Instant Settlement, R3
BizDay: Using Tokens for Payment and Instant Settlement, R3
 
BizDay: Digital Micro-Lending and Debt Crowd Funding Platform, JVentures
BizDay: Digital Micro-Lending and Debt Crowd Funding Platform, JVenturesBizDay: Digital Micro-Lending and Debt Crowd Funding Platform, JVentures
BizDay: Digital Micro-Lending and Debt Crowd Funding Platform, JVentures
 

Recently uploaded

Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Mattias Andersson
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 3652toLead Limited
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):comworks
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Scott Keck-Warren
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...Fwdays
 
Vertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsVertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsMiki Katsuragi
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebUiPathCommunity
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationRidwan Fadjar
 
Commit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easyCommit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easyAlfredo García Lavilla
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfAlex Barbosa Coqueiro
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Patryk Bandurski
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024Lorenzo Miniero
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brandgvaughan
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024Stephanie Beckett
 
SAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxSAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxNavinnSomaal
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr BaganFwdays
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Commit University
 
Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piececharlottematthew16
 
Vector Databases 101 - An introduction to the world of Vector Databases
Vector Databases 101 - An introduction to the world of Vector DatabasesVector Databases 101 - An introduction to the world of Vector Databases
Vector Databases 101 - An introduction to the world of Vector DatabasesZilliz
 

Recently uploaded (20)

Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
 
Vertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsVertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering Tips
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio Web
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
 
Commit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easyCommit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easy
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdf
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brand
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024
 
SAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxSAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptx
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!
 
Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piece
 
Vector Databases 101 - An introduction to the world of Vector Databases
Vector Databases 101 - An introduction to the world of Vector DatabasesVector Databases 101 - An introduction to the world of Vector Databases
Vector Databases 101 - An introduction to the world of Vector Databases
 

DevDay: Have Your Cake and Eat it Too, Privacy and Security with ZKP, ING

  • 1. Have Your Cake and Eat it too Matthijs van den Bos Both Privacy + Security with Zero Knowledge Notarisation in Corda CordaCon 2019, London
  • 2. Is there a problem? In Corda: Validating notaries get to see everything We want to share our transaction details on a need-to-know basis only.
  • 3. What can we do right now? Use a non-validating Notary and/or Confidential identities, etc. These either solve it partially, or introduce new issues. We prefer to have our cake and eat it too!
  • 4. Non-validating Notary: denial-of-state attack Does NOT validate: Smart contract rules, or signatures DOES check if inputs are already consumed Attackers can consume any unspent state they know ref of, no matter who owns it. Real owner will be denied use of the state for ever. Do you want to run this risk?
  • 5. So there is a trade-off We want to share our transaction details on a need-to-know basis only. Trade-off: non-validating: denial-of-state risk validating: privacy So can we have our cake and eat it too? Privacy Security
  • 6. Solution 1: Ignore! Pro: it's what we do now Con: If you close your eyes and don’t see a problem, a problem still sees you
  • 7. Solution 2: Lawyer up! Pro: will fix situation eventually Con: resolution might not be fast Con: during investigation you will have to reveal everything Con: (centralized) arbitration needed Con: undefined how to 'revert' transactions
  • 8. Solution 3: Trusted Hardware (SGX) Pro: solves everything! Con: vendor lock-in Con: more complex development Fact: need to trust vendor (current security issues, backdoors)
  • 9. Solution 4: ZKP (no knowledge - no problem) Pro: solves everything as well Con: also more complex development Fact: need to trust global scientific community Extra bonus: verifier scalability
  • 10. Non-validating Notary as base. Same privacy, same checks. Initiator creates a zero-knowledge proof that: • for the id of the tx we want to verify, • they know a matching tx data structure • that satisfies the smart contract rules • and that they know the matching signatures The Notary verifies this proof and is convinced of these facts. This prevents Denial of State attack: attacker can no longer spend a state that they do not own. Zero-Knowledge Notarisation: Overview
  • 11. /* * Initiator ZK Notarisation flow */ ZKNotaryFlow.Client(SignedTx) { // The tx we want notarised val ftx = buildFilteredTx() // Create proof that we know full tx + sigs val proof = ZKProof(LedgerTx, sigs) // Build ZK transaction val zktx = ZKTx(ftx, proof) val notarySig = notarise(zktx) } Custom Corda Notary + flows /* * Custom ZK Notary */ ZKNotaryServiceFlow { // Normal checks ftx.verify // Verify ZKP proof.verify(ftx.id) signTxAndSend(ftx.id) }
  • 12. ZK Notarisation: the ZKP toolchain Setup Once: Notary 1) Translates Corda smart contract to C (manually at the moment 😔 ) 2) Compiles C code to libsnark-compatible R1CS using Pepper 3) Performs trusted setup for libsnark (spoiler: it’s no problem!) 4) Distributes prover key Proving: Tx Initiator 1) From Corda, generates a proof for tx with libsnark using prover key, with tx id as public input and transaction data and signatures as secret input. Secret input is a serialised version of a full LedgerTransaction Verification: Notary 1) Verifies the proof with libsnark using verifier key, with only tx id as input
  • 13. Pseudo C contract int prove(pub_tx_id, secret_tx_data) { // Verify that the tx merkle root == tx.id if (calculate_merkle_root(secret_tx_data) != pub_tx_id) return 0; // Example contract logic: only one input if (get_input_count(secret_tx_data) != 1) return 0; // More contract rules here // Check required signatures if (!required_sigs_present(secret_tx_data, pub_tx_id)) return 0; return 1; } hash calculate_merkle_root(secret_tx_data) { // multiple calls to SHA256 gadget } int required_sigs_present(secret_tx_data, pub_tx_id) { // multiple calls to RSA signature verification gadget }
  • 14. Building a constraint system for contract code is hard and error prone! Either by hand, or using compiler like Pepper. Prover performance: Contract code will have to be simplified, to prevent huge constraint systems. You need hand crafted gadgets for heavy computations. There are few, and interoperability is an issue. For wide adoption, this needs to be simplified. All very nice, what's the catch? NOT
  • 15. Corda notarisation trade off: privacy vs. security. We believe SGX and ZKP can be solutions. Working on proof of concept for a Zero Knowledge Notary. This provides both privacy AND security. Next steps: • Make more mature and performant • Simplify toolchain: • same contract code for non-zkp and zkp verification • less ZKP tools • Hopefully convince Corda team to incorporate it :-) • More ZKP-friendly signature scheme in Corda Yes, you can have your cake and eat it too! Interested? Want to help out? Come talk to us!
  • 16. Matthijs van den Bos ING Bank | Distributed Ledger Technology Team matthijs.van.den.bos@ing.com Corda Slack: @mvdbos Links: • libsnark: https://github.com/scipr-lab/libsnark • Pepper: https://github.com/pepper-project/pepper & • Jsnark: https://github.com/akosba/jsnark Contact details & links