Questions tagged [witness-data]
35 questions
14
votes
2 answers
Why is witness data downloaded during IBD in prune mode?
Why do pruned nodes download (segregated) witness data during IBD if much of that data is marked as Assumevalid?
These nodes seem to be downloading witness data just to prune it. Since we already know that such witnesses are valid, and we plan to…
Son Kaos999
- 349
- 1
- 13
12
votes
2 answers
Follow-up to Segwit: Arbitrary data storage in witness?
In 2017 a question about Segwit: Arbitrary data storage in witness? asked whether people wanting to store more data in the blockchain than OP_RETURN allows could instead store data in the witness components.
The answer there stated that such a…
RedGrittyBrick
- 24,039
- 3
- 23
- 47
10
votes
2 answers
How do virtual size, stripped size and raw size compare between legacy address formats and native segwit?
This answer states that SegWit doesn't reduce transaction size. If this is true, why is it cheaper to send a SegWit transaction?
ecurrencyhodler
- 188
- 1
- 9
8
votes
3 answers
What is the Witness and what data does it contain?
I've learned about the Segregated Witness but couldn't find info on breaking it down.
I know usually when legacy addresses are used the public keys for example will be under Scriptig. With P2SH, I can see that the ScriptSig contains the hash of…
Robert
- 351
- 3
- 15
5
votes
2 answers
How does a SegWit node verify a block?
I know that non-SegWit node could verify a block without witness.
For SegWit node, is witness necessary to verify a block? Because I know witness are committed as wtxid merkle node in coinbase. What's the purpose of the wtxid merkle node?
If witenss…
fjchen
- 91
- 3
5
votes
2 answers
Is a transaction with a non-segwit input STILL considered malleable? If so how?
Below are a few examples of witness malleability, along with reasons why I believe they are no longer valid:
DER Malleability
For every DER signature with (r,s), there exists 2 valid 's' values -> BIP146 requires low 's' only
scriptSig…
Peter
- 115
- 5
3
votes
1 answer
Where is the witness data stored in the raw block data
I can see in BIP-141 where the merkle hash is stored. And I think its clear that the witness data won't be streamed inline with the TXN data. So I assume the witness data is simply thunked on to the end of the raw block.
Is this something so…
Dan
- 451
- 2
- 8
3
votes
1 answer
Redeem script. script hash, witness script and witness program
I have a little confusion about naming in Bitcoin.
Redeem script is the conditions that will be satisfy.
For example P2PKH inside P2SH
OP_DUP OP_HASH160 OP_EQUALVERIFY OP_CHECKSIG == redeem script
In P2SH-P2WPKH the redeem script…
monkeyUser
- 960
- 1
- 7
- 18
3
votes
1 answer
Confusion about Addresses
I have a little bit confusion about addresses segwit and not segwit.
I can see P2WPKH and P2WSH from this link https://en.bitcoin.it/wiki/BIP_0173, and they are segwit and start with bc (mainnet) or tb (testnet).
But I can see even P2SH, start with…
monkeyUser
- 960
- 1
- 7
- 18
3
votes
1 answer
Why does a same transaction signed separately have different witness values?
I signed a bitcoin testnet transaction using nbitcoin library and got an output:
…
Akshay Dev
- 75
- 6
3
votes
1 answer
Would signature aggregation reduce the largest feasible blocksize
If a Schnorr signature aggregation scheme were to be integrated into Bitcoin. Would the reduction in witness data versus non witness data (need less bytes for a signature therefore witness data usage would go down per tx) create a lower upper limit…
Bertram Lund
- 671
- 3
- 7
3
votes
2 answers
Why is the wtxid considered malleable?
Why is the wtxid considered malleable since the transaction is unconfirmed?
How can a third-party modify it?
dc_Bita98
- 394
- 3
- 14
3
votes
0 answers
Parsing a SegWit transaction, what are stack items in witness data
For every input we can have multiple stack items, what do these represent?
As a reference this question is helpful
Are these defined here?
For eg. P2WPKH would have a signature followed by a pubkey, (so two stack items)
Albert S
- 1,600
- 10
- 21
3
votes
1 answer
What is considered witness data in SegWit?
What fields in a transaction are considered witness data? I need this to calculate the vsize for fee.
My understanding is these are marker, flag and witness (from 1 and 2).
Or is it just witness, without marker and flag?
Did try to look in source…
WebOrCode
- 323
- 7
2
votes
3 answers
Calculating the witness size of a transaction
I want to calculate how many % of a block, and thus, transactions that are witness data. I need to calculate the size of the witness data in bytes in every transaction. And as I understand it, I cannot calculate this using existing size variables…
Jonas Svensson
- 33
- 3