<p>There is no reason to ever use this construction—other options would be able to achieve equivalent permissions much more weight efficiently. However, disallowing inefficient descriptors would complicate the implementation. I surmise that the example was only given as a sample of what would be possible, but one should not infer a recommendation to use it from that.</p>

CC BY-SA 4.0
2021-08-03T14:55:34.060Z
2021-08-03T14:55:34.060Z
Murch
<p>Bitcoin Core's <a href="https://github.com/bitcoin/bitcoin/blob/master/doc/descriptors.md" rel="nofollow noreferrer">descriptor documentation</a> lists a P2SH-P2WSH-P2PKH descriptor as one of its examples:</p>
<blockquote>
<p>sh(wsh(pkh(02e493dbf1c10d80f3581e4904930b1404cc6c13900ee0758474fa94abe8c4cd13))) describes an (overly complicated) P2SH-P2WSH-P2PKH output with the specified public key.</p>
</blockquote>
<p>That just seems inefficient and weird. It's not clear to me what advantage that construction would have over using P2SH-P2WPKH, P2WPKH, or, for his noodliness's sake, even P2SH-P2WSH-1of1-multisig. Is this listed just because it could be done, or is there an actual case in which the P2SH-P2WSH-P2PKH construction would be superior in some fashion to other viable options?</p>

<output-script-descriptors>
Would there ever be a reason to use a P2SH-P2WSH-P2PKH descriptor?
Murch
# Would there ever be a reason to use a P2SH-P2WSH-P2PKH descriptor?

(Asked by: username_0 on 2021-08-03)

Bitcoin Core's [descriptor documentation](https://github.com/bitcoin/bitcoin/blob/master/doc/descriptors.md) lists a P2SH-P2WSH-P2PKH descriptor as one of its examples:

> sh(wsh(pkh(02e493dbf1c10d80f3581e4904930b1404cc6c13900ee0758474fa94abe8c4cd13))) describes an (overly complicated) P2SH-P2WSH-P2PKH output with the specified public key.

That just seems inefficient and weird. It's not clear to me what advantage that construction would have over using P2SH-P2WPKH, P2WPKH, or, for his noodliness's sake, even P2SH-P2WSH-1of1-multisig. Is this listed just because it could be done, or is there an actual case in which the P2SH-P2WSH-P2PKH construction would be superior in some fashion to other viable options?

**Tags:** output-script-descriptors


---

## 1 answers

### Answer by username_0 on 2021-08-03. Score: 5

There is no reason to ever use this construction—other options would be able to achieve equivalent permissions much more weight efficiently. However, disallowing inefficient descriptors would complicate the implementation. I surmise that the example was only given as a sample of what would be possible, but one should not infer a recommendation to use it from that.


---

