Witness data is given a discount in terms of fees paid to include that specific type of data in the blockchain. There are very good reasons for that.
This year has seen a massive upswing in demand for the limited space available within bitcoin blocks, leading to higher fees for on chain transactions. Much of the demand is for transactions revealing inscriptions. The contents of these inscriptions are revealed as part of the witness data (1) of a bitcoin transaction. This witness data is discounted to one quarter the cost of other transaction data. Why are we giving these inscriptions a discount? Should we soft-fork out the witness discount?
Why are some bytes cheaper than other bytes?
Let's look at the cost of transaction inputs and outputs with and without segregated witness:
Type (2) | Output Bytes | Input Bytes | Witness Bytes | Input vBytes |
---|---|---|---|---|
P2PK | 44 | 112 | 0 | 112 |
Bare 2-of-3 | 106 | 186 | 0 | 186 |
P2PKH | 34 | 146 | 0 | 146 |
P2SH(2-of-3) | 32 | 293 | 0 | 293 |
P2WPKH | 31 | 41 | 107 | 67.75 |
P2WSH(2-of-3) | 43 | 41 | 252 | 104 |
The first thing to note from this table is how the witness script types (P2WPKH, P2WSH) have nearly the same number of input and output bytes (which are charged a full vByte each). The spender of a witness script is then charged 1/4 vByte for the data authorizing the spend, much of which is not verified for any but the most recent transactions, and none of which has an ongoing cost in the UTXO index. The other thing worth noting here is how the cost of using a more secure 2-of-3 multisig compared to a single signature is reduced from 147 vBytes to 36.25 vBytes.
Inscriptions are revealed in the witness, so they're only charged 1/4 vByte per byte of inscription data. Is this an abuse of the witness discount? The truth is that inscription data is some of the cheapest data for nodes on the network to validate. The script structure used by inscriptions explicitly skips execution of the inscription data, so the only verification done on it is a single hash check (ensuring that the revealed inscription is what the inscriber planned to reveal). This data is hashed once and then never looked at again by nodes. It has a very low computational cost (an order of magnitude lower than an equivalent size multisig script).
But inscriptions are driving up fees and pushing out other users.
Yes! With the current software available for interacting with the bitcoin network, inscriboooors have greater economic incentive to make their inscriptions than many folks have to make other transactions.
This throws into stark relief the value of increasing the economic density of bitcoin transactions. The Lightning Network takes a huge step toward this by enabling hundreds, thousands, or millions of economic transactions to be packed into a single bitcoin transaction. The greater the economic density of each byte in a transaction the lower the fee paid for that economic activity. As the economic density of bitcoin transactions increases, other uses of block space have been and will continue to be priced out (3).
(1) The term witness was adopted into bitcoin from cryptography jargon where it refers to data needed to efficiently verify a cryptographic claim. BIP141 defines it as any "data required to check transaction validity but not required to determine transaction effects". Cryptographers may have picked the term up from manufacturing witness marks used to efficiently verify the alignment of components.(2) Assuming the use of compact public keys and 71-byte low-R/S DER signatures.(3) Anyone remember Satoshi Dice?