# Lamport signatures and other CAT tricks

**URL:** <https://delvingbitcoin.org/t/lamport-signatures-and-other-cat-tricks/236>\
**Category:** Protocol Design\
**Created:** [December 2, 2023, 11:15pm UTC](https://delvingbitcoin.org/t/lamport-signatures-and-other-cat-tricks/236 "2023-12-02T23:15:49Z")\
**Posts on this page:** 1\
**Showing post:** 9

<div class="post-metadata">

**Author:** ![ZmnSCPxj](https://delvingbitcoin.org/letter_avatar_proxy/v4/letter/z/ee7513/32.png) [@ZmnSCPxj](https://delvingbitcoin.org/u/ZmnSCPxj)\
**Post date:** [December 5, 2023, 12:32pm UTC](https://delvingbitcoin.org/t/lamport-signatures-and-other-cat-tricks/236/9 "2023-12-05T12:32:13Z")

</div>

If we are willing to softfork something in that allows Lamport and other ttricks and re-enabling of `OP_CAT` (and converting all `OP_NOP` to `OP_SUCCESS`), then maybe we can use a different P2SH-like encoding? i.e. instead of `OP_HASH160 <hash> OP_EQUAL` as in P2SH, create a new P2XSH with template `OP_HASH256 <hash> OP_EQUAL`. If this template is recognized, then the softfork version expects the script top to be equivalent to a `0xC0`-version script as in tapleaf, including `OP_SUCCESS`. Then you can execute any extensions supported inside `0xC0`-version tapleaves in the P2XSH script, including `OP_CAT` if that is enabled inside tapscript version `0xC0`. This lets you avoid any quantum-non-resistant paths on the way to the script.

(Or maybe just make it into a tapleaf so include the version to the front of the script. sort of thing)

---

_[View the full topic](https://delvingbitcoin.org/t/lamport-signatures-and-other-cat-tricks/236)._
