Two questions about segwit implementation



Summary:

When a transaction is created, the creator may know which inputs are segwit-enabled, but validators have no way to tell until they look up the UTXO set. Validators only have access to the 36-byte outpoint, which does not provide information on whether the input is segwit-enabled or not. As a result, there needs to be a way to inform the validator that the witness for a particular input is empty. In response to this issue, Aymeric Vitte proposed that since the creator knows which inputs are segwit-enabled, they can parse the transaction to associate the correct input with the correct witness data without the need of "00" for non-segwit inputs. However, it is unclear if this approach would work in all cases.


Updated on: 2023-05-20T20:34:06.856012+00:00