Questions tagged [p2wpkh]
Pay to Witness Public Key Hash is the native SegWit v0 single-sig output format. P2WPKH addresses are Bech32 encoded and start with the prefix `bc1q`.
61
questions
1
vote
1
answer
94
views
Is it possible to "label" Segwit spendable output ScriptPubKeys with arbitrary bytes?
If one created a Redeem Script for a transaction output following a P2SH-P2WPKH pattern but with bytes prepended, something like:
OP_PUSHBYTES_8 41206c6162656c2e OP_DROP OP_0 OP_PUSHBYTES_20 <20 ...
3
votes
1
answer
57
views
What's the reason for the scriptCode format for a P2WPKH? (BIP 143)
When signing a P2WPKH input, the P2WPKH locking script is converted to the pattern of a legacy P2PKH when creating the scriptCode.
From BIP 143:
For P2WPKH witness program, the scriptCode is ...
2
votes
1
answer
114
views
Exact witness requirements for a segwit transaction with P2PKH and P2WPKH inputs
Segwit transactions can mix segwit and non-segwit inputs:
Segwit transaction from mixed addresses (segwit and non-segwit)
Can I build a raw segwit transaction with no segwit inputs?
But how exactly ...
0
votes
1
answer
93
views
Why can I not find my transaction in the mempool?
I built a native segwit raw v2 transaction with the pwpkh addresses, and get the decoded transaction as the follows
{
"version": "02000000",
"marker": "00",
...
-1
votes
1
answer
64
views
How does one verify signature in a P2WPKH transaction?
(Assume there's no OP_CODESEPERATOR)
For standard P2PKH, the signature digest is generated this way:
NewTransaction
settle the TxOuts well
set all TxIn scripts to empty
insert the Previous Locking ...
0
votes
1
answer
46
views
Incorrect Transaction ID being calculated for a p2wpkh transaction
RAW Signed transaction (signet)
...
0
votes
0
answers
59
views
bad data structure cause "Signature must be zero for failed CHECK(MULTI)SIG operation"
i could not fix the problem using available answer for this error on BSE. this is my previous transaction. i test alot of different data structure which was said to be the correct one but i got ...
0
votes
1
answer
97
views
I Get "Non-canonical DER signature" Error
it was asked few times in BSE and they were pointing the problem to the sighash which was not appended to the transaction but i did it and still have problem. i had a problem with amount of fee and ...
2
votes
1
answer
117
views
the purpose of the field before signature in P2WPKH
what is the purpose of that 02 in this P2WPKH transaction :
01000000
0001
01
d6f3994ab779ac849996a6235699ced672fa4b8334f825a2f1fcb4081c5b0c62
00000000
00
ffffffff
02
1027000000000000
16
...
2
votes
1
answer
222
views
What is the content of ScriptPubKey for P2WPKH?
What is the content of ScriptPubKey for P2WPKH?
Master bitcoin book 2end edition says the following (link):
Example P2WPKH output script
0 ab68025513c3dbd2f7b92a94e0581f5d50f654e7
In programming ...
2
votes
1
answer
221
views
How can I spend a mix of UTXOs (p2sh, p2wpkh, p2wsh) along with a p2tr UTXO?
I'm constructing a script to spend multiple distinct UTXOs in a single transaction. I've successfully combined all UTXOs except for two.
Succeeding in spending a P2TR with P2PKH UTXO.
I encountered a ...
9
votes
1
answer
1k
views
Is there an economic incentive to switch from P2WPKH to P2TR?
I have multiple times seen people argue that there is “no economic incentive” to switch from P2WPKH to P2TR. I know that the sum of input and output weight on P2WPKH and P2TR are very similar, but how ...
1
vote
3
answers
90
views
How can clients know the destination address for this P2WPKH transaction?
This is the raw hex of a random transaction I picked up on the blockchain:
...
1
vote
1
answer
86
views
Is there authoritative documentation on how to generate a P2WPKH address?
I Googled and found some BIPs but looking through bitcoincore.org, I could not find documentation on the process to generate a P2WPKH address.
Looking through other random articles, I see the process ...
0
votes
1
answer
70
views
How can I optimize my python script that creates a btc native segwit tx with an OP_RETURN message?
I have the following code that successfully created a bitcoin transaction with an OP_RETURN message:
from bitcoinutils.utils import to_satoshis
from bitcoinutils.setup import setup
from bitcoinutils....