summaryrefslogtreecommitdiff
path: root/67/9928565d1633a6f8b4af8e7d0763e016264c35
blob: 036dd81db31db7a8335950d2a4edfe72254bbb4a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
Return-Path: <fresheneesz@gmail.com>
Received: from smtp1.osuosl.org (smtp1.osuosl.org [IPv6:2605:bc80:3010::138])
 by lists.linuxfoundation.org (Postfix) with ESMTP id 3E9F9C000E
 for <bitcoin-dev@lists.linuxfoundation.org>;
 Tue, 27 Jul 2021 17:21:34 +0000 (UTC)
Received: from localhost (localhost [127.0.0.1])
 by smtp1.osuosl.org (Postfix) with ESMTP id 2CFC68387D
 for <bitcoin-dev@lists.linuxfoundation.org>;
 Tue, 27 Jul 2021 17:21:34 +0000 (UTC)
X-Virus-Scanned: amavisd-new at osuosl.org
X-Spam-Flag: NO
X-Spam-Score: -2.098
X-Spam-Level: 
X-Spam-Status: No, score=-2.098 tagged_above=-999 required=5
 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1,
 DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001,
 HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001,
 SPF_PASS=-0.001] autolearn=ham autolearn_force=no
Authentication-Results: smtp1.osuosl.org (amavisd-new);
 dkim=pass (2048-bit key) header.d=gmail.com
Received: from smtp1.osuosl.org ([127.0.0.1])
 by localhost (smtp1.osuosl.org [127.0.0.1]) (amavisd-new, port 10024)
 with ESMTP id erJdpXegdaBr
 for <bitcoin-dev@lists.linuxfoundation.org>;
 Tue, 27 Jul 2021 17:21:31 +0000 (UTC)
X-Greylist: whitelisted by SQLgrey-1.8.0
Received: from mail-ej1-x629.google.com (mail-ej1-x629.google.com
 [IPv6:2a00:1450:4864:20::629])
 by smtp1.osuosl.org (Postfix) with ESMTPS id 6D0A08386F
 for <bitcoin-dev@lists.linuxfoundation.org>;
 Tue, 27 Jul 2021 17:21:31 +0000 (UTC)
Received: by mail-ej1-x629.google.com with SMTP id e19so23215581ejs.9
 for <bitcoin-dev@lists.linuxfoundation.org>;
 Tue, 27 Jul 2021 10:21:31 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
 h=mime-version:references:in-reply-to:from:date:message-id:subject:to
 :cc; bh=JrrHwLt5oYY0Aqx4eGPTdrf5mb8ec14GfTffw3ffm60=;
 b=eb1zz4l3UVBEdpKqyciaPafWmWzAzhX8/Ntkh+Tp0JJVlV2t9pSYZ/GFZKDw1vXP1a
 c+bdjSee385WVE4FDmlhKP0bfSnV+ugHvelaFFQ7m2b0OP1VN1hQ8JooQRm6Z/Lellys
 /SteBKSGiJ58nm7eN0zMiLOXOTg4GIj/BEr/v8PaR6HADRtx1E4Q+7f8UCwU1S5MYPa/
 uCIwRWLQlsDABmR6PQgDKV1a/EbZEkvenCSwllihHPd1yyHH/Ej8b/a+9UHka8/9F9f7
 +dGhnDImbA/kTJTvSwR8XDrTcwIBioWceYon/zRuw54LPUIi4g4PfdQW8oQhLe9K5DOt
 6C2Q==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20161025;
 h=x-gm-message-state:mime-version:references:in-reply-to:from:date
 :message-id:subject:to:cc;
 bh=JrrHwLt5oYY0Aqx4eGPTdrf5mb8ec14GfTffw3ffm60=;
 b=ZPMbNoB8W7IsvaR4Ar+lyuPVt3mFe57UmxDzQDtaDDIc6qd+JbPHTTSQOEGJEK5MV5
 /L0A7ljKdcn9+we9P2zmC+iukqBYRpF2EBA0gIcDHD+DIDLq+/zkxu624qdN9Iarr5Aq
 WpREclhCPD8F0O/7GtN3O1irveIVDH77Or1AB1V4LuGyvkttvltya9m0fEHwhycDViID
 Cu+a9pylIsnzi8T3P6KlfeYJAZMpTtUzTeCqvlcVmMueOux+VkM5pqpLpuKN02xaBSFT
 c5jAyMC/Pnaei86tUAn2TDagVA4xdlyqeZKv9IucyjVWh2pOnnDdW/u6efcFiM2XTYoT
 NCAg==
