Understanding Blockchain Basics: Asking for a Friend

2 Jun 2023 · 53 min

Ask about this episode

Ask anything about it. ChatGPT or Claude reads this page and answers with the times it was said.

Connect VO and ask about every podcast you hear, including the moments you saved. Add to ChatGPT · Add to Claude

In short

Podcast Summary: Raoul Pal: The Journey Man - Understanding Blockchain Basics: Asking for a Friend

Podcast Description In this episode of "The Journey Man," Raoul Pal discusses the rapidly changing world of macroeconomics, cryptocurrency, and technology. With insights from leading experts, the episode explores the implications of the Exponential Age on various societal dimensions.

Episode Overview

Episode Title

Understanding Blockchain Basics: Asking for a Friend Episode Description This episode features Ash Bennington and Nico Brugge as they revisit the fundamentals of blockchain technology with a special framework provided by Anders Brownworth, emphasizing the importance of understanding how blockchains function.

Key Discussions and Highlights

Introduction

  • Hosts: Ash Bennington and Nico Brugge express the need to return to the basics of blockchain after discussing complex topics.
  • Guest: Anders Brownworth, principal architect at the Federal Reserve Bank of Boston, explains blockchain fundamentals in a visual manner.

Core Concepts of Blockchain

  • Definition of Blockchain:
  • Many describe blockchains by their functionalities (e.g., Bitcoin as digital gold), but the discussion aims to clarify the underlying technology.
  • Visual Demonstration:
  • Anders uses visual aids to illustrate how blockchains work, focusing particularly on two key cryptographic techniques:
  • SHA-256 Hash: A digital fingerprint that outputs a fixed-length hash from any input data.
  • It is one-way; you can generate the hash from the data but cannot derive the original data from the hash.
  • Nonce and Mining:
  • The nonce is a variable used to find a hash value that meets specific criteria (like starting with a certain number of zeros), illustrating the mining process.

Building Blocks of Blockchain

  • Structure of a Block:
  • Each block consists of data, a nonce, and a hash.
  • Blocks are interconnected, where each block contains the hash of the previous block, ensuring data integrity.
  • Mining and Proof of Work:
  • Mining involves solving complex mathematical problems to validate transactions and create new blocks.
  • The system incentivizes miners through rewards (coinbase transactions).

Security and Trust

  • Decentralization:
  • Multiple copies of blockchain data exist across different nodes, enhancing security and trust.
  • If a malicious actor attempts to alter a block, the majority consensus among nodes will reject the fraudulent chain.
  • Public/Private Key Cryptography:
  • Transactions are signed with a private key, enabling secure verification using a public key, creating a trustless environment for transaction validation.

Ledger and Transaction Management

  • Flow vs. Balance:
  • Blockchain keeps track of transactions (flow) rather than account balances, which prevents double spending and maintains system integrity.
  • Coinbase Transaction:
  • New currency is introduced into the system through a special transaction that rewards miners, establishing a controlled monetary supply.

Conclusion

  • Takeaways:
  • The technology of blockchain offers a new trust layer for internet transactions, building on existing cryptographic principles.
  • Understanding the basics is crucial for appreciating the broader implications of blockchain in finance and beyond.
  • Further Exploration:
  • Listeners are encouraged to interact with Brownworth’s demo available online to deepen their understanding of blockchain mechanics.

Closing Remarks

  • Final Thoughts:
  • Ash Bennington and Nico Brugge emphasize the importance of revisiting foundational knowledge for a better grasp of contemporary discussions on cryptocurrency and technology.

Key Takeaways

  • Blockchain technology is rooted in cryptographic principles, with SHA-256 hashes and public/private key pairs being essential for its operation.
  • Decentralization allows for a trustless environment, where alterations to the blockchain are easily identifiable.
  • Understanding these basics is vital for anyone looking to engage with cryptocurrency markets and decentralized finance (DeFi).

---

Additional Information

  • For further insights and a deeper dive into the math behind blockchain technology, listeners are directed to additional Real Vision content.
  • The episode encourages sharing knowledge with friends and family to foster broader understanding of the technology.

Written by AI. May contain mistakes. Listen to the episode to check what was said.

Hear the part that matters, and keep it.Open this episode in VO. Double tap your headphones to save a moment as you listen.
Get VO free

Transcript

Automatic transcript. May contain errors.

0:00Your favorite neighborhood spot grows with Square. Indeed, my favorite neighborhood spot has quickly become Todd Snyder in Williamsburg. Todd Snyder is one of my favorite menswear shops and has supplied me with all the clothes I have needed this quite hot summer. Every business has different goals, but Square is the business platform that supports them all. From opening a new location, selling something new, or just expanding their reach. Indeed, I've seen it with Todd Snyder. In Square, also, you can get real-time insights, so don't wait for end-of-day reports. Go to square.com forward slash go forward slash realvision to learn more about how your business can grow with Square.

