Questions tagged [p2wsh]

Pay to Witness Script Hash is the native SegWit v0 script output format. P2WSH addresses are Bech32 encoded and start with the prefix `bc1q`.

47 questions
7
votes
1 answer

In simple terms, what are the major differences between P2WPKH and P2WSH bech32 addresses?

I've read over the bip173, bip141, and bip143 specifications and they're a bit too technical to get at the simple answers I'm looking for.
kawthuldrok
  • 303
  • 1
  • 10
7
votes
1 answer

Support for P2WSH-wrapped P2TR addresses

Given that Taproot addresses use a new SegWit version and a new address encoding (bech32m), it's reasonable to expect a transition from the ecosystem to this new address version similar to what we saw for the P2PKH/P2SH -> P2WPKH/P2WSH transition.…
esneider
  • 308
  • 1
  • 4
6
votes
2 answers

generate a P2SH-P2WSH address and spend output sent to it

I am attempting generate a P2SH-P2WSH address and then spend an output sent to this address, but when I attempt signing I receive Invalid private key error from bitcoind (v0.15.1.0). So where am I going wrong I am not entirely sure that I generate…
Kristaps
  • 63
  • 6
6
votes
2 answers

P2WSH, witness_v0_scripthash: how to derive an address

Is there an address associated with P2WSH scripts? for testnet txid =6717c8971dccbf826790efc16fb357f1e225fed3448247b8556c9f13a6c0ce42, i get: "vout": [ { "value": 0.05994165, "n": 0, "scriptPubKey": { "asm": "0…
Albert S
  • 1,600
  • 10
  • 21
6
votes
1 answer

Will P2TR make P2WSH obsolete?

Assuming users have upgraded their wallets to handle P2TR outputs and trust the validation rules of P2TR, would there be any advantage of using P2WSH over P2TR?
Darius
  • 779
  • 4
  • 16
5
votes
2 answers

Why are P2WSH addresses larger than P2SH addresses?

One would, perhaps naively, assume that both addresses are hashes of scripts and therefore ought to be the same size.
Bertram Lund
  • 671
  • 3
  • 7
4
votes
2 answers

Using multiple penalty transactions to increase max HTLCs per LN channel

BOLT#2 states the below as one rationale to limit a Lighting Network channel to 483 HTLCs: It also ensures that a single penalty transaction can spend the entire commitment transaction, as calculated in BOLT #5. In other words: we're constrained…
3
votes
1 answer

Is the dust output limit the same for p2wpkh and p2wsh?

I've seen mentioned in a few places that the dust limit for an output to be considered standard is minRelayTxFee*3. Based on this, I would expect the dust limit for a p2wsh output to be larger than for a p2wpkh, since CTxOut for p2wsh is larger (43…
Darius
  • 779
  • 4
  • 16
3
votes
1 answer

Can a coinbase transaction have a segwit output?

And more generally speaking, are there any restrictions on the output of a coinbase transaction?
3
votes
2 answers

How to calculate P2WSH signatures with OP_CODESEPARATOR?

I read the bip143, but didn't understand how to calculate the scriptCode of p2wsh. bip143 told us: A new transaction digest algorithm is defined, but only applicable to sigops in version 0 witness program Double SHA256 of the serialization of: 1.…
jumper
  • 31
  • 2
2
votes
0 answers

spend founds from p2wsh address,non-mandatory-script-verify-flag (Signature must be zero for failed CHECK(MULTI)SIG operation) (code 64)

i want spent coin from p2wsh address on btc testnet3 network, i use bitcoinj 0.15.2 build transaction and sign it, use 2/3 multiSig when i send raw transaction by bitcoin core 0.17.0 command line by use ./bitcoin-cli sendrawtransaction, i get…
yanpl
  • 21
  • 1
2
votes
2 answers

Constructing a P2WSH address from the BIP173 spec

The BIP173 specification defines how to create Bech32 Segwit native addresses. In the examples section a public key is given: 0279BE667EF9DCBBAC55A06295CE870B07029BFCDB2DCE28D959F2815B16F81798. Based on that key it is somewhat easy to generate a…
harm
  • 123
  • 5
2
votes
1 answer

How to generate a P2WSH address

getnewaddress "" bech32 generates a P2WPKH address (e.g. tb1qw508d6qejxtdg4y5r3zarvary0c5xw7kxpjzsx). How can I generate a P2WSH address (e.g. tb1qrp33g0q5c5txsp9arysrx4k6zdkfs4nce4xj0gdcccefvpysxf3q0sl5k7)?
toddmo
  • 774
  • 2
  • 7
  • 23
2
votes
1 answer

Failing to construct transaction that unlocks P2WSH

I am trying to unlock the P2WSH output of the following transaction: https://blockstream.info/testnet/tx/b435b180c936564cc902ce3d7011643836a74d671159d494f59536e70d977cd2 The script that I'm paying to is a non-standard script, which can be unlocked…
2
votes
0 answers

Create and spend P2WSH that locks coins with OP_CHECKLOCKTIMEVERIFY

I'm attempting to create a P2SWH address with a script that locks the coins for some time. And then I want to spend those coins from that address. I've read a lot, some of the most relevant: BIP173 Segwit dev guide Constructing a P2WSH address from…
1
2 3 4