X-Gm-Message-State: AOAM532s3Sxll23yOK6XfMdiXI70Ztk8GDqjrP1RO8z+Aw7Qu8+nmwwg
 Qj12BbcSdv/gtReiW3YhilgLvQAooFqmI3XX4us=
X-Google-Smtp-Source: ABdhPJzjbvucbzfnvqKP0ibHQ+2QJ3ZCLq01bffN/Cb/+Mb+SbrxhWX7VWX1flyZ+1/rUZkMk2v4wxDg7N2Zf+F3rQU=
X-Received: by 2002:a17:906:2b58:: with SMTP id
 b24mr21933340ejg.141.1627406489409; 
 Tue, 27 Jul 2021 10:21:29 -0700 (PDT)
MIME-Version: 1.0
References: <CAGpPWDZ0aos5qHw2=popCpjuH7OXC0geEj8i3dwDTfP0j=or4w@mail.gmail.com>
 <20210725053803.fnmd6etv3f7x3u3p@ganymede>
 <CAGpPWDZ8EWd7kGV5pFZadQM1kqETrTK2zybsGF1hW9fx2oZb7w@mail.gmail.com>
 <CAH+Axy7cPufMUCMQbCz2MUgRqQbgenAozPBFD8kPYrSjwcRG8w@mail.gmail.com>
 <CAGpPWDb8yzGO-VtCO-x09e-phKHT7ezOms+DzeWc9vS3rN1AAw@mail.gmail.com>
 <CAJ4-pEDWuNfdE4NXkZBsOnuSQ4YOv28YVwGavyiU+FPvpC6y1w@mail.gmail.com>
In-Reply-To: <CAJ4-pEDWuNfdE4NXkZBsOnuSQ4YOv28YVwGavyiU+FPvpC6y1w@mail.gmail.com>
From: Billy Tetrud <billy.tetrud@gmail.com>
Date: Tue, 27 Jul 2021 10:21:11 -0700
Message-ID: <CAGpPWDZL6BpzoNa0Qgf-Ux60fyWPjZH=NESkgbhEQO_My=XiAg@mail.gmail.com>
To: Zac Greenwood <zachgrw@gmail.com>
Content-Type: multipart/alternative; boundary="000000000000b4de1405c81e1950"
X-Mailman-Approved-At: Tue, 27 Jul 2021 18:22:16 +0000
Cc: Bitcoin Protocol Discussion <bitcoin-dev@lists.linuxfoundation.org>
Subject: Re: [bitcoin-dev] Covenant opcode proposal OP_CONSTRAINDESTINATION
 (an alternative to OP_CTV)
X-BeenThere: bitcoin-dev@lists.linuxfoundation.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: Bitcoin Protocol Discussion <bitcoin-dev.lists.linuxfoundation.org>
List-Unsubscribe: <https://lists.linuxfoundation.org/mailman/options/bitcoin-dev>, 
 <mailto:bitcoin-dev-request@lists.linuxfoundation.org?subject=unsubscribe>
List-Archive: <http://lists.linuxfoundation.org/pipermail/bitcoin-dev/>
List-Post: <mailto:bitcoin-dev@lists.linuxfoundation.org>
List-Help: <mailto:bitcoin-dev-request@lists.linuxfoundation.org?subject=help>
List-Subscribe: <https://lists.linuxfoundation.org/mailman/listinfo/bitcoin-dev>, 
 <mailto:bitcoin-dev-request@lists.linuxfoundation.org?subject=subscribe>
X-List-Received-Date: Tue, 27 Jul 2021 17:21:34 -0000

--000000000000b4de1405c81e1950
Content-Type: text/plain; charset="UTF-8"

Hi Zac,

I haven't heard of any proposal for limiting the amount that can be sent
from an address. I assume you mean limiting the amount that can be sent in
a period of time - eg something that would encode that for address A, only
X bitcoin can be sent from the address in a given day/week/etc, is that
right? That would actually be a somewhat difficult thing to do in the
output-based system Bitcoin uses, and would be easier in an account based
system like Ethereum. The problem is that each output is separate, and
there's no concept in bitcoin of encumbering outputs together.