0:43That's S-Q-U-A-R-E dot com slash G-O slash R-E-A-L-B-I-S-I-O-N.

0:57Hey everyone, if you like this podcast, go behind the paywall to get privileged access to the smartest minds in finance. Join the Real Vision community and learn how to become a better investor. Visit realvision.com slash rvpod and use the promo code podcast10, that's podcast10, to get 10 % off our essential membership for the first year. Now, to the top analysis of today's crypto markets.

1:30All righty, everybody. We got a really special episode for you this Friday. I'm asking for a friend, but I'm going to do a bit of a mea culpa here because this should have been our first episode, Ash. I fucked up. We got way too degen. So we're pulling it back and we're going to go into the fundamentals of blockchain technology. This is an amazing piece that Ash and Anders Brownworth gave a couple of years ago. So Ash, you know, I know this is one of your favorite videos, but mind teeing it up just a bit for us? Yeah, that's exactly right, Nico. Everything you said. This is an important video for me because it played an incredibly important role in my own development in learning about and understanding blockchains.

2:06Anders had done two of these demonstrations, visual demonstrations for how blockchain worked on YouTube that I actually saw in 2017. And for me, this was kind of the aha moment where I actually understood how blockchains work just by watching him physically walk through all of these steps in a way that was very visual. So it was an incredibly powerful experience for me back in 2017. We asked Anders to come on Real Vision and do both parts together for the first time ever for a Real Vision audience. I was incredibly excited to get to do it. And I'm incredibly excited to get to rebroadcast this because I think it's such an important piece of information for people who are really struggling to get their heads around this basic question.

2:44hey, I get it, it's cool, but how does it actually work? Well, Anders has those answers. MARK BLYTHYNIC Absolutely. Let's get right into it. RAOUL PAL, Anders, welcome to Real Vision. RICK VISCOMI Thank you, Ash. This is a pleasure. RAOUL PAL, It's such a pleasure to have you here. Anders, one of the things that I find so interesting about your demo is that very often when you ask people what a blockchain is, they tell you what it can do. They give you use cases. They say, Bitcoin is digital gold. Ethereum is a place to write smart contracts, but they don't actually tell you what it is. And what I find so fascinating about what you've done here is that your videos do something that I've never seen anyone else do, which is to walk you through in a step-by-step way that's incredibly visual, concept by concept, the underlying technology for how blockchains work.

3:35Yeah, I only learn visually. So this is an outgrowth of having done the Bitcoin deep dive and try to re-explain the basic idea behind it with pictures, because that's the way I think. Yeah. And I should say a little bit about your background. You're currently principal architect at the Federal Reserve Bank of Boston. You're a senior software engineer at Circle. And way back, I think in 2014, you co-taught the first blockchain class at MIT. That's right. I was lucky enough to be picked to do that. It was, it's amazing. You go there and you've got 100 of the best minds in the world, and you're supposed to teach them something that they don't know.

4:21And it's incredibly invigorating. It's a lot of fun. Well, I should say you certainly succeeded in doing that. And finally, I should add, if you enjoy this demo, this walkthrough half as much as I do, shout it from the rafters, tweet it, post about it, tell your friends, share it as broadly as possible. I think this is something really special. Well, thank you very much. So if you want, we can dive right in. Let's dive in. Great. Well, so I think the key is with blockchains, there's only really two cryptographic techniques you have to understand to understand how blockchains work. And we're going to just quickly get a visual feel for how each of those work.

5:06And this one right here we're looking at is called a SHA-256 hash. This is one of them right there. Looks like a bunch of letters and numbers together. It's actually a hex number. And what this is, is a digital fingerprint of whatever I type up here. So I'm going to type something. I'll type my name, A-N-D-E-R-S. Okay. Well, look at that. You know, some kind of, you know, seemingly random looking data. But if I were to take this, let's see, first of all, I should note that that starts with a 1-9-E-A. So let me delete what I wrote there. And I'm going to type exactly the same thing and sure enough 19EA okay so anytime I type exactly the same thing here I get exactly the same hash out of it so in that sense the SHA-256 hash is a digital fingerprint of whatever data I put in here now I can put you know I could put nothing I could put lots of data and you'll see every time I'm typing a key, this is changing.

6:15So you get the idea that this can be calculated very, very quickly. But no matter how much or little I put up here, you're always going to get a SHA-256 hash, which is exactly this long. And importantly, you're not going to be able to go backwards. You're not going to be able to start with this and just intrinsically know what was put in to get it. You can't go in that direction. But it's super easy to go in the other direction, you can tell, because that's how I type and it calculates it very quickly. So I could put anything in here, including like the Library of Congress, and it would always come out to a hash that's just that long.

