Skip to content

Instantly share code, notes, and snippets.

View bitjson's full-sized avatar

Jason Dreyzehner bitjson

View GitHub Profile
bitjson / prueba
Created September 26, 2023 21:53 — forked from anonymous/prueba
We couldn’t find that file to show.
bitjson /
Created August 18, 2021 21:08 — forked from markblundeberg/
How might Taproot be implemented in BCH, and do we need it?

Taproot is an interesting technology to enable multiparty privacy on a bitcoin. Currently, there is a problem with multiparty contracts in that they are obvious deviation from the most common script type (P2PKH), which hurts privacy. The script that gets used will typically indicate exactly what kind of protocol was at play. Also complex P2SH scripts take extra resources (transaction size and CPU cycles).

The basic idea with Taproot is that instead of P2SH where a script is committed by a hash, you can hide a script (or set of possible scripts) as a commitment within a normal-looking public key. Now there are two ways to spend from this public key:

  1. Create a normal transaction signature using the public key, or,
  2. Reveal the commitment, and provide parameters that satisfy the revealed script.

To do #1, it means you need to know the private key, or, you have a set of signers who are able to produce a signature (that's where Schnor

bitjson / bst.schema.json
Created December 5, 2018 20:46 — forked from jcramer/bst.schema.json
Bitcoin Script Template (BST) Schema
"description": "Definition file for Bitcoin Script Templates",
"$schema": "",
"$id": "",
"title": "Bitcoin Script Template (BST) JSON Schema",
"type": "object",
"properties": {
"description": "BST schema version",
"type": "integer",
find . -type f -name '*.php' -exec awk 'END {print NR}' '{}' + 2>/dev/null | awk '{ total+=$1 }END{print total}'