What you could do is design a system where coins would be combined in a
single output, and then encumber that output with a script that allows a
limited amount of coin be sent to a destination address and requires all
other bitcoins be returned to sender in a new change output that is also
timelocked. That way, the new change output can't be used again until the
timelock expires (eg a week). However, to ensure this wallet works
properly, any deposit into the wallet would have to also spend the wallet's
single output, so as to create a new single output at that address. So 3rd
parties wouldn't be able to arbitrarily send money in (or rather, they
could, but each output would have its own separate spending limit).

> such kind of restriction would be extremely effective in thwarting the
most damaging type of theft being the one where all funds are swept in a
single transaction

It would. However a normal wallet vault basically already has this property
- a thief can't simply sweep funds instantly, but instead the victim will
see an initiated transaction and will be able to reverse it within a delay
time-window. I don't think adding a spending limit would add meaningful
security to a delayed-send wallet vault like that. But it could be used to
increase the security of a wallet vault that can be instantly spent from -
ie if the attacker successfully steals funds, then the victim has time to
go gather their additional keys and move the remaining (unstolen) funds
into a new wallet.

OP_CD could potentially be augmented to allow specifying limit amounts for
each destination, which would allow you to create a wallet like this. It
would be a bit of an awkward wallet to use tho, since you couldn't receive
directly into it from a 3rd party and you also couldn't keep separate
outputs (which is bad for privacy).

An alternate way of doing this that you don't need any new opcodes for
would be to have a 3rd party service that signs multisig transactions from
a wallet only up to a limit. The end-user could have additional keys such
that the 3rd party can't prevent them from accessing that (if they turn
uncooperative), and the 3rd party would only have a single key so they
can't steal funds, but the user would sign a transaction with one key, and
the 3rd party with another as long as the spending limit hasn't been
reached. This wouldn't have much counterparty risk, but would be a less
awkward wallet than what I described above - meaning anyone could send
funds into the wallet without defeating the spending limit, and privacy
could be kept intact (minus the fact that the 3rd party would know what
your outputs are).

BT

On Tue, Jul 27, 2021 at 4:18 AM Zac Greenwood <zachgrw@gmail.com> wrote:

> Hi Billy,
>
> On the topic of wallet vaults, are there any plans to implement a way to
> limit the maximum amount to be sent from an address?
>
> An example of such limit might be: the maximum amount allowed to send is
> max(s, p) where s is a number of satoshi and p a percentage of the total
> available (sendable) amount.
>
> A minimum value may be imposed on the percentage to ensure that the
> address can be emptied within a reasonable number of transactions. The
> second parameter s allows a minimum permitted amount. (This is necessary
> because with only the percentage parameter the minimum permitted amount
> converges to zero, making it impossible to empty the address).
>
> There may be other ways too. In my view, such kind of restriction would be
> extremely effective in thwarting the most damaging type of theft being the
> one where all funds are swept in a single transaction.
>
> Zac
>
>
> On Tue, 27 Jul 2021 at 03:26, Billy Tetrud via bitcoin-dev <
> bitcoin-dev@lists.linuxfoundation.org> wrote:
>
>> Hey James,
>>
>> In the examples you mentioned, what I was exploring was a mechanism of
>> attack by which the attacker could steal user A's key and use that key to
>> send a transaction with the maximum possible fee. User B would still
>> receive some funds (probably), but if the fee could be large, the attacker
>> would either do a lot of damage to user B (griefing) or could make an
>> agreement with a miner to give back some of the large fee (theft).
>>
>> But as for use cases, the proposal mentions a number of use cases
>> <https://github.com/fresheneesz/bip-efficient-bitcoin-vaults/blob/main/cd/bip-constraindestination.md#motivation> and
>> most overlap with the use cases of op_ctv <https://utxos.org/uses/> (Jeremy
>> Rubin's website for op_ctv has a lot of good details, most of which are
>> also relevant to op_cd). The use case I'm most interested in is wallet
>> vaults. This opcode can be used to create a wallet vault where the user
>> only needs to use, for example, 1 key to spend funds, but the attacker must
>> steal 2 or more keys to spend funds. The benefits of a 2 key wallet vault
>> like this vs a normal 2-of-2 multisig wallet are that not only does an
>> attacker have to steal both keys (same level of security), but also the
>> user can lose one key and still recover their funds (better redundancy) and
>> also that generally the user doesn't need to access their second key - so
>> that can remain in a much more secure location (which would also probably
>> make that key harder to steal). The only time the second key only comes
>> into play if one key is stolen and the attacker attempts to send a
>> transaction. At that point, the user would go find and use his second key
>> (along with the first) to send a revoke transaction to prevent the attacker
>> from stealing their funds. This is somewhat akin to a lightning watchtower
>> scenario, where your wallet would watch the chain and alert you about an
>> unexpected transaction, at which point you'd manually do a revoke (vs a
>> watchtower's automated response). You might be interested in taking a look
>> at this wallet vault design
>> <https://github.com/fresheneesz/bip-efficient-bitcoin-vaults/blob/main/cd/op_cdWalletVault1.md>
>> that uses OP_CD or even my full vision
>> <https://github.com/fresheneesz/bip-efficient-bitcoin-vaults> of the
>> wallet vault I want to be able to create.
>>
>> With a covenant opcode like this, its possible to create very usable and
>> accessible but highly secure wallets that can allow normal people to hold
>> self custody of their keys without fear of loss or theft and without the
>> hassle of a lot of safe deposit boxes (or other secure seed storage
>> locations).
>>
>> Cheers,
>> BT
>>
>>
>>
>>
>>
>> On Mon, Jul 26, 2021 at 2:08 PM James MacWhyte <macwhyte@gmail.com>
>> wrote:
>>
>>> Hi Billy!
>>>
>>> See above, but to break down that situation a bit further, these are the
>>>> two situations I can think of:
>>>>
>>>>    1. The opcode limits user/group A to send the output to user/group B
>>>>    2. The opcode limits user A to send from one address they own to
>>>>    another address they own.
>>>>
>>>> I'm trying to think of a good use case for this type of opcode. In
>>> these examples, an attacker who compromises the key for user A can't steal
>>> the money because it can only be sent to user B. So if the attacker wants
>>> to steal the funds, they would need to compromise the keys of both user A
>>> and user B.
>>>
>>> But how is that any better than a 2-of-2 multisig? Isn't the end result
>>> exactly the same?
>>>
>>> James
>>>
>> _______________________________________________
>> bitcoin-dev mailing list
>> bitcoin-dev@lists.linuxfoundation.org
>> https://lists.linuxfoundation.org/mailman/listinfo/bitcoin-dev
>>
>

--000000000000b4de1405c81e1950
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr">Hi Zac,<div><br></div><div>I haven&#39;t heard of any prop=
osal for limiting the amount that can be sent from an address. I assume you=
 mean limiting the amount that can be sent in a period of time - eg somethi=
ng that would encode that for address A, only X bitcoin can be sent from th=
e address in a given day/week/etc, is that right? That would actually be a =
somewhat difficult thing to do in the output-based system Bitcoin uses, and=
 would be easier in an account based system like Ethereum. The problem is t=
hat each output is separate, and there&#39;s no concept in bitcoin of encum=
bering outputs together.=C2=A0</div><div><br></div><div>What you could do i=
s design a system where coins would be combined in a single output, and the=
n encumber that output with a script that allows a limited amount of coin b=
e sent to a destination address and requires all other bitcoins be returned=
 to sender in a new change output that is also timelocked. That way, the ne=
w change output can&#39;t be used again until the timelock expires (eg a we=
ek). However, to ensure this wallet works properly, any deposit into the wa=
llet would have to also spend the wallet&#39;s single output, so as to crea=
te a new single output at that address. So 3rd parties wouldn&#39;t be able=
 to arbitrarily send money in (or rather, they could, but each output would=
 have its own separate spending limit).=C2=A0</div><div><br></div><div>&gt;=
 such kind of restriction would be extremely effective in thwarting the mos=
t damaging type of theft being the one where all funds are swept in a singl=
e transaction</div><div><br></div><div>It would. However a normal wallet va=
ult basically=C2=A0already has this property - a thief can&#39;t simply swe=
ep funds instantly, but instead the victim will see an initiated transactio=
n and will be able to reverse it within a delay time-window. I don&#39;t th=
ink adding a spending limit would add meaningful security to a delayed-send=
 wallet vault like that. But it could be used to increase the security of a=
 wallet vault that can be instantly spent from - ie if the attacker success=