6:59Okay? That's the critical piece of information. You can go one way very easily, and the other way is impossible. So it only moves in one direction, and whether you type in one character or the entire Library of Congress, the hash always comes back the same length. Right, right. And exactly the same. It will always be exactly the same. If you put in the Library of Congress in exactly the same order, you'll always get exactly the same thing out of it. And we're going to say that this is real time actually happening. This isn't a demo. This isn't a video. This is actually the algorithm being calculated in real time as you see it on the screen.

7:36Yeah. There was somebody had released a shop to 256 hash implementation in JavaScript. So I stole it to make this. That's how I did it. So, yeah, so that's a hash, you know, not very interesting, I guess, in the sense that I can just type stuff and know that I have the same thing. That's, you know, doesn't seem all that interesting. I'm going to make what I call a block out of this. Okay, so this, I mean, it looks very similar to what we were looking at before, but instead of one text area, now I've got three. I've got one that I call a block. We'll call this block number one. I have an entry here I call a nonce.

8:20We'll go into what that is later. And then just some data. You can type, you know, whatever data you want. But basically, this hash here, this SHA-256 hash, is the hash of the concatenation of all this data. So if you take all this stuff, put it together, you get that. Okay. Now, importantly, very importantly, this is an unusual hash because it starts with four zeros in a row. Okay. And completely arbitrarily, I'm just going to say that that makes this block solved. Okay. So what would happen, Ash, if I were to type something in this data area? What's going to happen to this hash? Well, that's going to change as soon as you start typing.

9:06Yeah. What's the chance that it's going to start with zeros? Well, probably 10 ,000 to one, I guess. Right? Yeah, exactly. It's probably not, right? So if I type something, it's going to violate what I call a hash, a solved block. So I'm going to type something. And sure enough, it turns reddish, meaning this is not solved. So how could we solve this block? right i could i could go here and i could put a number see this is my nonce there and told you we get back to this this is uh this is what gives me a field that i can change that doesn't really affect anything else so i put a one there does it start with four zeros no well let's try two well let's try three you know as i'm going here i'm looking for one that starts with four zeros so you can tell i'm not getting it right so what we're doing right here is we're mining Now, I bet you wonder what this mine button does, right?

10:05Well, literally what it does is it starts at one, just like what I was doing, but goes all the way up and does it automatically. And this is literally mining. So I'm gonna hit mine. And there it's thinking for a little bit. And it's going from starting from one, and it's gonna go up to whatever number it needs to get to to find a block that hashes out to something starting with four zeros. And my computer was taking a little bit of time for it, but there we go. Had I gone all the way up to 71 ,000 whatever, I eventually would have run across a hash that starts with four zeros. And so what I'm demonstrating here is we have a block and we have done some work to satisfy what is essentially an arbitrary definition of what a solved block is.

11:01And that is that it starts with four zeros. Hey, everyone, we're going to take a quick pause and hear a word from our partners. We'll be right back.

11:13Right. So that's it. One of the things that I find really interesting about this is the way that you have this divided up. You have a block, you have a nonce, you have the data, and then you have the hash. It's almost a kind of an arbitrary division from the perspective of mining. But what makes the nonce, as I understand it so important, is that you segregate the data out kind of as the payload. You could think of it as perhaps an envelope, and it's the thing inside. And then you calculate the series of numbers going through them, iterating through one by one until you solve for the hash that meets the criteria that we're looking for, which in this case is four leading zeros.

11:50Yep. Yep. That's exactly right. Yeah. Okay. So then to move on, let me ask you, what is, so this is a block. What's a blockchain? Well, I have the benefit of having gone through your demo over a series of years, but it has to do with the way these are chained together. So So show us a little bit about how that works, because I think this is really just the incredible aha moment that many people will have when they're watching this video. Yeah, so this is how you chain blocks together. I'm just going to make a chain of, in this case here, I've got five blocks. These look just like what we were looking at before.

12:29But interestingly, I've added this previous. What is previous? Well, that number is this number, is the previous blocks hash. and this previous is this block's hash, right? So everything else is exactly the same. If I change something here, it's going to break this block, right? But what were to happen if I were to change something here? It's going to change this hash, right? But that gets copied up to here. So we're going to have two broken blocks, right? Sure enough, that's what happens. So you might say, well, that's not the end of the world. We could just re-mine it, right? I could mine these two, and then we would be fine, right?

13:24Well, as we saw, I'm going to fix that one. I'm going to go back one more, and I'm going to add some data here. So now we have three broken blocks. And now I'm going to say, well, if you were to mine it, I just hit mine there, and that thing is thinking, well, that one went relatively fast. I hit this one. That one's taking a little bit of time. And then this one, right? We could re-mine this blockchain and it would be fine. It would satisfy our definition of what we call solved blocks in a chain, right? But the problem is the farther back we go, the more of these you would have to fix, okay? So it takes time to mine each of the blocks.

