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
|
Return-Path: <user@petertodd.org>
Received: from smtp1.osuosl.org (smtp1.osuosl.org [IPv6:2605:bc80:3010::138])
by lists.linuxfoundation.org (Postfix) with ESMTP id 6728CC0012
for <bitcoin-dev@lists.linuxfoundation.org>;
Thu, 9 Dec 2021 13:50:45 +0000 (UTC)
Received: from localhost (localhost [127.0.0.1])
by smtp1.osuosl.org (Postfix) with ESMTP id 4EFCC84F54
for <bitcoin-dev@lists.linuxfoundation.org>;
Thu, 9 Dec 2021 13:50:45 +0000 (UTC)
X-Virus-Scanned: amavisd-new at osuosl.org
X-Spam-Flag: NO
X-Spam-Score: -2.398
X-Spam-Level:
X-Spam-Status: No, score=-2.398 tagged_above=-999 required=5
tests=[BAYES_00=-1.9, DKIM_INVALID=0.1, DKIM_SIGNED=0.1,
RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H3=0.001,
RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001]
autolearn=ham autolearn_force=no
Authentication-Results: smtp1.osuosl.org (amavisd-new);
dkim=fail (2048-bit key) reason="fail (message has been altered)"
header.d=petertodd.org
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 isabQbR8pwc9
for <bitcoin-dev@lists.linuxfoundation.org>;
Thu, 9 Dec 2021 13:50:44 +0000 (UTC)
X-Greylist: from auto-whitelisted by SQLgrey-1.8.0
Received: from outmail149084.authsmtp.net (outmail149084.authsmtp.net
[62.13.149.84])
by smtp1.osuosl.org (Postfix) with ESMTPS id BEF6784F47
for <bitcoin-dev@lists.linuxfoundation.org>;
Thu, 9 Dec 2021 13:50:43 +0000 (UTC)
Received: from punt22.authsmtp.com (punt22.authsmtp.com [62.13.128.207])
by punt16.authsmtp.com. (8.15.2/8.15.2) with ESMTP id 1B9DofrP013199
for <bitcoin-dev@lists.linuxfoundation.org>; Thu, 9 Dec 2021 13:50:41 GMT
(envelope-from user@petertodd.org)
Received: from mail-c237.authsmtp.com (mail-c237.authsmtp.com [62.13.128.237])
by punt22.authsmtp.com. (8.15.2/8.15.2) with ESMTP id 1B9Dofqr046993;
Thu, 9 Dec 2021 13:50:41 GMT (envelope-from user@petertodd.org)
Received: from petertodd.org (76-10-157-59.dsl.teksavvy.com [76.10.157.59])
(authenticated bits=0)
by mail.authsmtp.com (8.15.2/8.15.2) with ESMTPSA id 1B9Doc9l070152
(version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO);
Thu, 9 Dec 2021 13:50:39 GMT (envelope-from user@petertodd.org)
Received: by petertodd.org (Postfix) with ESMTPSA id B99D89E6E6;
Thu, 9 Dec 2021 08:50:37 -0500 (EST)
DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=petertodd.org; s=mail;
t=1639057837; bh=kCfW3ytUQ7sp1+j9K+BQx/rzHvpzyBNP1mhzNeZ/E6M=;
h=Date:From:To:Subject:References:In-Reply-To:From;
b=UnHCkWa7RdM0gYlMfwYG2dYKRDFPm2sD+sRNFaKk+e7+vQhicT3LrkYptP/dPzqYe
y0fQ/J9YplsPLM2ohTkdlGpyc505cU3Uag6EAfeYGl7VQTjMnffIcSNZ0xDhvbpw5q
WbijP10+3tmO9C0taaOYSCBlk+as5+2gRhREHdkYkM8QcFOjZGuRHPakEe/cXws795
h/JF8FSDtB24aPoQtBCm0nhMYWPLRNWPh6gg8yEKjP643ageJDSoVlh01LAqpZNWSE
x2SBrgeWRf+zRxHt8G621fARjtyoVI05xmbohwcO0kenKAmjGg3n5k2LX1HVb90C+4
sZXRv1CXTBKmA==
Received: by localhost (Postfix, from userid 1000)
id A245E5FB50; Thu, 9 Dec 2021 08:50:33 -0500 (EST)
Date: Thu, 9 Dec 2021 08:50:33 -0500
From: Peter Todd <pete@petertodd.org>
To: darosior <darosior@protonmail.com>,
Bitcoin Protocol Discussion <bitcoin-dev@lists.linuxfoundation.org>
Message-ID: <YbIJqX+oK6hio4C3@petertodd.org>
References: <hBx6OYA5Mv9C_anoMQ-s-9l_XNwNFPfDVmOND9pXBJEBi7qsULF3bgPGpagtqjOsKDTXu8iOTVzvOjflz-M6EfnfwVH81Cu-nnai0kakouo=@protonmail.com>
MIME-Version: 1.0
Content-Type: multipart/signed; micalg=pgp-sha512;
protocol="application/pgp-signature"; boundary="gTOQlUl3d0imVUeI"
Content-Disposition: inline
In-Reply-To: <hBx6OYA5Mv9C_anoMQ-s-9l_XNwNFPfDVmOND9pXBJEBi7qsULF3bgPGpagtqjOsKDTXu8iOTVzvOjflz-M6EfnfwVH81Cu-nnai0kakouo=@protonmail.com>
X-Server-Quench: fed02fe9-58f6-11ec-ba2e-8434971169dc
X-AuthReport-Spam: If SPAM / abuse - report it at:
http://www.authsmtp.com/abuse
X-AuthRoute: OCd2Yg0TA1ZIVwkA IjsJECJaVQIpKltL GxAVKBZePFsRUQkR
aAdMdgsUHFAXAgsB AWcbWldeVV17XWM7 bAxPbAVDY09JQQBj T0pMXVMcFXdhdUNS
D0IeVRlzcgcIeX50 YU4sCCUPXEYsIE9g R0YCE3AHZDIzdTJO UhVFfwdXdApNfx5D
YwQsGhFYa3VsNCMk FAgyOXU9MCtqYA0d TAwAaFgPRF4KGDF0 QhcOEDFH
X-Authentic-SMTP: 61633532353630.1024:7600
X-AuthFastPath: 0 (Was 255)
X-AuthVirus-Status: No virus detected - but ensure you scan with your own
anti-virus system.
Subject: Re: [bitcoin-dev] A fee-bumping model
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: Thu, 09 Dec 2021 13:50:45 -0000
--gTOQlUl3d0imVUeI
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable
On Mon, Nov 29, 2021 at 02:27:23PM +0000, darosior via bitcoin-dev wrote:
> ## 2. Problem statement
>=20
> For any delegated vault, ensure the confirmation of a Cancel transaction =
in a configured number of
> blocks at any point. In so doing, minimize the overpayments and the UTxO =
set footprint. Overpayments
> increase the burden on the watchtower operator by increasing the required=
frequency of refills of the
> fee-bumping wallet, which is already the worst user experience. You are l=
ikely to manage a number of
> UTxOs with your number of vaults, which comes at a cost for you as well a=
s everyone running a full
> node.
>=20
> Note that this assumes miners are economically rationale, are incentivize=
d by *public* fees and that
> you have a way to propagate your fee-bumped transaction to them. We also =
don't consider the block
> space bounds.
>=20
> In the previous paragraph and the following text, "vault" can generally b=
e replaced with "offchain
> contract".
For this section I think it'd help if you re-wrote it mathematically in ter=
ms
of probabilities, variance, and costs. It's impossible to ensure confirmati=
on
with 100% probability, so obviously we can start by asking what is the cost=
of
failing to get a confirmation by the deadline?
Now suppose that cost is X. Note how the lowest _variance_ approach would b=
e to
pay a fee of X immediately: that would get us the highest possible probabil=
ity
of securing a confirmation prior to the deadline, without paying more than =
that
confirmation is worth.
Of course, this is silly! So the next step is to trade off some variance -
higher probability of failure - for lower expected cost. A trivial way to do
that could be to just bump the fee linearly between now and that deadline. =
That
lowers expected cost. But does increase the probability of failure. We can =
of
course account for this in an expected cost.
One final nuance here is if this whole process is visible in the UI we might
want to take into account user discomfort: if I know the process could fail,
the user will probably be happier if it succeeds quickly, even if the
probability of success in the future is still very high.
FWIW the approach taken by the OpenTimestamps calendars is a trivial linear
increase. While they don't have deadlines in the same sense as your
application, there is a trade-off between cost and confirmation time. So our
strategy is to spend money at a constant rate by simply bumping the fee by =
the
same amount at every new block. I could improve this by using knowledge of =
the
mempool. But so far I haven't bothered.
--=20
https://petertodd.org 'peter'[:-1]@petertodd.org
--gTOQlUl3d0imVUeI
Content-Type: application/pgp-signature; name="signature.asc"
-----BEGIN PGP SIGNATURE-----
iQIzBAEBCgAdFiEE0RcYcKRzsEwFZ3N5Lly11TVRLzcFAmGyCacACgkQLly11TVR
LzfgpA//Um5FKs6Oath2qfE4xjLc3DSVietzZ/EgmorZMtB6wHqiKbrxdGzMibks
c1t0MdOccd5eg01AsiMv5Ms0CL6HIAN1O2J8OmBORb9vcvz9DvL1gzwnQWYhhsCD
OSPeSq5TCjw9J6HwR02KPspvFlIfYdjU+S3gydQt740DgfKJ5jHLdMvr847G+ChQ
782aeH/jrRic7WLsEQ8BHxTWGNICqAui/7tQFugu1jCt+p2O8Gg/advksQ6dao0o
i63UHdMZsElr8DcNQgglQ8x47Yu/2DfVpjKRRkWILWbG4PrE7RtFIhANHgwgREGE
7R8XfNy9aL/9vd9UgmrAKvDIp9lxyU3Sk0RpmkFcng8t7DvwwOI0NSMq4WiBTYHA
8emwgiFZHajK4lqh7sGdT5FkChn9gOJlAbLDF3+txiWyob9pVq20Be7JapXhmuxd
UlH4lp+xD0SUa+xQExnxF2BTKFwGIS26RWUtoPIZxKWHVB5bXXT43iHJdvCzLJMw
oRoHH7J6UEWJe9DStt9/iXXgZ4iI3G0IaMpkuYi9zxmxA57NE3RGLt2nZNkINNY8
Um/pC3JlLdwAwMZkcqB2wuKwRF0r4CR3Cw1Y1bFMbB9x2XC66RgTHkOdc5Bc1WYV
jVpmKdb5w8F2aPFuepfd7aIDw7f5BgJAvssFhj7+88COXwAYLAk=
=tdsx
-----END PGP SIGNATURE-----
--gTOQlUl3d0imVUeI--
|