m/86'/0'/0'/1/2, I could prove I know the xpriv at m/86'/0' which derives the xpub at m/86'/0'/0'. Then I provide the remaining key path elements /1/2 in the witness. Note, i do not mean we derive the xpriv at m/86'/0' inside the guest program. I mean the prover derives m/86'/0' first (in the host), and then writes that xpriv into the guest program's inputs. The guest program derives and outputs the xpub at m/86'/0'/0'. The verifier may check the STARK output (xpub) is correctly computed, then use the given key-path to manually derive the taproot address from the xpub themselves, outside the circuit, and validate that address against the UTXO i'm spending. The verifier thus has confirmed the prover knew an xpriv which (through a hardened derivation step) derives the correct taproot output key./1/2 inside the guest program (but we still do not need to do the taproot key tweaking in the guest program).--
You received this message because you are subscribed to the Google Groups "Bitcoin Development Mailing List" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bitcoindev+...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/bitcoindev/CAO3Pvs_PciUi%2BzBrCps3acO14sgeHVUANx9w6TVwUf_AYcd_qQ%40mail.gmail.com.
m/86'/0') and output a child xpriv (e.g. at m/86'/0'/0') to the journal (instead of outputting a child xpub). HMAC_SHA512 = SHA512((K⊕0x5c) || SHA512((K⊕0x36) || msg)) K is the chaincode (padded with zeros to 128 bytes) and msg = (0x00 || sk || i) is the parent secret key and child index. len(K) = 128 is the SHA512 block size, we need a total of 4 SHA512 compression calls: (K⊕0x36)msg (and SHA512 padding/length)k, chaincode c and index i, I know a preimage x and secret key sk such that:
I <- SHA512(<something> || SHA512(<something> || 0x00 || sk || i))c == I[:32]k == int(I[32:]) + sk % n<something> slots are arbitrary, and we know in BIP32 they are always exactly one-block long, it seems easy to throw out the compression calls (1) and (3). The host can precompute the relevant SHA512 midstates outside the circuit, and pass the midstates into the guest program as secret inputs. The tradeoff is that this permits malicious provers the flexibility of choosing their starting midstates (though hash input length can be fixed at 192 bytes). I'm not entirely sure if this meaningfully weakens the verifier's soundness. Ethan Heilman might have opinions on this, he knows a lot more about attacking hash functions than I do. Intuitively, I doubt sampling random SHA512 midstates is that much better than sampling a random HMAC key (chaincode) K and computing the resulting midstates.sk if we just hashed it without a chaincode at all, using two bare SHA512 calls - the only thing that changes is the midstate, and the SHA512 input length suffix. Starting from a different midstate doesn't magically give the attacker a head-start in a 256-bit search space looking for sk. A frauduent prover would know the child secret key k = sk + int(I[32:]) % n, but they don't know int(I[32:]) or sk so they cannot solve for either.I, set sk = int(I[32:])k = sk + sk % nk to find correct midstates such that
I == SHA512(<something> || SHA512(<something> || 0x00 || sk || i))k == int(I[32:]) + sk % n == sk + sk % nsk = int(I[32:]). Thus for these conditions to hold, the proof forger must be able to find not just the correct midstates, but also midstates which give a 2-stage partial hash cycle so that:I == SHA512(<something> || SHA512(<something> || 0x00 || I[32:] || i))To view this discussion visit https://groups.google.com/d/msgid/bitcoindev/CAO3Pvs9tps%3DbsMQyA%2BHvhK-u%2BXqRwWtjTq8WXZi%2BcveAVwPi9A%40mail.gmail.com.
m/352'/coin'/account'. Then any verifier could easily derive the private scan/spend keys m/352'/coin'/account'/0'/0 or m/352'/coin'/account'/1'/0, then replicate the ECDH process (with some BIP352-specific tweaks that the spender can provide), and add the result together. This reproduces the private key of the SP taproot output being spent, proving the spender is authentic.Curious why not generalise beyond BIP-32? P2PKH and P2WPKH without BIP-32 still commit to an unrevealed secret — HASH160(k·G) — as long as the pubkey has never previously appeared on-chain. A zk-STARK proof should apply here too? The prover argues for the correctness of HASH160(k·G) = h, where k is the private key scalar and k·G is the elliptic-curve point, without ever revealing k or the pubkey. This would allow recovery of a broader set of funds.
k such that HASH160(k*G) = h, then some non-negligible fraction of those coins will still be vulnerable to a CRQC because k*G may be known to the attacker, which to a CRQC is equivalent to knowing k. k for that address, and could use it to forge a proof that h = HASH160(k*G) to attempt to double-spend/RBF the authentic transaction.To view this discussion visit https://groups.google.com/d/msgid/bitcoindev/02378fd1-17a4-47aa-89fa-ee87626def65n%40googlegroups.com.
X using two peer pubkeys A and B:X = A * int(H(A, A || B)) + B * int(H(B, A || B))a and b in a way that also commits that proof to a spending transaction, then you can spend X but a CRQC cannot.(a, b) pair which produce pubkeys (A, B) such that:x = a * int(H(A, A || B)) + b * int(H(B, A || B))x is written to the public output of the proof. A verifier could then recompute X = x * G outside the circuit to validate a spend. Creating this proof demands we arithmetize two curve point multiplications and two hash function invocations, i.e. one mult and one hash per MuSig2 participant. Another downside is this would require participants to trust each other and share private keys (or use MPC to build the proof).(A, B) such that they recompute X using MuSig key aggregation, and then prove you know a BIP340 signature from X on a given transaction. This is similar to what Kurbatov did in this recent post exploring STARKs for rescuing hashed addresses without the need to export secret keys from secure signing devices. This approach would let you prove a similar statement without the need to share privkeys between peers, at the cost of one extra point multiplication and an extra hash invocation - These are needed to verify a Schnorr signature in the circuit.A and B, and neither can be forged by non-quantum peers in the MuSig group. Though, if there is a quantum adversary in the MuSig group, the group is screwed in either case. It'll still be very expensive to generate either proof, and circuit complexity will scale linearly with the number of MuSig2 signers. I think commit/reveal would be a better choice in this situation.A and B were derived using a hardened BIP32 step or some other hash-based algorithm though, then we could reuse Laolu's techniques to create a BIP32 proof which is secure even against Quantum attackers inside the MuSig group. a and b, and then let the verifier recompute A, B and X in software. The resulting circuit would be much faster and more efficient, because you only need to arithmetize one HMAC call per peer; no point multiplication needed. A quantum attacker in the MuSig group cannot forge any of their peers' proofs either, since they do not know the preimages their peers used to generate their keys. Though you'd need one separate proof for every signer in the MuSig group, so it'd probably be wise to aggregate the proofs together, especially for larger groups.To view this discussion visit https://groups.google.com/d/msgid/bitcoindev/2482176b-1ad7-4216-b1e7-2c03265425een%40googlegroups.com.
Hi Boris,
That’s a very interesting direction. For MuSig2, a "Federated Rescue" approach using Recursive STARKs seems like a viable path.
In this case, each participant could generate a leaf proof for their individual BIP32-derived key, and then a master STARK would aggregate these to prove the validity of the final MuSig2 aggregate key without revealing the underlying seeds.
This would be a powerful way to bridge the gap between individual hardware wallet security and multi-party coordination in a post-quantum world. I’d be interested to see how we can optimize the recursion overhead for this.
Best,
Mohammed Alwasabi
To view this discussion visit https://groups.google.com/d/msgid/bitcoindev/2482176b-1ad7-4216-b1e7-2c03265425een%40googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/bitcoindev/bd1f1379-fffa-4a93-a747-c449c2f7265cn%40googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/bitcoindev/02378fd1-17a4-47aa-89fa-ee87626def65n%40googlegroups.com.