14:06The farther back you go, the more of that work you have to do. And let's talk about this for a second. This is the work we're doing is literally the proof of work that you hear about in proof of work blockchains. This is the work that they're doing. So we need some way to fix this. We have this problem because, OK, I did the work. But how are you going to know that I've altered this chain, that I've taken some data and I've changed it? Right. How do you know? Well, we can't really know. We just know we have a solved chain here. So what I'm going to do is I'm going to distribute this blockchain.

14:48OK, so we've got exactly the same thing. Five blocks. But this is in peer A. we also have a peer b right and there are five blocks in peer b and here is peer c right we have five blocks okay now how do we know let's say i were to change something i'll go back in time and change this block and i'm gonna you know remind it and uh you know i'm let's say i'm mischievous, right? I shouldn't be doing this. I remind this block. Interesting, takes a long time. And then I remind this block. Okay, so when this completes, I've got my altered chain, right? This is a problem. It's an altered chain, but it satisfied the criteria that we arbitrarily decided was signed, which is those four leading zeros.

15:47It does. Yeah. Yeah. But we need to be able to detect that somebody has gone and maliciously changed something here, right? So how do we know? Well, getting back to the hash, remember how it is a fingerprint of some data. Well, this is actually a fingerprint of all of the data in this chain, including the previous blocks, because the previous hashes are copied up. So literally, all I have to do is check this, right? AEF, ADF, whatever. Is that the same as E4B? No. And here's another one that claims it's E4B, okay? So who's right? Well, democracy, right? We have this chain, peer A, that says it's something, and then two others that disagree.

16:38So the majority wins, and we just forget about this chain. So all of that work that was done was thrown away, essentially. Yeah. And this is such an important point. People frequently ask when they're new to this space, well, how do I know? How can we know whether a particular computer that's telling us something on the blockchain, and Bitcoin, for example, is reliable? How do we know that people didn't kind of go in and tinker around with some of the transactions. And what you're seeing right here is a real-time live demo showing how you can have multiple peers on a network, also called nodes, that have different ultimate hashes, which show that OneChain has been changed.

17:19It's really fascinating. It's actually kind of a revolution in that for the first time in human history, You can generate trust in a way that's decentralized. It doesn't rely on a single centralized actor, a big bank, the Federal Reserve to say, this is the source of truth. You can see it democratically happening in real time in this demo. And I think that's just fascinating. Yeah. So I should also note, though, that this is a very simplistic blockchain, right? We have five blocks here. Right now, the Bitcoin blockchain is something like 680 ,000 blocks long. So if you were to, you know, like one way to compare all the chains would be to literally lay out 600 ,000 blocks and check the first one.

18:05Is this one the same? Yes. Is this next one the same? Yes. Next one the same. Or you could just go to the last hash and realize that that is a fingerprint of that entire chain and compare it against any of the others. So the blockchain can get arbitrarily long, billions, trillions of blocks long, and it will all always boil down to something that's this long and no longer. So it's super easy. Yeah. It's elegant. I mean, it's super easy to just instantly check literally terabytes of data, petabytes of data in one number. It's pretty neat. Elegant is a word that comes up over and over again when you hear people who really understand the math, such as yourself, for how this works.

18:53I should say, if you've heard the term Merkle tree, I know it's a lot of complex cryptography and math behind it, but this is really the basis for basically how you can take a hash of a hash of a hash and aggregate it so that at the end, you can just look at one number and know that the entire chain is authentic. Yeah. And that's actually a really interesting point. We know that the chain is authentic or not. We don't know what change was made, but it doesn't matter. The only thing you care about is that you have the authentic one. If there has been a change, it doesn't matter what the change was we're gonna drop it.

19:35So a hash gives you a real easy way to do that. Now we've got a problem with this blockchain here right this is a blockchain and it's got some data area I can type whatever I want who cares right this is this is not valuable information I'm trying to save you know the the letter a you know that's that's not great so let's do something about that instead of that data area what I'm going to do and this is a blockchain, just like we were looking at before, five blocks long, but the data area I've replaced with what I'm calling transactions. And this is just some amount going from some person to someone else.

20:17And so it's transfers. And there you have it. Now you've got a ledger. That's right. Yeah. But importantly, this is a ledger of transactions, not a ledger of balances. We are not saying John's balance is whatever. We're just saying that some amount of money was sent from one person to another. ED HARRISON Right. And this is such a key concept, I think, for people who think about traditional accountancy. This isn't a stock value, it's a flow variable. It's talking about what's just happened in terms of a transfer. And this is a really also, I think, deeply fascinating and pivotal point in how blockchains work.

