public inbox for bitcoindev@googlegroups.com
 help / color / mirror / Atom feed
From: "James O'Beirne" <james.obeirne@gmail•com>
To: Anthony Towns <aj@erisian•com.au>,
	 Bitcoin Protocol Discussion
	<bitcoin-dev@lists•linuxfoundation.org>
Subject: Re: [bitcoin-dev] OP_VAULT: a new vault proposal
Date: Wed, 18 Jan 2023 17:45:01 -0500	[thread overview]
Message-ID: <CAPfvXfKMsOF1g85Td8UpZdWSH+a0sRXK9Rur1ODduMauJhM+6A@mail.gmail.com> (raw)
In-Reply-To: <Y8ZSXrxfR8HrB8zD@erisian.com.au>

[-- Attachment #1: Type: text/plain, Size: 2169 bytes --]

I've implemented three changes based on suggestions from Greg Sanders
and AJ Towns.

I've segmented the changes into commits that should be
reasonable to follow, even though I'll probably rearrange the commit
structure later on.

1. Greg's suggestion: OP_UNVAULT outputs can now live behind
scripthashes. This means that the lifecycle of a vault can live entirely
within, say, Taproot. In this case the only thing that would reveal
the operation of the vault would be the content of the witness stack
when triggering an unvault or recovering. So I think no real privacy
benefits over the previous scheme, but certainly some efficiency ones
since we're moving more content from the scriptPubKey into the witness.

 Commit here:
https://github.com/bitcoin/bitcoin/pull/26857/commits/cd33d120c67cda7eb5c6bbfe3a1ea9fb6c5b93d1

2. AJ's suggestion: unvault trigger transactions can now have an extra
"revault" output that redeposits some balance to the same vault
scriptPubKey from which it came. This is nice because if the delay
period is long, you may want to manage a remaining vault balance
separately while the spent balance is pending an unvault.

 Commit here:
https://github.com/bitcoin/bitcoin/pull/26857/commits/cf3764fb503bc17c4438d1322ecf780b9dc3ef30

3. AJ's suggestion: instead of specifying <recovery-spk-hash>, introduce
a replacement parameter: <recovery-params>. This contains the same
target recovery sPK hash as before, but the remaining bytes contain a
scriptPubKey that functions as authorization for the recovery process.
This allows users to optionally avoid the risk of "recovery replays" at
the expense of having to maintain a recovery key. Users can opt out of
this by passing OP_TRUE for the recovery sPK. I guess maybe I could even
support just omitting an sPK altogether for the legacy behavior.

Commit here:
https://github.com/bitcoin/bitcoin/pull/26857/commits/fdfd5e93f96856fbb41243441177a40ebbac6085


The suggestions were good ones, and I think they've improved the
proposal.

My next steps are to do minor updates to the paper and start writing a
BIP draft.

Thanks to achow for the valuable feedback, which I'm still mulling on.

James

[-- Attachment #2: Type: text/html, Size: 2800 bytes --]

  parent reply	other threads:[~2023-01-18 22:45 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-01-16 23:47 Andrew Chow
2023-01-17  7:46 ` Anthony Towns
2023-01-18 19:00   ` Billy Tetrud
2023-01-18 23:37     ` James O'Beirne
2023-01-19 22:49       ` Billy Tetrud
2023-01-18 22:45   ` James O'Beirne [this message]
2023-01-20 17:43 ` James O'Beirne
  -- strict thread matches above, loose matches on Subject: below --
2023-01-09 16:07 James O'Beirne
2023-01-09 19:02 ` rot13maxi
2023-01-09 19:31   ` Greg Sanders
2023-01-09 20:32     ` James O'Beirne
2023-01-10 13:35       ` James O'Beirne
2023-01-10 12:29 ` Anthony Towns
2023-01-10 20:22   ` James O'Beirne
2023-01-11  6:52     ` Anthony Towns
2023-01-10 14:17 ` James O'Beirne

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAPfvXfKMsOF1g85Td8UpZdWSH+a0sRXK9Rur1ODduMauJhM+6A@mail.gmail.com \
    --to=james.obeirne@gmail$(echo .)com \
    --cc=aj@erisian$(echo .)com.au \
    --cc=bitcoin-dev@lists$(echo .)linuxfoundation.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox