summaryrefslogtreecommitdiff
path: root/4a/d6467ea9925f0c3716de9a6b28d831d15c22b8
blob: e3ea7288f68a1cfa91d00bb61af5bdd6fe3c3b7a (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
Return-Path: <ZmnSCPxj@protonmail.com>
Received: from smtp1.linuxfoundation.org (smtp1.linux-foundation.org
	[172.17.192.35])
	by mail.linuxfoundation.org (Postfix) with ESMTPS id CB93FDB9
	for <bitcoin-dev@lists.linuxfoundation.org>;
	Mon, 29 Jul 2019 01:46:48 +0000 (UTC)
X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6
Received: from mail-40130.protonmail.ch (mail-40130.protonmail.ch
	[185.70.40.130])
	by smtp1.linuxfoundation.org (Postfix) with ESMTPS id 079E35E4
	for <bitcoin-dev@lists.linuxfoundation.org>;
	Mon, 29 Jul 2019 01:46:47 +0000 (UTC)
Date: Mon, 29 Jul 2019 01:46:40 +0000
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com;
	s=default; t=1564364805;
	bh=dxW1gShqHAGC47zhyGBTsaAKQSqEpCdhQo8DYfiPo3Y=;
	h=Date:To:From:Cc:Reply-To:Subject:In-Reply-To:References:
	Feedback-ID:From;
	b=IB3nqPaj7kmoAyp/viEDMLXLUA8ru3LqJ6QJyQA/76oAMwVGTjLccrBusvD2/5kmp
	QF+ZxUq/r9C48Crfvg5GKstx5azzh+IK3EBs159sYRohVjV5iiUqH/0l+vZaky1FZW
	e9gDvmqGBef71KO5cW8I5Wz7dZ2tjBlDXwDkElCc=
To: Mike Brooks <m@ib.tc>
From: ZmnSCPxj <ZmnSCPxj@protonmail.com>
Reply-To: ZmnSCPxj <ZmnSCPxj@protonmail.com>
Message-ID: <dW426iyRLdy0-CbpWL9pG7dG8qvmyQizPrwuBVHpblJBCBDSMjeIuFMiTjNHOaMfUzjaW2btTiFD9PiozOt9Cv5DQUZG0o22hYndr2wk3SI=@protonmail.com>
In-Reply-To: <CALFqKjQoA+4XKGePHEK9OAZv2+qg=Q669v=f=MpDtg4F3Fx4kQ@mail.gmail.com>
References: <CALFqKjQkQwuxjeYkGWO_Y_HhNQmJgrjqF3m04hbORV7FSbsi3Q@mail.gmail.com>
	<nk8ihWbf71QT6w-wVbnunppF_DjS8ywDoDAugBj5mYM_LCpSzec0j6lkaTKBK4t3CsXwRSXWmzbWiW7nmqT4y0W2fn8X-3oXv-TAYXwP1R4=@protonmail.com>
	<CALFqKjQoA+4XKGePHEK9OAZv2+qg=Q669v=f=MpDtg4F3Fx4kQ@mail.gmail.com>
Feedback-ID: el4j0RWPRERue64lIQeq9Y2FP-mdB86tFqjmrJyEPR9VAtMovPEo9tvgA0CrTsSHJeeyPXqnoAu6DN-R04uJUg==:Ext:ProtonMail
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
X-Spam-Status: No, score=-2.2 required=5.0 tests=BAYES_00,DKIM_SIGNED,
	DKIM_VALID, DKIM_VALID_AU, FREEMAIL_FROM, FROM_LOCAL_NOVOWEL,
	RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.1
X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on
	smtp1.linux-foundation.org
X-Mailman-Approved-At: Mon, 29 Jul 2019 02:53:15 +0000
Cc: Bitcoin Protocol Discussion <bitcoin-dev@lists.linuxfoundation.org>,
	"pieter.wuille@gmail.com" <pieter.wuille@gmail.com>
Subject: Re: [bitcoin-dev] PubRef - Script OP Code For Public Data References
X-BeenThere: bitcoin-dev@lists.linuxfoundation.org
X-Mailman-Version: 2.1.12
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: Mon, 29 Jul 2019 01:46:49 -0000

Good morning Mike,


Sent with ProtonMail Secure Email.

=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90 Original Me=
ssage =E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90
On Sunday, July 28, 2019 4:03 AM, Mike Brooks <m@ib.tc> wrote:

> Hey ZmnSCPxj,
>
> As to your first point.=C2=A0 I wasn't aware there was so much volatility=
 at the tip, also 100 blocks is quite the difference!=C2=A0 I agree no one =
could references a transaction in a newly formed blocks, but I'm curious ho=
w this number was chosen. Do you have any documentation or code that you ca=
n share related to how re-orgs are handled? Do we have a kind of 'consensus=
 checkpoint' when a re-org is no longer possible? This is a very interestin=
g topic.
>

Miner coinbases need 100 blocks for maturity, which is the basis of my sugg=
estion to use 100 blocks.
It might be too high, but I doubt there will be good reason to be less than=
 100.

There is a potential for a targeted attack where a large payout going to a =
`scriptPubKey` that uses `OP_PUBREF` on a recently-confirmed transaction fi=
nds that recently-confirmed transaction is replaced with one that pays to a=
 different public key, via a history-rewrite attack.
Such an attack is doable by miners, and if we consider that we accept 100 b=
locks for miner coinbase maturity as "acceptably low risk" against miner sh=
enanigans, then we might consider that 100 blocks might be acceptable for t=
his also.
Whether 100 is too high or not largely depends on your risk appetite.

>=C2=A0 A validator only needs an array of PUSHDATA elements and can then v=
alidate any given SCRIPT at O(1).=C2=A0=C2=A0

Data derived from > 220Gb of perpetually-growing blockchain is hardly, to m=
y mind, "only needs an array".
Such an array would not fit in memory for many devices that today are pract=
ical for running fullnodes.
It is keeping that array and indexing it which is the problem, i.e. the dev=
il in the details.

Reiterating also, current pruned nodes did not retain that data and would b=
e forced to re-download the entire blockchain.
Unless you propose that we can refer only to `OP_PUSHDATA` after activation=
 of `OP_PUSHREF`.

Regards,
ZmnSCPxj