20:54ED HARRISON Yeah, these are showing changes of state. It turns out computers are really good at calculating numbers very quickly. So if we were to save the balances here, it would really be duplicate information. We can just say everyone had nothing to start with, and then they got this money through transfers. So that's how this goes. And let me just, you know, just to nail the point home, right? If this is$2 ,700 some amount of dollars, if I were to change that, right, It's going to break the block. And this is very, very important. Even if I were to change literally like one penny, if I were to make this 64 cents, it's going to break the blocks.

21:41That's very important. And now remember, we also have P or B and C, the same thing we had before. So we're going to essentially democratically figure out what the authoritative chain is just by checking who has what and pointing to the one that has the majority as essentially the winner. But I've got a problem in my little system here. I don't know if you can find it easily or not. Any ideas? Hey, everyone, we're gonna take another quick break and hear a word from our partners. We'll be right back to the Real Vision Crypto Daily Briefing.

22:25All right. I think I see it, but walk us through. Okay. Where does money come from? How do I know that Rick here has$62 to give to Ilsa? How do I know that this much money is in this guy's account for that person? By the way, I don't know if you know all these names. These all come from a movie. If you know what movie that is, you get extra points. Is it Casablanca? It's Casablanca. That's right. Yeah, each one of these are different sort of movies. So the interesting thing here is we have no way of knowing, like money just appears. You know, the money is just moving around. That's great, right?

23:09But we can't just have unconstrained. I can't just like say somebody I make up gives Anders a million dollars. That sounds like a great idea, but it's probably not good in an economic system. So we have to have a way to get money into this system. OK. And so in order to do this, we are going to use what we will call a Coinbase transaction. And we'll zip forward to five here. OK. So I'm just going to add a new transaction at the top of the transaction stack called a Coinbase. And regularly, every one block, I'm going to release$100 to someone. who well this happens to go to the person that has mined this block first okay so now we have a regular transmission of money right i create money in the coinbase so it's uh it's controlled and it oh it's always going to go to someone and then those people can then transfer the money so let's go back to the beginning of this chain the first block here has a 100 coinbase transaction goes to me.

24:19I happen to have created this block. I happen to have solved this block, but there are no transactions because I can't, nobody has any money to send to anyone. So there's just no transactions. Now the second block, you'll notice that I'm the only one sending money. It's all Anders, Anders, Anders, because the money, you know, I'm the only one who has money in the system at this point. And if you add these up, you'll notice that they don't go over$100. Okay. So it's just some basic economic, you know, truths that you want to, you know, have trust in, right? So that'll be the economic role of this system.

25:01So now as I go forward, and you'll see that there are different people money is going from, you'll notice that they were all given money previously. And the amount of money that they're sending is not more than what they got. Right. And so if you sit here and you kind of go through all of them, you'll notice it does actually work. And we have an economic system here where transactions are recorded indelibly. Like if I were to change any, if I tried to change the person's name, right, it's going to break the block. They're recorded indelibly across a bunch of peers. There's peer B, and there's a bunch of peers out there.

25:42We're all agreeing on the flow of funds. It's interesting because most people have heard the term Coinbase, obviously, because of the exchange. Now, you see where that came from. When you scroll back all the way to the first transaction, this is the genesis block. This is the creation of the chain that you're seeing here. Yeah, that's right. And you'll notice there is no previous. So we have this fake all zeros hash that we've put in. Yeah, exactly. This is the genesis block. And a matter of fact, in the code, what you do is you create the first block and you say, OK, this is the official first block.

26:21This is the hash of the first block. In that sense, the first block in public blockchains is very important because you base what you're going to follow on that. But that's all kind of hard set in the code by the time you get it. Right. Yeah. So remember, I said that there were two cryptographic operations that you kind of had to have a sort of a feel for. There is another one that we're going to jump into here. Now, all of what we've seen so far has just relied on this one-way function called a hash. We have an issue though, what if I don't want to put my name or my identity or something that I want to kind of, you know, step away from that somehow.

27:12Okay, so the other cryptographic primitive that I want to introduce is this concept of public and private key pairs, okay? And I'm going to be slightly hand wavy on the math behind this, but I will show you the the truth that it allows. So this is a private key. Okay, it's a pretty long one. And from this private key is derived a public key. Okay, this is many digits long, right? But you could be anything. The one is a private key. It's not a very good one because other people have thought of one before, right? You can just type whatever you want and that's also a private key. It's probably not great because humans aren't very good at coming up with randomness.

28:01That's why I put this little random button. All right, I can press this random button a bunch of times and get some value for my private key. Now, a private key is literally just a number. And as the name would suggest, though, it's a number that you want to keep private. You don't want to ever tell anyone this number. OK, this would be like your email password, right? You don't want to tell people your email password. However, from this private key, I derive this public key. And as the name would suggest, this is public, like my email address. I would want to give you my email address. So the math behind this, as I say, you have to take it on faith that that actually works.

