What is SegWit and How Does It Work?

Welcome back to another beginner’s guide on cryptocurrency! I’m going to explain what SegWit is to you today. Hundreds of cryptocurrencies are on the market, and each has its own set of regulations that govern how it operates. This set of rules is a protocol. So, what does this all have to do with SegWit? What exactly is SegWit?

Cryptocurrencies, like any computer program, must be updated and improved. They resolved some bugs and issues. When your laptop asks you to shut down and correct, this is what happens. Adjustments must be made when a cryptocurrency’s protocol has to be upgraded or enhanced. Last year, they updated the Bitcoin protocol with SegWit.

In this article, I’ll explain all you need to know about SegWit. I’ll explain what SegWit is and how it works. I’ll also explain its enhancements to the Bitcoin network and what these enhancements signify for its users. After reading this guide, you will never have to ask yourself, “What is SegWit?” again.

What is SegWit?

Pieter Wuille initially proposed the SegWit protocol during a Bitcoin conference in 2015. Wuille is a Bitcoin creator and co-founder of Blockstream, a software firm specializing in digital security for financial services.

Wuille proposed SegWit as a fix for a weakness in the Bitcoin protocol. Patches are fixes to problems in software development. He wished to address transaction malleability. Transaction malleability is a geeky term for the ability to steal Bitcoin from users by modifying small parts of transaction information. Don’t worry. I’ll go through everything in greater depth in the following position.


Wuille’s SegWit proposal sparked heated controversy in the Bitcoin community, and it took nearly two years to become operational. They ultimately turned it on on August 23, 2017. On May 10, 2017, they implemented the identical change to the Litecoin protocol. SegWit, solved the transaction malleability problem while also allowing for certain additional Bitcoin protocol upgrades. However, it still has many detractors, and not all Bitcoin network users have welcomed the modifications. Some Bitcoin community members are so opposed to SegWit that they have developed their currency!

Before we get into it, let’s take a closer look at the issue of transaction malleability. So, what exactly is transaction malleability, and what is SegWit doing to prevent it?

Beginners’ Transactions

Lucy wishes to send Jude ten Bitcoin (BTC). Lucy and Jude will need two types of information to do this:

  • A public address is analogous to a Bitcoin email address. A public address is a digital address to which Lucy may transfer Bitcoin. Jude has a Bitcoin address that is open to the public. The entire network may view public addresses.
  • A private key: If public addresses are analogous to email addresses, private keys are analogous to passwords. They demonstrate that the public addresses, and the Bitcoin itself, belong to Lucy and Jude. Only Lucy has access to Lucy’s private key, and only Jude has access to Jude’s private key.

Let’s look at how the transaction appears on the Bitcoin network.

What is SegWit Transaction Malleability?

Using the same scenario, I’ll demonstrate how Jude can exploit transaction malleability to deceive Lucy into transferring him 20BTC instead of 10. Jude can modify Lucy’s witness data before the transaction verifies due to a transaction malleability bug in Bitcoin’s code. This changes the transaction ID but not the transaction itself.


When the network confirms this modified transaction, it cancels the original transaction. Now Jude approaches Lucy to complain about not receiving 10BTC, even though he has. Lucy checks and discovers that the initial transaction did not go through. She now adds a more significant transaction charge and resends it. The network handles this new transaction. Jude earns an