fully steals funds, then the victim has time to go gather their additional =
keys and move the remaining (unstolen) funds into a new wallet.=C2=A0</div>=
<div><br></div><div>OP_CD could potentially be augmented to allow specifyin=
g limit amounts for each destination, which would allow you to create a wal=
let like this. It would be a bit of an awkward wallet to use tho, since you=
 couldn&#39;t receive directly into it from a 3rd party and you also couldn=
&#39;t keep separate outputs (which is bad for privacy).=C2=A0</div><div><b=
r></div><div>An alternate way of doing this that you don&#39;t need any new=
 opcodes for would be to have a 3rd party service that signs multisig trans=
actions from a wallet only up to a limit. The end-user could have additiona=
l keys such that the 3rd party can&#39;t prevent them from accessing that (=
if they turn uncooperative), and the 3rd party would only have a single key=
 so they can&#39;t steal funds, but the user would sign a transaction with =
one key, and the 3rd party with another as long as the spending limit hasn&=
#39;t been reached. This wouldn&#39;t have much counterparty risk, but woul=
d be a less awkward wallet than what I described above - meaning anyone cou=
ld send funds into the wallet without defeating the spending limit, and pri=
vacy could be kept intact (minus the fact that the 3rd party would know wha=
t your outputs are).=C2=A0</div><div><br></div><div>BT</div></div><br><div =
class=3D"gmail_quote"><div dir=3D"ltr" class=3D"gmail_attr">On Tue, Jul 27,=
 2021 at 4:18 AM Zac Greenwood &lt;<a href=3D"mailto:zachgrw@gmail.com">zac=
hgrw@gmail.com</a>&gt; wrote:<br></div><blockquote class=3D"gmail_quote" st=
yle=3D"margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padd=
ing-left:1ex"><div dir=3D"auto">Hi Billy,</div><div dir=3D"auto"><br></div>=
<div dir=3D"auto">On the topic of wallet vaults, are there any plans to imp=
lement a way to limit the maximum amount to be sent from an address?</div><=
div dir=3D"auto"><br></div><div dir=3D"auto">An example of such limit might=
 be: the maximum amount allowed to send is max(s, p) where s is a number of=
 satoshi and p a percentage of the total available (sendable) amount.</div>=
<div dir=3D"auto"><br></div><div dir=3D"auto">A minimum value may be impose=
d on the percentage to ensure that the address can be emptied within a reas=
onable number of transactions. The second parameter s allows a minimum perm=
itted amount. (This is necessary because with only the percentage parameter=
 the minimum permitted amount converges to zero, making it impossible to em=
pty the address).=C2=A0</div><div dir=3D"auto"><br></div><div dir=3D"auto">=
There may be other ways too. In my view, such kind of restriction would be =
extremely effective in thwarting the most damaging type of theft being the =
one where all funds are swept in a single transaction.</div><div dir=3D"aut=
o"><br></div><div dir=3D"auto">Zac</div><div dir=3D"auto"><br></div><div><b=
r><div class=3D"gmail_quote"><div dir=3D"ltr" class=3D"gmail_attr">On Tue, =
27 Jul 2021 at 03:26, Billy Tetrud via bitcoin-dev &lt;<a href=3D"mailto:bi=
tcoin-dev@lists.linuxfoundation.org" target=3D"_blank">bitcoin-dev@lists.li=
nuxfoundation.org</a>&gt; wrote:<br></div><blockquote class=3D"gmail_quote"=
 style=3D"margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);p=
adding-left:1ex"><div dir=3D"ltr">Hey James,<div><br></div><div>In the exam=
ples you mentioned, what I was exploring was a mechanism of attack by which=
 the attacker could steal user A&#39;s key and use that key to send a trans=
action with the maximum possible fee. User B would still receive some funds=
 (probably), but if the fee could be large, the attacker would either do a =
lot of damage to user B (griefing) or could make an agreement with a miner =
to give back some of the large fee (theft).=C2=A0</div><div><br></div><div>=
But as for use cases, the proposal mentions <a href=3D"https://github.com/f=
resheneesz/bip-efficient-bitcoin-vaults/blob/main/cd/bip-constraindestinati=
on.md#motivation" target=3D"_blank">a number of use cases</a>=C2=A0and most=
 overlap with the <a href=3D"https://utxos.org/uses/" target=3D"_blank">use=
 cases of op_ctv</a>=C2=A0(Jeremy Rubin&#39;s website for op_ctv has a lot =
of good details, most of which are also relevant to op_cd). The use case I&=
#39;m most interested=C2=A0in is wallet vaults. This opcode can be used to =
create a wallet vault where the user only needs to use, for example, 1 key =
to spend funds, but the attacker must steal 2 or more keys to spend funds. =
The benefits of a 2 key wallet vault like this vs a normal 2-of-2 multisig =
wallet are that not only does an attacker have to steal both keys (same lev=
el of security), but also the user can lose one key and still recover their=
 funds (better redundancy) and also that generally the user doesn&#39;t nee=