28:45But let me show you what this allows us to do. Let me just add also the public key that you're looking at. You see letters and numbers in it, but that's really just a number. it's just represented in hexadecimal base 16. The short, simple version of it is you can put more digits, more representations of numbers into a shorter space. What you're looking at at the top and what you're looking at the bottom are both just numbers just expressed in a slightly different way. ED HARRISON Yeah, that's exactly right. Great point. These numbers can literally be hundreds of digits long. You want to compress them if you can, so you can see them.

Read the full transcript

29:24Okay, so let's look at the way that this public private key pair can be used. All right, so what I'm going to do is I'm going to make a message, you know, hello there. Just some message, and this could be something that I, you know, I just want to prove the authenticity of, okay? Nobody really cares about hello there, but we'll use it. So here's my private key. This is copied from that last screen, 3.7a, whatever it is. This is my private key. And I am going to, using this private key, run it through some math that spits out a message signature. Okay? Okay, so now this, don't get confused about the SHA-256 hash thing.

30:13This is a signature of this data, but it requires, you know, the original message to be exactly the same and something else. Okay, so we'll see what that is. If I flip over to my little verify screen and I take my exact same message and now the public key. So this is something that anyone out there on the internet can do. We can take the message that you've posted, and we can take your public key, which you've told the world about, and then you can send along the signature that we just made, and you can run an operation called verify. And sure enough, that verifies. You create a message, you sign it with your private key, and then you post that digital signature.

31:00And then anyone who has your public key, which is posted for everyone to read, can verify that you, in fact, are the person who sent the message and that it hasn't been tampered with or modified in any way. That's exactly right. But only by using your public key, they don't have to use your private key to figure that out. And that is the core piece that the public-private key pair enables you to do. So as long as I haven't leaked my private key, you have high confidence. Well, I'll just say you have absolute confidence that someone in possession of the private key, presumably me, has signed this message.

31:43So now if I alter the message and hit verify, it's not going to work, right? I'll fix that. If I alter the signature, right, I'll make that a four. That won't work. So you get the idea. If anything is out of place, it's going to notice that. OK, so now here is the here is how we're going to bring this into our our blockchain. What I'm going to do is instead of the message being, you know, I typed hello there. Instead of that, I'm going to say the message is a transaction. So it is literally like I'm saying,$20 goes from some public key, mine, to some other public key, yours. And I am using my private key.

32:41It's the private key behind my public key. I will use this private key to sign this message, which is just the concatenation of these three things up here. So I'm going to hit sign and I get some message signature there. Great. Now, how do you know that you got paid, right? Well, you verify. So I'm giving you the message. It says$20 is going from my public key to your public key. You already have my public key because it's in the message. all you need to do is check this stuff against the signature that I've also attached and you'll find out that it works now you could just steal you know a hundred dollars from me right no you can't I pose the transaction that I want to send I sign it and then it's valid okay so if we were now to take this concept and place it on the blockchain suddenly we don't have that problem where it says anders got this amount of money and uh you know transferred it to ash or whomever right so let's look at block number five here again so so it's got some kind of a nonce And here we are, the same is getting kind of folded over a little bit, but you see that this is a Coinbase transaction to some public key.

34:15Whose is that? I don't know. Can that one person have many public keys? Yes. So this is a set of transactions that are being posed from some public key to some other private key. And importantly, also in the blockchain, I'm adding the signature that proves that I did that. Okay. So watch what happens if I change this to$8. Of course, it breaks the block. The block is no longer valid. But also notice the signature is red. The signature doesn't check out anymore. So we have multiple things we can check for correctness in these blocks to make sure that the money flows properly. This gets to the Bitcoin concept of a pseudonymous blockchain.

35:12So we're moving money around between public keys. And we're just requiring that the people behind them have signed the transactions correctly. And if somebody goes in there and tries to change$7 to$8, it's not going to work. It's going to break. So only the people that have the money are allowed to, you know, will create a signature that will be accepted, will create a transaction that will be accepted. So in that sense, this whole system operates as a push, you know, a push financial system. People that have money may push it to others. And importantly, all you have is a private key. all you have is the permission to push the money you actually don't really have the money it's just that no one else can push it but you right um so that's that's sort of the that's sort of the other way uh to think about it now one last thing and then and then and then i'm i'm done here but uh there is we do have a little bit of a problem and that is if you give me seven dollars you could just take the original signature and repose exactly the same transaction again and again and again, and you would keep getting$7.

36:31And you'll notice that that's what I've done. I've got$7 here and then$7 here to the same keys. Well, what I've also added to this is a sequence number, and I'm going to require that the sequence number is always unique, always stepping up by one. So the sequence number over here is two. That makes this signature actually different than this one. So you can't just replay the same transaction over and over. So that's a blockchain. You didn't have to learn about encryption. There is no encryption. It's just two cryptographic primitives, a SHA-256 hash and a public and private key pair with signing.

37:19So that's how blockchains work internally. Now, this is a bit of a demo. I don't have many, many nodes. I'm doing very simple mining. You're seeing we're looking at four zeros in Bitcoin. That's 10, 15, 18 zeros in a row. So these are not numbers that you can come by easily. It's not really going to compute on my laptop. So this is somewhat of a toy blockchain. Also, the Bitcoin blockchain uses UTXOs, which is, you know, my little example here is more like an account model. There are some, you know, you can definitely dive deeper than this. But I don't think those, you know, differences are quite as important as sort of highlighting these.

38:10So that's how I got to it. Yeah, I mean, the extraordinary thing about this is you can build up an understanding of how this works block by block, pun not intended, as you walk through this demo. And the really incredible thing about it, Anders, is you've created this, you wrote this demo. It's now out there on the internet. Anyone can go up and play with it and do exactly what you did by changing transactions, entering values, and actually see, physically touch how it works and go through those steps just as you did? Yeah, this is actually up on my website. You can just go there and try, you know, messing around and changing numbers and, you know, seeing things break and stuff like that.

38:51This is all available. I actually open sourced the data and the code behind this. And a bunch of people have translated it to a bunch of different languages. But the origin story of this thing is, I think, interesting. Back in 2014, MIT asked me to teach this class, and it happened to be starting in two weeks, and oh, by the way, we don't really have a syllabus yet, so would you do it? And so I said first yes, and then I just stayed up all night trying to figure this out. When I was done with teaching that semester, I didn't feel like I actually transferred the information appropriately. So I started working on this demo.

39:40I ended up presenting it at the Federal Reserve Bank of Boston, strangely enough, at a Hub Week demo. And I honed it over time at Yale and a lot of classes at MIT, a lot in the Sloan School. And eventually, I got it to a point where I could actually just explain just the important points. It took about two years. And then I was in my kitchen and I recorded it on my iMac as a movie. And I thought, I should put this on YouTube. So I did. And I wasn't really quite prepared for the response. But it just kind of has an interesting backstory to it. Yeah, you got over a million views of this, which is pretty extraordinary.

40:24Yeah, I don't know where that came from. It just trended. I think it was on Hacker News one day and it just kind of took off from there. By the way, I should say, I was absolutely mesmerized the first time I saw this, but I didn't fully understand it. It took me days and I think weeks of going and watching the video again and again. And that's pretty amazing thing about video, I think, is you can see something and be like, wow, that's really cool, but I don't quite understand it. And you watch it two or three times and somehow almost magically, by the fifth or sixth time you watch it, the second or third time, if you're a lot smarter than I am, you go, I kind of get this.

41:00It's pretty amazing. RAOUL PAL, Did you ever mess with the demo on the web at all, or was it just video? RAOUL PAL, Oh, yeah, absolutely. I went back and forth between watching the video and drawing out the demo, experimenting, doing your data, watching the video again. Slowly but surely, after I kept playing with both, it started to sink in. You have these little epiphany moments. Then what was interesting is I would understand it while I was watching it, and then I'd try and explain to someone because I was so excited. And I'd get completely goofed up and realize, nope, I got to go back and watch it again.

41:32It definitely takes time. These are some really, really big ideas. And some of the smartest people in the world, some of the smartest people in finance have struggled to get their heads around this. Yeah, it's one of those things that it's really basically a complete rethink. This doesn't come out of a computer science program. It's very multidisciplinary. There's economics, there's basic human greed, there's cryptographic stuff, and it's all kind of put together in a very interesting and unique way. And it requires you to deep dive. Everybody says, how'd you go down the rabbit hole? Well, you have to go down the rabbit hole.

42:14You cannot just take it all on faith that this stuff works because you won't understand why we can be completely confident that the history has not been changed. This is why we can completely be comfortable, to some degree, in DeFi and how smart contracts work, because they're just written literally right into the blockchain. So you have confidence that they won't be altered. You don't have confidence that they don't have bugs, but you do have confidence that what has been written will not be altered. Right. I should say, for Real Vision subscribers, I actually did a deep dive on some of the underlying math that we're talking about here, talking about the power of randomness, how difficult it is to break these passwords with your former MIT colleague, Silvio McCauley.

43:06So if you're interested in the deep dive nerdiness on the math, please do go check out that video. Absolutely. It's really super fun stuff. I mean, it's captivated me for 10 years at least. So I'm smitten. So Anders, we've walked through this entire demo, end to end, both demos together for the first time ever. Really extraordinary work that you've done here. Give us some key takeaways for the audience, if you could, because this has obviously been a lot of information. What are some of the big picture things that people should leave this conversation with? Well, my hope is that I haven't confused you, right?

