These slides were used in the lecture 7 of FinTech - Financial Innovation and the Internet 2020 Fall at the Graduate School of Business and Finance, Waseda University, on November 13, 2020.
Lecture 7 : Blockchain (1) Kenji Saito Professor, Graduate School of Business and Finance, Waseda University Lecture 7 : Blockchain (1) — FinTech — Financial Innovation and the Internet 2020 Fall — 2020-11-13 – p.1/31
required You do need to speak often (we are going to have a lot of dialogue) We will use breakout rooms a lot, but those won’t be recorded unless you do it yourselves (need to be allowed) Keep your Zoom client updated! We might use latest features The recordings could be used for research on online learning Transcribed for use and anonymized Will let you know when the necessity arises Lecture 7 : Blockchain (1) — FinTech — Financial Innovation and the Internet 2020 Fall — 2020-11-13 – p.2/31
and chat text will be posted at Moodle and Discord Trial automatic transcription of the lecturer’s part will be posted at Discord Lecture 7 : Blockchain (1) — FinTech — Financial Innovation and the Internet 2020 Fall — 2020-11-13 – p.3/31
Lecture 2 10/2 Overview of FinTech (2) • Lecture 3 10/9 Internet Technology and Governance (1) • Lecture 4 10/16 Internet Technology and Governance (2) • Lecture 5 10/23 The World of Apps (1) • Lecture 6 10/30 The World of Apps (2) • Lecture 7 11/13 Blockchain (1) • Lecture 8 11/20 Blockchain (2) Lecture 9 11/27 Other Ledger Technology and Applications (1) Lecture 10 12/4 Other Ledger Technology and Applications (2) Lecture 11 12/11 Cyber-Physical Society and Future of Finance (1) Lecture 12 12/18 Cyber-Physical Society and Future of Finance (2) Lecture 13 1/8 FinTech Ideathon (1) Lecture 14 1/15 FinTech Ideathon (2) Lecture 15 1/22 Presentations and Conclusions Lecture 7 : Blockchain (1) — FinTech — Financial Innovation and the Internet 2020 Fall — 2020-11-13 – p.4/31
Web API (REST) in particular Basics of cryptography Cryptographic hash function Public key cryptography and digital signature Zero-knowledge proof Discussion : Imagine API Assignment Lecture 7 : Blockchain (1) — FinTech — Financial Innovation and the Internet 2020 Fall — 2020-11-13 – p.5/31
to answer Physical model with beakers and newspaper Functional layers (validity, existence, uniqueness) Possibilities and Impossibilities Applications people talk about, and thoese workable in reality Lecture 7 : Blockchain (1) — FinTech — Financial Innovation and the Internet 2020 Fall — 2020-11-13 – p.6/31
*OQVUUIBUHJWFTUIFTBNFEJHFTU $BO` UEFEVDF 'JYFEMFOHUIEFpOFECZ UIFGVODUJPO FYCJU *OQVU )BTIWBMVF EJHFTU *GJOQVUTBSFKVTU CJUEJ⒎FSFOU 5PUBMMZEJ⒎FSFOU PVUQVU $SZQUPHSBQIJDIBTIGVODUJPO 4)" 3*1&.% FUD $BO` UEFEVDF $BO`UEFEVDF *U` TJOGFBTJCMFUPDBMDVMBUFBO JOQVUUIBUQSPEVDFTBTQFDJpD EJHFTU When a file (e.g., an open-source app) needs to be authenticated, the provider may publish a fingerprint value (called a hash value or digest) of the file (typically in hexadecimal) The downloader can calculate the digest in the same way, and if it is the same value as the publicly available one, they have a real file It is considered extremely difficult to disguise a fake file so that it gives the same digest The digest is calculated using a cryptographic hash function There are various functions, such as the SHA (Secure Hash Algorithm) series A cryptographic hash function produces a completely different digest if the original data (preimage) is different by even 1 bit Unidirectional, and cannot get preimage from the digest So it is sometimes used to hide the original data Lecture 7 : Blockchain (1) — FinTech — Financial Innovation and the Internet 2020 Fall — 2020-11-13 – p.8/31
Output : signature Verifying Input : <plain text, signature, public key> Output : OK or NG OK ← the private key is used and the plain text has not changed a bit NG ← otherwise Whether the signature meets certain mathematical properties that can be tested using plain text and public key Private key cannot be inferred in the verification process Lecture 7 : Blockchain (1) — FinTech — Financial Innovation and the Internet 2020 Fall — 2020-11-13 – p.9/31
no knowledge other than what prover wants to prove Example: “I know a secret spell to open the door” ↑ Prove this without revealing the spell itself For example, repeat “coming out from the way she is told” for 20 times Completeness Verifier accepts with high probability if the proposition is true Soundness Verifier has little chance of accepting if the proposition is false Zero-knowledge Can imitate dialogue without having to be a prover (without knowledge) Lecture 7 : Blockchain (1) — FinTech — Financial Innovation and the Internet 2020 Fall — 2020-11-13 – p.10/31
financial services (2) If a user is an “end (edge)”, what is the “center” operated by people in the example? (3) How will the service change if the center is automated? Deadline and how to submit November 10, 2019 at 17:59 JST From Moodle (mandatory) Optionally, you can also post to #assignments channel at Discord So that your classmates can read your report, refer to it, and comment on it Just plain text, and be concise, please Lecture 7 : Blockchain (1) — FinTech — Financial Innovation and the Internet 2020 Fall — 2020-11-13 – p.12/31
Measures . . . how to improve the class 15 out of 16 students submitted (pretty good, and always better later than never) To be automated : (cross-border) payments (5) / loans (3) / insurances (flight delay) (3) / security trading and settlements (2) / filing taxes (1) / blockchain (1) Very interesting, but perhaps you have too high expectations for automation The goal of this course is to gain a high-resolution understanding of technology Lecture 7 : Blockchain (1) — FinTech — Financial Innovation and the Internet 2020 Fall — 2020-11-13 – p.13/31
the service change if the center is automated? positive: transfer speed up, decrease of human resource cost Negative: high risk of money laundering, security problems ⇒ Why do you think so, especially on the negative side? Which is easier to cheat on, a person or an automated system? Lecture 7 : Blockchain (1) — FinTech — Financial Innovation and the Internet 2020 Fall — 2020-11-13 – p.14/31
assistance with filing taxes [snip] In essence, technology has replaced a large portion of the role of accountants [snip] This could potentially solve even further if the customer support function becomes automated [snip] If the AI becomes self-sufficient in this aspect as well, humans may become obsolete in tax services Their only role will be inputing updates to tax formulas based on recent changes in the relevant legal system ⇒ Probably changes in regulations can also be applied automatically e.g. I think that Washington, D.C. uses GitHub to manage the text of the ordinance Software receives update notifications and can trigger automatic updates of tax formulas Lecture 7 : Blockchain (1) — FinTech — Financial Innovation and the Internet 2020 Fall — 2020-11-13 – p.15/31
the delay takes place, it will be documented in the smart contract which is connected to airline transportation database, so the holder of the insurance policy (the passenger) is able to have the compensation automatically ⇒ This is an application often talked about We will see if this is a useful example (I think it can be) when we get to lectures on smart contracts Lecture 7 : Blockchain (1) — FinTech — Financial Innovation and the Internet 2020 Fall — 2020-11-13 – p.16/31
Nakamoto) Satoshi him or her or themselves called it “distributed time-stamp server” Not a good word for representing a concept (catchy, but manipulating the impression) Something implemented by Chain of ← actually, backward list of Blocks ← actually, sets of data For example, we don’t call TV “picture tube” today (or do we?) Lecture 7 : Blockchain (1) — FinTech — Financial Innovation and the Internet 2020 Fall — 2020-11-13 – p.17/31
money whenever we want, and never let anyone stop us”? Distrust of (central) bank money / Sending money → a state transition in a state machine Straightforward requirements (BP : Blockchain Properties) BP-1: A self-authorized user solely can cause a state transition that is allowed in the state machine BP-2: Such a state transition always occurs if the authorized user wants it to happen BP-3: Once a state transition occurs, it is virtually irreversible, and can never be denied Denying = rejection, deletion, alteration, fabrication ⇒ Not really perfectly satisfied by blockchain Lecture 7 : Blockchain (1) — FinTech — Financial Innovation and the Internet 2020 Fall — 2020-11-13 – p.18/31
“we send money whenever we want, and never let anyone stop us”? Distrust of (central) bank money Bitcoin’s “Answer” Cannot depend on any particular service provider ⇒ Exchange digital coins over the Internet by P2P (peer-to-peer) What if they deny that they sent a coin? ⇒ Use digital signatures (collateral for verifiability and non-repudiability of contents) Lecture 7 : Blockchain (1) — FinTech — Financial Innovation and the Internet 2020 Fall — 2020-11-13 – p.19/31
by digital signatures alone Need to prevent double spending (want to ensure non-repudiation of existence) ⇒ Put the evidence of the transaction in newspaper What if refused for publishing or service is discontinued? ⇒ Place evidence of a transaction in “newspaper” (as collective evidences of events) issued by a crowd And thereby records are like locked up in the air Theft of coins based on this idea always follow the story made typical by the Mt.GOX or CoinCheck incident “Don’t let anyone stop us from spending our own money whenever we want to” ⇒ Has to prove that the user is oneself by their own → Zero-knowledge proof of possession of the private key → Anyone with the private key is the user oneself ⇒ Transaction is verifiable by all but irrevocable → Stolen coins can be tracked but not recovered Lecture 7 : Blockchain (1) — FinTech — Financial Innovation and the Internet 2020 Fall — 2020-11-13 – p.20/31
of liquid of no value to mankind Contained in a tank Individuals can hold as many beakers as they like, measuring down to 1 100 , 000 , 000 cm3 (it has a locked lid) Only “editor” selected every 10 minutes on average can pump now 6.25cm3 into their beaker Chosen by a special lottery The winning lottery is held in everyone’s box, and each person draws the lottery with all their strength → non-stoppable procedure Coordinate the proportion of winning lots so that someone is chosen every 10 minutes on average Volume pumped is reduced by half every about 4 years (every 21 thousand pages of “newspaper” described later) Started from 50cm3 in January 2009 Lecture 7 : Blockchain (1) — FinTech — Financial Innovation and the Internet 2020 Fall — 2020-11-13 – p.21/31
of fluid between beakers Recorded as “a signed article” by the pourer Post the article in the “newspaper” made by everyone Selected “Editor” verifies the articles and publishes them in the last page of the newspaper Page carries the evidence of winning the lottery Editor also gets “overflow” of trades on the page If people publish a page with the same page number. . . Longer sequence of pages wins People sometimes lose the key of their beakers Create this digitally, and pretend that it’s a currency → Bitcoin There is no money or currency that does not need pretension Lecture 7 : Blockchain (1) — FinTech — Financial Innovation and the Internet 2020 Fall — 2020-11-13 – p.22/31
a digital signature of the party to which the referenced output is addressed Referenced output (= coin) is consumed → never double-spent (UTXO : Unspent transaction (TX) Output) Lecture 7 : Blockchain (1) — FinTech — Financial Innovation and the Internet 2020 Fall — 2020-11-13 – p.23/31
number : n page number : n+1 page number : n+2 Cryptographic digest of the previous page (must be less than or equal to the target value) some extra number (Nonce : Number used Once) (random value to make the digest less than or equal to the target) Page digest (output by a cryptographic hash function) must be less than or equal to target We don’t know how to manipulate the original data to get the right digest This is the principle of the lottery, which requires the same amount of cost to fake the history Lecture 7 : Blockchain (1) — FinTech — Financial Innovation and the Internet 2020 Fall — 2020-11-13 – p.24/31
page number : n+1 page number : n+2 page number : n+3 page number : n+1 page number : n+2 page number : n+3 page number : n+4 This history is valid Sometimes page sequences are split when someone else wins the lottery at about the same time A history is the hardest to tamper with when the cumulative cost of lottery for the whole sequence is the highest Everyone agrees that that history is the official one (strict consensus is not achieved) Lecture 7 : Blockchain (1) — FinTech — Financial Innovation and the Internet 2020 Fall — 2020-11-13 – p.25/31
n+1 block_no : n+2 block_no : n+3 block_no : n+1 block_no : n+2 block_no : n+3 block_no : n+4 Histroy with the largest cost to record or modify (history the most difficult to alter) is chosen Cryptographic digest of the previous block Transactions are digitally signed To create a block, its cryptographic digest needs to be below some certain number (Proof of Work) or one needs to win by voting weighted by the stakes in cryptocurrency (Proof of Stake) [both costly] Creator of a block can record the reward in cryptocurrency in the block, which is effective only when the block is included in the chosen history Means are provided to confirm existence of transactions validity existence uniqueness In case of Proof of Work, the cost of power is balanced against the market value of the native currency Everyone confirms that records are not tampered with by the mechanism protected by the price of the native currency Lecture 7 : Blockchain (1) — FinTech — Financial Innovation and the Internet 2020 Fall — 2020-11-13 – p.26/31
access (no need for mediation), agreed real-time settlements, business rule descriptions, and confidentiality Corporate behavior (automating corporate management, especially in financial matters) Real-time execution and confidentiality control of share splits, capital reductions and consolidations, share transfers and exchanges, mergers, third-party allocation of new shares, etc. Supply Chain Traceback of materials, and record and search from production, storage to sales (beware of linkage problem) Master Data Management Only authorized personnel can update and designated reviewers approve it Sharing Economy and IoT Smart cities/towns, transportation, healthcare/fitness, retail, architecture, education, etc. (implicitly real-time and on a large scale) where trust is not necessarily established Red letters denote parts that blockchains are not good at Within the problems we want to solve, there are sub-problems that have not been solved yet Lecture 7 : Blockchain (1) — FinTech — Financial Innovation and the Internet 2020 Fall — 2020-11-13 – p.28/31
. . Remittances that bypass banking networks That’s a huge impact Proof of Existence Ex. Proof of Existence, Everledger (in the past), . . . Embed arbitrary digests in a blockchain (piggybacking hack) There is also a method of embedding a single digest of a large number of records Proof that a record has existed and has not been tampered with Origin Certification (traceability, tracking and accounting) This is the originally intended application category of blockchain (an alternative to “newspaper”) Lecture 7 : Blockchain (1) — FinTech — Financial Innovation and the Internet 2020 Fall — 2020-11-13 – p.29/31