d to access their second key - so that can remain in a much more secure loc=
ation (which would also probably make that key harder to steal). The only t=
ime the second key only comes into play if one key is stolen and the attack=
er attempts to send a transaction. At that point, the user would go find an=
d use his second key (along with the first) to send a revoke transaction to=
 prevent the attacker from stealing their funds. This is somewhat akin to a=
 lightning watchtower scenario, where your wallet would watch the chain and=
 alert you about an unexpected transaction, at which point you&#39;d manual=
ly do a revoke (vs a watchtower&#39;s automated response). You might be int=
erested in taking a look at <a href=3D"https://github.com/fresheneesz/bip-e=
fficient-bitcoin-vaults/blob/main/cd/op_cdWalletVault1.md" target=3D"_blank=
">this wallet vault design</a> that uses OP_CD or even <a href=3D"https://g=
ithub.com/fresheneesz/bip-efficient-bitcoin-vaults" target=3D"_blank">my fu=
ll vision</a> of the wallet vault I want to be able to create.</div><div><b=
r></div><div>With a covenant opcode like this, its possible to create very =
usable and accessible but highly secure wallets that can allow normal peopl=
e to hold self custody of their keys without fear of loss or theft and with=
out the hassle of a lot of safe deposit boxes (or other secure seed storage=
 locations).=C2=A0</div><div><br></div><div>Cheers,</div><div>BT</div><div>=
<br></div><div><br></div><div><br></div><div><br></div></div><br><div class=
=3D"gmail_quote"><div dir=3D"ltr" class=3D"gmail_attr">On Mon, Jul 26, 2021=
 at 2:08 PM James MacWhyte &lt;<a href=3D"mailto:macwhyte@gmail.com" target=
=3D"_blank">macwhyte@gmail.com</a>&gt; wrote:<br></div><blockquote class=3D=
"gmail_quote" style=3D"margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(2=
04,204,204);padding-left:1ex"><div dir=3D"ltr"><div dir=3D"ltr">Hi Billy!</=
div><div dir=3D"ltr"><br></div><div class=3D"gmail_quote"><blockquote class=
=3D"gmail_quote" style=3D"margin:0px 0px 0px 0.8ex;border-left:1px solid rg=
b(204,204,204);padding-left:1ex"><div dir=3D"ltr"><div><span>See above, but=
 to break down that situation a bit further, these are the two situations I=
 can think of:</span><br></div><div><div><ol><li style=3D"padding-bottom:0.=
6001em">The opcode limits user/group A to send the output to user/group B</=
li><li style=3D"padding-bottom:0.6001em">The opcode limits user A to send f=
rom one address they own to another address they own.=C2=A0</li></ol></div>=
</div></div></blockquote><div><span>I&#39;m trying to think of a good use c=
ase for this type of opcode. In these examples, an attacker who compromises=
 the key for user A can&#39;t steal the money because it can only be sent t=
o user B. So if the attacker wants to steal the funds, they would need to c=
ompromise the keys of both user A and user B.</span></div><div><span><br></=
span></div><div><span>But how is that any better than a 2-of-2 multisig? Is=
n&#39;t the end result exactly=C2=A0the same?</span><br></div><div><span><b=
r></span></div><div><span>James</span></div></div></div>
</blockquote></div>
_______________________________________________<br>
bitcoin-dev mailing list<br>
<a href=3D"mailto:bitcoin-dev@lists.linuxfoundation.org" target=3D"_blank">=
bitcoin-dev@lists.linuxfoundation.org</a><br>
<a href=3D"https://lists.linuxfoundation.org/mailman/listinfo/bitcoin-dev" =
rel=3D"noreferrer" target=3D"_blank">https://lists.linuxfoundation.org/mail=
man/listinfo/bitcoin-dev</a><br>
</blockquote></div></div>
</blockquote></div>

--000000000000b4de1405c81e1950--