Don't have enough time to read all the best articles on Bitcoin in the crypto economy. Well, let me read them for you. This is a crypto Connie quick read. The L2 protocol is an update to the lightning Network that could really simplify and streamline the channel process in lightning and that is what we are reading about today and who better to go to for breaking down this new development for us other than Aaron van Werdum and Bitcoin magazine. I'll have some great additional things to explore in the show notes. Thanks to the interview. We had with Aaron and a few other things. Also, don't forget to check that out. But let's go ahead and jump into the no input class how a Bitcoin soft work could simplify lightning? Bitcoins lightning Network the overlay protocol or fast and cheap transactions consists of payment channels these payment channels today rely on a somewhat complex fallback mechanism to keep everyone honest and require some level of alertness from its users. This could be simplified a small group of Bitcoin and lightning developers is working on a new class of Sig hash. Bags with names like Sig hash underscore. No input Sig has any previous out and cig hash any previous out any script one or several of these could see deployment as a soft work protocol upgrade in the not-too-distant future to help streamline the lightning user experience in two big ways. Here's how The no input class any Bitcoin transaction consists of several pieces of information these for example include inputs the data that unlocks coins outputs which lock the coins up again specifying what is needed to spend them in the future and more additionally at least one cryptographic signature is added the signature corresponds to the public key and thus the Bitcoin address of the coin. Being spent so it proves that the coin owner indeed wants to spend them the Signature Signs the new transaction proving that the owner agrees with how the coins are spent. However, this signature does not need to sign each part of the new transaction using a cig hash blag, the creator of a signature indicates exactly which parts of the transaction are being signed for example, While Sig hash all indicates that most transaction data is signed. Just not the signature output sick hash none indicates that only the inputs are assigned not the outputs. There are a few more sick hash flag. Now a new class of see cash Flags is being proposed. No input any previous out and any previous out any script which will refer to in this article as the no input class this no input class indicates that the outputs and some other transaction data will be signed but not the input by not signing the input. It is possible to take a transaction even after it is signed. And rewrite it to swap in a different but compatible input without having to generate a new signature. Of course more often than not there wouldn't be any other compatible in put the signature still corresponds to a specific public key in this public key should be associated with a specific coin swapping in a random input would break this link and make the transaction invalid. But there are some exceptions where the input can be swap. The undesirable scenario first an undesirable scenario while it is discouraged. It's possible to accept several transactions on the same Bitcoin address protected by the same public and private keys. If the same address is used to accept two transactions worth say one Bitcoin each. This does result in two different outputs. These two different outputs could normally be spent only through two different inputs in follow-up. Actions. However, if one of the two coins is spent with a no input signature that signature doesn't specify which of the two outputs is actually spent and the signature corresponds with either they are protected by the same public and private keys. This means that someone can rewrite the transaction even after it is signed to swap in the other input there by spending the other coin in fact the same. Transaction could be copied and Rewritten to be broadcast twice with the same. No input signature claiming both coins, even when the cinder meant to spend only one this would be undesirable indeed and it is why the no input class is not intended to be used in regular wallets, but there are also desirable applications of the no input class. L2 the first and most important potential application of the new Sig hash class is an alternative type of payment channel for the lightning Network. All lightning channels are really just unbraid casted transactions that spend funds from an address shared by two users these users update the channel by signing and exchanging new transactions from this shared address every time a payment is made or forwarded between them. The latest quote state of the channel and on broadcaster transaction is the only real one broadcasting an older state would be cheating. Participants in these channels are currently kept honest through a setup that includes penalty transactions broadcasting an old state allows the channel partner to follow up with a transaction that claims all of the funds in the channel. This should and usually does suffice to keep participants honest. The problem is that broadcasting an old Channel State isn't necessarily done intentionally may also be caused by a software bug. Sometimes it can happen due to an honest mistake. Like a software backup gone wrong in these cases having all of your funds drained from a channel is a very painful punishment in some consider it to severe L2 proposed by block streams see lightning developers Christian Decker and Rusty Russell and lightning Labs L&D developer allow lewisham Takin offers an alternative with L2. Both payment Channel users. Hold onto a copy of the Shame on broadcasted transaction called the update transaction representing their funds in the channel. This transaction is signed by both users. So either can choose to broadcast it at any time and it will confirm on the blockchain if someone broadcast the transaction and it does confirm on the blockchain the funds can subsequently be spent in two ways one. Both parties can spend their share after a time lock has run out for example after a Week or two the funds can immediately be spent to a newer mutually signed update transaction indeed in L2 update transactions are chronologically numbered update transaction three can spend the funds from update transaction to and update transaction to can spend the funds from update transaction one, but not the other way around. This is actually already possible with the current bitcoin protocol. But because the inputs of an update transaction need to be signed specific update transactions can only refer to a specific output from a specific update transaction that came before it update transaction three could claim funds from update transaction to but not from update transaction one. This isn't very practical if there are say one. Hundred update transactions in the very first of these is accidentally or intentionally broadcast the quote unquote real Channel balance could only be restored by broadcasting all subsequent update transactions update transaction one spins to update to which bends to update transaction 3 all the way to 100 this chain of transactions would present a big burden to the Bitcoin Network and it would require many fees more or less defeating the purpose. s of using payment channels in the first place L2 is therefore really only useful if update transactions can be skipped. Update transaction 3 must be able to spend funds not only from update transaction to but also directly from update transaction 1. It's this skipping that requires the no input sick hash class by swapping the input. The latest update transaction can always be re-written to refer directly to any other update transaction and swapping input is possible because no matter which previous update transaction is picked in a payment channel. The required signatures are always from the same to users with the same to public. private keys an L2 example So here's what L2 would look like in practice. Let's say that Alice and Bob have an L2 lightning Channel open for a while and the channels state has been updated 100 times as such they both hold on to update transaction 100 which spins funds from Alice and Bob's shared address. It represents. The latest state of the channel and is signed by both of them both Alice or Bob can choose to broadcast this update transaction at any time in which case They can claim their share of the funds after say a week when the time-lock expires. It's actually more likely that they would opt for a regular Cooperative close. If they do close the payment Channel as they wouldn't have to wait a week to spend the funds but nevermind this for now now if Alice accidentally broadcasts and old Channel State say update transaction 13 and this transaction confirms on the Bitcoin blockchain. The funds are also time locked for a week during this. Week Bob can take update transaction 100 rewrite it by swapping the input to refer to update transaction 13 instead and broadcast this Bitcoin nodes and miners on the network see update transaction 100 and conclude that it is valid. It refers to a chronologically earlier update transaction and it includes valid signatures from both Alice and Bob as required. The output in update transaction 13. So once update transaction 100 is confirmed. Both update transactions are included in the Bitcoin blockchain with all the funds waiting in update transaction 100 or a week until both participants can claim their share though Alice and Bob could again speed this up with a Cooperative close. So despite Alice's mistake, the channel was closed according to the latest Channel state attributing to both Alice and Bob what they are owed without any further punishment and without requiring update transactions one through twelve and fourteen through 99 to be broadcast at all. lightning watchtowers L2 payment channels are useful in and of themselves, but they also benefit another lightning Network Innovation watchtowers to avoid being cheated on with or without L2. Lightning users. Must keep track of the Bitcoin blockchain to see if an old Channel state was broadcast. If that does happen they have some time to respond and correct the situation a week in the examples above currently without L to this response can Is of a penalty transaction which drains all the funds from the channel and lets the honest user climate importantly every previous state of the channel has its own unique penalty transaction. If a payment channel was updated 100 times. Both participants must hold on to 100 penalty transactions. That's 200 penalty transactions in total. There are some ways to reduce this data, but the difference is marginal. With L2. This is no longer necessary. No matter which old state is broadcast a payment Channel user can correct any of it by simply broadcasting the latest Channel State. Both users would only need to hold onto a copy of one and the same update transaction and rewrite it to swap the input if needed watchtowers in particular could greatly benefit from this watchtowers are a special type of service provider on the Lightning Network that monitor the blockchain for other users if they see a cheating attempt, they can broadcast the transaction that sets the record straight presumably in return for a fee. The presence of watchtowers would make cheating practically impossible. However, it Watchtower monitors and not just one channel, but potentially thousands or maybe even millions of channels. All of these channels are updated frequently and two new penalty transactions are created with each update. Thus the number of specific penalty transactions a watchtower must hold onto could quickly balloon. With L2 watchtowers would only ever need the latest backup transaction or each Channel a much more sustainable model making watched our deployment more feasible. deploying the no input class There are currently two concrete proposals for the new Sig hash flag class. The first one is no input initially proposed by Joseph poon and Thaddeus dry jie in the lightning Network white paper. It is now been drafted into a more concrete proposal by a see lightning developer for Block stream Christian Decker and formalized in Bitcoin Improvement proposal or VIP 118. No input was recently rebranded to any previous out any script by a Bitcoin core. Contributor for zap. Oh Anthony towns who is also proposed any previous app. There is a VIP for this set of proposals as well, but it doesn't have a VIP number yet. Both any previous out any script and any previous out or largely based on no input but are specifically designed to be compatible with Taproot. Another proposed Bitcoin core protocol upgrade on top of that any previous out signs a bit. It more transaction data and adds a feature designed to avoid the undesirable scenario described in the beginning of this article to prevent an input being swapped against a users will for example after accepting several payments on the same address this version of the Sig hash flag requires an additional signature called The Chaperone signature that does sign the input in L2 this chaperone signature could be created by either Channel. While this would be a bit more secure it prevents a third party from swapping inputs. It also makes the sick hash option more complex and be expensive. All in all while the idea of this new type of sick. Ash flag had already been presented several years ago. No input has really only been taken into serious consideration for about a year and any previous out and any previous out any script or proposed only some months ago so far no single specification of it has been definitely settled on Decker towns and other Bitcoin enlightening contributors are currently taking a conservative approach favoring. Peer review and room for discussion as such it is too soon to say win or if this sick hash class will actually be deployed on the Bitcoin Network though. It does seem likely that a version of it eventually will be for the sake of clarity this article left out or simplified some implementation details for a full specification of the protocols see the bips for no input and any previous out. Thanks to Christian Decker and Anthony towns for information and feedback. All right. Now that may have been a little bit technical for people. I know there's a lot of words in there. So I want to try to help break this down on because this is a really really fascinating change the lightning network. But before we do, let's go ahead and hit our sponsor. I'm going to get something to drink and we'll come back and I'll see if I can't break this down to make it a little bit more audio friendly. For anyone who has a podcast anchor cannot be beaten particularly for trying to get off the ground their entire platform is free. This includes unlimited hosting both in audio that you upload and how much your listeners download. I have uploaded an incredible library of audio now and I've never paid anchor a dime. In fact, they connect me with other sponsors and have run an ad consistently on my show. So they've paid For exposure to my audience that's really hard to beat even if we ignore that I can record directly in the app or my browser. I don't need any other software. If I don't want it I can edit at sound effects clips and they automatically published to all of the top podcasting platforms. I never had to do a thing. So if you were thinking of starting a show or already have a podcast, there's no better platform out there check out anchor by downloading the app or go to Anchor dot f FM today All right. So let's jump into this and first just a huge. Thank you to Aaron been Werdum for writing this piece as always and of course Bitcoin magazine.com. I'm actually wearing my Bitcoin magazine shirt at the moment and I've worn it to the meetups last couple of times. Excuse me. So I've been like low-key advertising for them for like a couple of weeks. But um, so as I've said before I really rely on Um a couple of Publications Bitcoin magazine magazine really being number one on what I should be digging more into like I like I use their sort of vetting process. So I've really really do like love they are just a wonderful resource and I cannot recommend them enough so Let's jump into this piece though. So I find that just the constant input output like explanations like because like those are the specific terms, but it's so hard to follow sometimes like I know I get lost sometimes even when I'm like trying to explain it particularly one like a current output becomes an input in another transaction. So like when you're referencing it in the transaction where it was created versus the transaction where it was spent, The same or it doesn't sound the same in the explanation. So I understand that this stuff can get complicated really hard to follow particularly in audio. So let's just start at the beginning and I'm just going to kind of walk through this article first. We'll look. What is the no input class and look. What are we? What are we talking about when we mean inputs and outputs in a transaction. So an input every transaction spins from an input and sends coins. To an output. So it's where the coins currently are to where they're going to go and that output also includes whatever instructions required to spin them. So and those instructions can just be the person with this public key needs to uh needs to sign to send them, which is just a normal transaction or it can have a time lock. It can have a couple of limits and restrictions. It can have a specific next output that you have to spend it, too. centers that are you can do all these funky things with the script and that's how you make the lightning lightning channel is it's a series of scripts for how the next time these coins are spent can be spent and that is all just in the output and the input is which coins are being spent and you know satisfying whatever instructions are required to get them out of said instead account or address whatever you want to call it in those instructions generally include or well then I guess they sort of have to what needs to be signed like what data needs to be signed how how much needs to be included versus how little needs to be included in order to validly release those Bitcoins to a new owner or validly take control of those Bitcoins. And that is the the Sig hash flag. Indicating which part of the transaction needs to be signed. So the main ones are and that he talks about briefly in the article are Sig hash all and that's the that's the default. That's just the all inputs and all the outputs are signed and therefore none of the data can be changed without invalidating the transaction in this is the very obviously the normal and secure way to transfer funds from one Bitcoin. Join address to another Bitcoin address then we've got sick hash none, which is essentially saying that none of the outputs are signed. I have to sign the inputs because the previous set of instructions the previous Sig hash still needs to be fulfilled and that's probably hopefully in my situation would say that only if I sign it with my private key does do these coins get unlocked so I still have to in the input because I have to have to unlock the coins that already exists in a box locked on the blockchain and but a sick hash nun says that nobody I like there's there's nothing it's attached to no specific output, which means that somebody could grab the transaction after I broadcast it and put their output in it and just spin the coins to themselves or the minor could do it or I mean literally anybody who has the information the signature is valid no matter what The output is set in because the Sig hash clearly says don't worry about the outputs. Just make sure that the original input is a conditions are fulfilled. So it sounds like it seems like why would the hell would you need that? Right? That's the seems a little bit bizarre. Well, it's actually used so that I guess sort of in like a like an aggregating way such that you can actually sign with your input like the where your coins are coming from, but you can also sign a list of other people's inputs. So like let's say you've just got one address that you're spending out and then there are nine other. Serpents who were going to do this with you while you can sign to make sure that all of those other inputs are included and you can have an organizer essentially sign the end result that says as long as everybody in this group all 10 addresses get signed with the Sig hash. None of all the individual parties and then someone and then you have like a organizing parties sign it with then the Sig hash all instruction. Well, then I can basically In to be a part of a large group of inputs that I can know won't change and someone else can delineate the output who's maybe like the organizer of this aggregate or something like that. But I know without the signatures of the you know, ten other addresses included it's invalid. So it's kind of like a as long as everyone else is spending all of these current bitcoin balances. Well then I don't care about any other any other outputs. And this is just using like special circumstances like this and then there is actually which was not mentioned to their Sig hash single which is kind of similar in use case in a sense, but I'm agreeing to if I'm saying Sig hash single. I'm moving a specific amount of Bitcoin to a specific place. So just like our previous example, except I am I'm adding an output Specifically and rather than just saying well you just put in whatever output you want. Well, I'm doing it I'm signing it with the available input to the transaction and saying this is definitely the output so as long as all of these other people who I'm including all these other inputs are signed as well. Well, I don't really care what they add to the outputs as long as Lead this amount gets sent to the one output that I did sign. So what is this useful for? Well, this is kind of more a explicit way of doing or a more secure from my standpoint of using the C cash none. It's a little bit more. It's sort of the same idea is that I'm going to make sure that I sign all of these inputs. So as long as these other parties sign as well that this transaction will be valid, but I'm also signing that I know. Exactly where at least one of the outputs will go I'm signing just that output and that output and that amount can't be changed. So a situation where we might use this is that let's say you and I are jointly paying for some lawyers like some legal service or something and we both want to contribute half a Bitcoin to this is going to be a one Bitcoin legal service of some sort and I'm going to contribute half of Bitcoin and you're going to contribute half a Bitcoin. Yeah, but currently I have a half a Bitcoin exactly in an address and you only have an address that has one Bitcoin. So you need to be able to include a change output because you're signing over a full one Bitcoin transaction, but I don't need to know or I shouldn't have to know what that change output is, and I shouldn't have to sign that change out because then we got like exchange information back and forth the whole bunch and agree on all this. Well, what if I just Sign my half a Bitcoin as a part of the input and then also sign that exactly one Bitcoin will go to this output the lawyer that we are paying and then you add your one Bitcoin address and because I'm using cig hash single and I've only signed the one output. Well, you can then just add your other output of your .5 Bitcoin paid back to you on to To the change address so that you've only spent one Bitcoin and you just haven't signed over one full Bitcoin when you're only trying to spend half a Bitcoin. And by the way, if I guess some of you may not know this obviously but any Bitcoin that are spent in an address you have to spend the entire balance of the address, you can't break that up. So if one Bitcoin is sitting somewhere on the Bitcoin Network when you sign it that full Bitcoin has to move I can't sign it for Just point one Bitcoin what I do on or what's happening on the back end is I'm signing if I'm going to give somebody point one Bitcoin is I'm signing to send point one Bitcoin to specifically this output and then point nine goes to a new output that is just also in my wallet. So it never leaves my control but I do have to sign it from the place that it was to the new place in which I control it. And of course that would be done with Sig hash all that's the one where I'm signing everything and nothing can change. Change and if anybody digits with it at all, well, then guess what you it's no longer valid. All right, and and then there's sick hash anyone can be anyone can pay which is a can be used in combination with each of the others for like a couple very specific things and like the ones say cash none and then sick - anyone can pay is one of those ones that's just like just just dumps Bitcoin Into The Ether anybody anywhere can Grab it and so it's actually can be used as like a proof of burn almost but none of that is important for this discussion. So we won't go that far into it. But I just kind of wanted to cover those a little bit just to give you a brief idea of kind of what's happening and what those tools are and these these Sig hashes are essentially the commitment to exactly what data in the transaction cannot be changed is signed and essentially stuck and this is part of the script like the the encumbrances. So like Opie like the opcodes then in that instance would like check Sig would refer to what the Sig hash flag is in order for checking the signatures. And then that's when you would go through your script on the which As need to be checked because then you could build a two of three situation where I have my inputs and outputs shined in a cig hash single you have one in a sick Ash single and somebody else does but you only need to fulfill two of the valid signature requirement in order to fulfill the script. So all of this stuff can be used in combination for even though there's not there's only a handful of these like sort of scripts and stuff like There's they're very limited. They're like Lego blocks, you know, like with 9 different shaped and sized Lego blocks. You can still build some pretty elaborate stuff and there's actually another one from Bitcoin magazine that I recommend reading mini script that is coming to bitcoin hopefully soon, which is another really interesting thing to dig into just because it simplifies the the language of the script in order to just make it Whole lot easier to understand like like so that you can clearly see that this part over here will not execute in except as a result of this other part where he's currently it's a little bit because it's like a stack language or whatever. It's really kind of hard to it's not intuitive to look at it and be like, okay. Well, obviously this part happens first and then when this x blah blah blah, you know, so many script is definitely one that I encourage you to actually go digging into if you really like this super techy stuff. So that leads us to the no input. And again, there's three different names for this hash the Sig hash flag, but they're roughly the same thing. They do have variations, but it's no input any previous out and any previous out any script. So these all commit to the output of a transaction exactly where the Bitcoin are going to go and who owns what so where does this where does the end result of what we've set up from our previous moving of coins the only available location for it to end up so I'm going to sign that I have an output that specifically says I get back, you know .5 Bitcoin if I agree. With this lawyer gets wrong and our goes wrong. And as long as it's being used with the same public key. I might not be so concerned. I'm just guaranteeing that I get my point five Bitcoin back, right whatever is valid from the joint address that we are dealing with here that requires both of our signatures. I know that I am only signing it in such a way. The definitely .5 Bitcoin is coming back to me. But that's what leads us to the possibility of the undesirable scenario and why we wouldn't use it for a normal transaction because let's say I've got a let's go back to our same agreement. You were spending .5 and I'm spending .5 to our joint lawyer and this is actually going to be in a to of to account until our business deal or whatever it is to get sorted out. Well while it's there. If I'm signing if we're signing this with just the with a no input signature well in the undesirable scenario, let's say I got .5 Bitcoin into an address, but then there was another situation like transaction that happened later where I got another point five Bitcoin to that same address will own the Block Chain as quote unquote unspent outputs, which is what they're called. They're separate. I have to refer to both of them in order to to spend the full Bitcoin but in if I'm only spending a half a Bitcoin I can just pick which one I want to refer to as my input. However, if I don't pick which one since they're locked behind the same public key the same address on the Chain. Well, as soon as I sign for one of them to an output that go somewhere. Let's say to the lawyer or something like that. Well since I'm signing the information, but Reading the input specifically that signature is valid if somebody else swaps the other point 5 Bitcoin in because it's behind the same public key and I didn't worry about delineating that it is exactly this one output that um that I can spend coins from so that would be bad if we use that normally because then reusing an address just means that signatures that I have already. Signed for completely different transactions that were on totally unrelated can now be used to take every set of funds that can be reused can be essentially recycled to continue moving any coins out of that address into the same output that I signed the first time because the output is the only thing that can't be changed. So in short where the coins come from just need to be the same public key and is not concerned with a specific. Transaction but instead any transaction to that public key, but where the coins going are going to is set in stone because I have signed the output but I have not specifically delineated what the input is or where the coins are coming from. But therein lies what makes this so powerful and what makes it such an Innovative thing So currently in channels and he actually goes through that they're actually already was a sequencing thing. In fact, Satoshi Nakamoto extremely early on like right at the very beginning of Bitcoin warts already talked about he developed really in a sense or were talking about at the very beginning of this thing the idea of payment channels and Sequencing of off chain payments but that was the problem with the simple sequencing system that he came up with them. That was a no more efficient in the case of a dispute than just normal transactions and the example that Aaron give gives in this article is that if we've updated the channel balance a hundred times, but then you publish the very second update which no longer has the valid balance. It doesn't have the ones that I own the only way I can prove that transaction 100 in this sequence is in fact transaction a valid transaction 100 is if I show that okay from to we agreed to publish going to address number three and then from three we agreed in both signed to send it to address for and etcetera ad infinitum until like you get to the end of the chain. So while a Operative clothes clothes would mean that okay. Yeah, we just broadcast transaction 100. Well, you could call such a headache and so much pain to someone during a dispute. It makes no sense. And it doesn't cost them anything. They could at least just try and then just see what happens when you try to cram a hundred transactions into the blockchain all at once and obviously we do nothing for efficiency or block space. In fact, it would make it worse because now you're using all these joint transactions and Joint signatures which make the data bigger. But that's what's cool about L2 and the use of this no input that rather than in the current state of things it is you have we have asymmetric transactions. We have one on my side like we if you and I now have a channel. Well, when we do an update transaction, we have one that requires you to wait that you have signed likely gives me a buffer to trust you that I am holding onto and then I sign A half of the transaction that gives you a buffer to trust me. So essentially I'm a I'm a holding a transaction that is more beneficial to me and make sure that I have an insurance policy and you have signed it and then you have one in the exact opposite that I've signed and that's how we know we can trust each other because we already signed essentially the fallback scenarios of each other's transactions, but we have different transactions. Which means we both need to keep up with hours individually or you know, there's a problem in like and then at the exact same time, we've got the other limitation of every single update along this channel. Let's say again, we've got a hundred update. Well, we have to keep the signed punishment Clause the sign-in signed insurance contract for each individual one so that because every time we update the transaction. Well, there's a new Outdated state that would now be available as a possible cheating opportunity. So, you know, if we only update three times, well, then there's two cases where someone could publish information that is a cheat and one case that it's valid. But if we got a hundred well then now we've got 99 possible cheating scenarios and again a single valid state. So I need to keep the punishment Clause this the insurance policy that you signed for me for all 99 of the others because if you publish Point our number 87, I got a publish punishment 87 But therein lies a bit of a limitation because there's a lot of risk there. Obviously, I could have some sort of a failure and lose some of the data what if the saving of transaction 100 doesn't work and I end up like rebooting and have some sort of a hard drive problem or software problem. And now I've only got transaction 99 well of my note, it seems to broadcast or attempts to close that channel now because you know, something has gone wrong. Wrong. Well now I look like I'm a hack like I'm trying to cheat my our agreement and I lose all of my coins. I was everything and again that's severe. It's a it's a huge incentive for honesty, but it's and it's a huge incentive for Hardware's and are secure hardware and backups and stuff. But it is also a rather unnecessary risk because I mean really like then I don't think there's still I have not heard. Other than example, I think of a actual malicious attempt to cheat a lightning Channel just because it's so it's so costly because of that punishment Clause but there have been numerous examples already of Hardware or software failures that caused the loss of all of the funds in a channel and both of those both of these situations are altered with the implementation of the no input sick hat. Each or of course any previous out any previous out any script what that means is that transaction 100. Now the the hundredth update to our payment channel is no longer locked to any previous update. It is simply its valid because of the output and the sequence number and as is a chronological sequence. So the latest action transaction 100 will be more will always be the valid one and more valid than transaction 10, but I don't have to have transaction 11 and then 12 and then 13 and 14 etcetera etcetera because I wasn't concerned with exactly which input was necessary to fulfill the output that I want and I can just grab the input from transaction 10, which does not affect the validity of the In at all with this new Sig hash because all I'm concerned about is that my output gets funded with the correct amount of Bitcoin. And now I can just use the update number 102 essentially invalidate update number 10. So that solves our sequencing problem. The other cool thing is that we no longer are holding a symmetric transactions. I'm no longer holding. You know my favorable half of the transaction and you're no longer holding your favorable half of the transaction is that we're actually holding the exact same data. So rather than every new update State having two separate transactions to keep track of and two separate punishment Clauses. We have one set of data that includes everything that we need and we've both got the signed copies of it and that's that part of it is how this is such a huge benefit to Ooh, watch Towers because go back to our hundred transaction updates and needing to keep a hundred punishment Clauses because I you know, I can't shout. I can't like let's say, you know, we've got our Channel together. I don't I don't necessarily know you or trust you. You might be real tsumiki malicious, you know, Dennis the Menace over here so watch it. Um, so the Watchtower has to keep every one of my punishment Clauses, but then he exact same time or keep enough. Go to restore the punishment details the the punishment part of the transaction one. They when they see the transaction ID of a previous one on the anywhere in that like group of 100, but also a watchtower has to store a either a different or the same Watchtower asked to store all the same punishment Clauses for the other party. So this not only immediately shrinks in half because we have the exact same data, but the exact same time it now it's now just one state for each channel. It's just the most recent one because now they don't need States 1 through 99 either and they only need one state or the final one. So it just it just the Watchtower ballooning of data requirement is just gone. It's just no longer there. It's just the it's strictly the number of backups are strictly. Did to the number of channels that are necessary and the Watchtower would need the most recent or latest update to the channel and that would be enough to essentially solve any dispute that happened at any point in that channel. Even if there's been 10,000 transactions to go over this channel has been open for a year. None of it matters. All we need is transaction number 10,000. And we can swap whatever input of the any cheat that happens from one to 99999 and grab that input place it into transaction 10,000 and it is it will validly give me back exactly the amount of Bitcoin that I am owed. So this is a really powerful change to lightning that simplifies as implementation simplifies its backup process mitigates. The huge risk in like a failure of Hardware or something like that and simplifies the network watched our model of essentially Outsourcing the the policing essentially of the channel participants. And that's just a really powerful tool in the creation of these new layers new network layers on top Bitcoin and another really the important thing is that L2, even though it seems like an improv very different construction of lightning is totally compatible. It's like I can have my traditional lightning connected to your L2 lightning and we can both use you can have your channels BL2 and then our channel is just my traditional lightning and there's there's no reason you can easily Bridge with you know, a normal lightning channel in the left hand and and Channel on the right. It's just a different risk tolerance. And that's that's why there is actually a little bit of pushback from this model because developers are the extremely adversarial conditions of Bitcoin and the nature of these open networks, like open Global Network. You don't want you want to make sure that incentives are aligned to punish bad actors and in the case of L2 the punishment Clause is really gone. Gone, it is no longer a part of it. So essentially there's not much cost for me to try to broadcast transaction 10, even if broadcast even if transaction 100 will invalidate it because I'll still get my coins when transaction 100 invalidates number 10, so I don't have much cost as a cheater to not try to cheat every single time. But you know, obviously that might mean that my reputation on the lightning Network as a reliable mode will go down significantly and probably no one will open Channels with me or accept channels from me. But regardless of that you're still you don't have any part of the actual contract that says I'm going to punch you if you try to cheat me essentially so there is still there is still a bit of a trade-off there, even though I think it's a much simpler and Really fascinating new piece of the extension of these protocols and the car continued development into making these things simpler simpler more secure and more failsafe against common scenarios. All right. So I think I think that'll wrap it up and it was everything I wanted to go through but a huge thank you again one final time to are invented. Mm and Bitcoin magazine.com and I cannot recommend them enough definitely check out Bitcoin magazine.com. Get your copy of the 10th anniversary edition on their store. They got a lot of goodies and a lot of the past like physical magazines is just something novel about that that I love. I've got three copies of the thing so I have Have every version of every use that I could have for it and have my um looks really nice so I can sit it out somewhere. And then the one that everybody's going to read and is kind of wrinkled and all messed up and then the one that never leaves its plastic. So I've got I've got every version or every use of this magazine covered and I highly highly recommend it. It's a great one and it's got another bunch of great articles by Aaron van Werdum in the magazine. So tons of other stuff to explore their and of course I will have listed in the show notes the article about many script from Bitcoin magazine, which is another great one to cover and maybe I'll do I'll connect some reading available to go a little dig into these opcodes and sit cache stuff if you really want to geek out on that for some time and lastly a link to an inventor Adams Twitter page and the conversation. That we had with him on the show, which was tons of fun and you'll learn so much about a guy's an amazing writer and he's been a Bitcoin for a long time. So he's got it fascinating things to say and I highly recommend that episode as well. Alright guys. Thank you so much for listening. I am guys Swan and this is the crypto economy. This is the podcast where you get audio versions of all the most brilliant works and developments in fascinating ideas in the Bitcoin and crypto Khan. Ami space and if you would like to support this show are two things you can do for me one you become a pet. You can become a patreon whichever. We've had a number of new patreons recently crypto dread Kirk and Jake a huge. Thank you to you guys and welcome to the telegram group and if anyone else wants to join that telegram group and help support this project of turning everything into all you version. It deserves in the Bitcoin space. Well you can do so at page. On.com slash the crypto economy as little as one dollar will get you in the telegram group and it goes a long way every dollar counts, but if you can't do that, the one thing that you definitely can do and that is much easier and less costly is to Simply share this out with everyone, you know in the Bitcoin and crypto economy space who is unable to read all of this amazing work and doesn't know that it's right here in audio ready. Them to consume. So thank you guys so much share this out subscribe. If you have not I'm God's one. We are out until next time take it easy guys.
Today we take a dive into the future of Lightning and one of the amazing developments to make it simpler and more reliable, the new sighash flags referred to as the "Noinput Class." Who better to take us through it than Aaron Van Wirdum & Bitcoin Magazine? Our recent interview with Aaron Van Wirdum, the extraordinary author of this work and 100s more: https://anchor.fm/thecryptoconomy/episodes/CryptoChat_018---Investigating-Bitcoin-with-Aaron-Van-Wirdum-e4rt9e  Don't forget to check out the original article for extra clarity on how it works, and of course for the many other great articles at BitcoinMagazine.com: The “Noinput Class”: How a Bitcoin Soft Fork Could Simplify Lightning https://bitcoinmagazine.com/articles/noinput-class-bitcoin-soft-fork-simplify-lightning Miniscript: How Blockstream Engineers Are Making Bitcoin Programming Easy(er) https://bitcoinmagazine.com/articles/miniscript-how-blockstream-engineers-are-making-bitcoin-programming-easyer  Other great reading for SigHash Flags and other Bitcoin scripting details: Raghov Sood's Blog post on signature types https://raghavsood.com/blog/2018/06/10/bitcoin-signature-types-sighash Bitcoin.org's Extensive Guide to Transactions https://bitcoin.org/en/transactions-guide#introduction  And Lastly don't forget to check out the cool stuff at the Bitcoin Magazine Store: https://store.b.tc/  Thank you so much to our recent patrons! If you would like to join them and the rest of the awesome crew in the Cryptoconomy telegram, become a patron and support my turning every great piece of Bitcoin & Cryptoconomy literature into the audio version it deserves. patreon.com/thecryptoconomy  ---   This episode is sponsored by  · Anchor: The easiest way to make a podcast. https://anchor.fm/app  ---   Send in a voice message: https://anchor.fm/thecryptoconomy/message 