43:46The technology is actually a bunch of very simple building blocks put together, and you can get it. You can understand this stuff. It is reachable. You don't have to delve into the deep math behind it, but it is reachable. It is just a complete rethink. So the important things are, I would argue that there is a new trust layer on the Internet enabled by these technologies. and that allows us allows programmers to do really new and interesting things but in order for you to have confidence about that you kind of have to have a like a seat of the pants feel for like this is why I am confident that this information won't change or something won't just be you know swapped out from under me.

44:37It's both an economic system in the sense that my miners out there on the network are being incented by receiving that Coinbase transaction and in some networks fees as well, to create these blocks. And, you know, if someone decides to go rogue, they essentially risk wasting all of their resources to create an alternate view of the universe that nobody follows. So it's a network effect kind of a thing. The more you get, the more nodes there are, the more hashing power you have, just trying to find that needle in the haystack nonce that makes that block solved, the more that there is, the more confident you are that this is not going to be subverted out from under you.

45:40So yeah, those are the takeaways, I think. Yeah, you were saying earlier this idea that it's a multidisciplinary approach. One of the things that's so interesting about this to me is how it just builds on layer after layer of technology, the underlying TCP IP that runs the internet. Obviously, you need that as the very base of your stack. But also, the kind of peer-to-peer aspect of this. It's really interesting. We think about the music sharing software that came out in, I guess it was the late 90s now, hard to believe so long ago. But that idea that you have different peers on a network that can interact with each other, and then you build layer upon layer until you get this incredible system in the form of Bitcoin and some of the other coins that we have out there, all based on these technologies like TCPIP and the peer-to-peer network of Napster, public key cryptography.

46:31It's just such a fascinating agglomeration of things put together. And what you have at the end is the ability to share value, to share money, financial transactions across the web globally in a trustless way. Yeah, I think the word is elegant. And this is why it's so captivating. You sit there and look at this and you think these completely disparate cryptographic things create just this elegant thing that hangs together and gives you this brand new capability that this is a new sort of a primitive that we haven't had as programmers more than 10 or 12 years. So it's quite compelling. Yeah, well, if you're anything like me, I certainly didn't get it the first time I went and watched the video.

47:24So please feel free to watch again and again. And by the way, I should say, if you have friends and family who you've tried to explain this concept to, but gotten caught up as I have, you start to get into it and you go, Wait a minute, maybe that's not quite right. Please share this video so we can get Anders' great work out to as many people as possible so that we can share the understanding and the passion that I and you and so many others have for this technology. Yeah, thank you. Please do. Don't get lost in the weeds. Nobody likes somebody trying to explain something if they're lost in the weeds.

47:59I get lost in the weeds too much, so hopefully it helps. Anders, thank you so much for joining us. I wanted to do this conversation for years, and I'm just so excited to get this information, this demo that you created out to the world to an even broader audience than the millions you've already had see this work. Well, my pleasure, and thanks for distributing it. I think it's very fundamental stuff we all should be aware of. Thanks for joining us, and thank you for watching, everyone. I hope you enjoyed Andra's work a tenth as much as I have. Thanks a lot. So, Ash, it's been a couple of years since I watched this, but God, it just blows my mind every time.

48:38It really speaks to how some of these technologies really have to be seen on the base layer to understand. What were your key takeaways from it? Well, that's exactly right, Nico. You said it perfectly there. You have to really see it at the base layer to understand how it works. And I think once you understand how it works, it gives you a sense of how this is truly a decentralized technology that drives things in a way that doesn't require governments, centralized institutions, corporations to come to that consensus, to come to that trust layer. You know, my biggest key takeaway on this was if you didn't get it all the first time, don't worry, I didn't either.

49:13I think I had to watch it three, four, five times before I really understood it. But just the first time, there was this kind of like mind melt effect where you get this sense of, oh, man, this is something that's just incredibly powerful. So I would advise if you didn't understand it, go back, watch it again. There's certainly no shame in it. God knows I did it. Absolutely. And it really is interesting because everything else we've talked about on this Friday series of Asking for a Friend relies on this base layer we just saw. So thank you so much, Ash. We'll see you next Friday for another episode of Asking for a Friend.

49:44And we'll be back next Monday with our regular scheduled interviews. Thank you for watching, everybody. What's up, revolutionaries? Thanks for tuning in. For more content like this, head over to realvision.com and get unfiltered access to the very best, brightest, and biggest names in finance.

From the publisher

Asking for a Friend continues this Friday with Real Vision's own Ash Bennington and Nico Brugge realizing they might have jumped the gun getting into all the degen fundamentals. So we're pulling it back and going deep into how blockchains actually work with this special re-air of our classic piece with Anders Brownworth.
Learn more about your ad choices. Visit podcastchoices.com/adchoices

More from Raoul Pal: The Journey Man

All 379 episodes
Understanding Blockchain Basics: Asking for a FriendRaoul Pal: The Journey Man · 53 min
Listen in VO