Christian Decker [ARCHIVE] on Nostr: 📅 Original date posted:2019-10-03 📝 Original message: Anthony Towns <aj at ...
📅 Original date posted:2019-10-03
📝 Original message:
Anthony Towns <aj at erisian.com.au> writes:
> On Mon, Sep 30, 2019 at 03:23:56PM +0200, Christian Decker via bitcoin-dev wrote:
>> With the recently renewed interest in eltoo, a proof-of-concept implementation
>> [1], and the discussions regarding clean abstractions for off-chain protocols
>> [2,3], I thought it might be time to revisit the `sighash_noinput` proposal
>> (BIP-118 [4]), and AJ's `bip-anyprevout` proposal [5].
>
> Hey Christian, thanks for the write up!
>
>> ## Open questions
>> The questions that remain to be addressed are the following:
>> 1. General agreement on the usefulness of noinput / anyprevoutanyscript /
>> anyprevout[?]
>> 2. Is there strong support or opposition to the chaperone signatures[?]
>> 3. The same for output tagging / explicit opt-in[?]
>> 4. Shall we merge BIP-118 and bip-anyprevout. This would likely reduce the
>> confusion and make for simpler discussions in the end.
>
> I think there's an important open question you missed from this list:
> (1.5) do we really understand what the dangers of noinput/anyprevout-style
> constructions actually are?
>
> My impression on the first 3.5 q's is: (1) yes, (1.5) not really,
> (2) weak opposition for requiring chaperone sigs, (3) mixed (weak)
> support/opposition for output tagging.
>
> My thinking at the moment (subject to change!) is:
>
> * anyprevout signatures make the address you're signing for less safe,
> which may cause you to lose funds when additional coins are sent to
> the same address; this can be avoided if handled with care (or if you
> don't care about losing funds in the event of address reuse)
>
> * being able to guarantee that an address can never be signed for with
> an anyprevout signature is therefore valuable; so having it be opt-in
> at the tapscript level, rather than a sighash flag available for
> key-path spends is valuable (I call this "opt-in", but it's hidden
> until use via taproot rather than "explicit" as output tagging
> would be)
>
> * receiving funds spent via an anyprevout signature does not involve any
> qualitatively new double-spending/malleability risks.
>
> (eltoo is unavoidably malleable if there are multiple update
> transactions (and chaperone signatures aren't used or are used with
> well known keys), but while it is better to avoid this where possible,
> it's something that's already easily dealt with simply by waiting
> for confirmations, and whether a transaction is malleable is always
> under the control of the sender not the receiver)
>
> * as such, output tagging is also unnecessary, and there is also no
> need for users to mark anyprevout spends as "tainted" in order to
> wait for more confirmations than normal before considering those funds
> "safe"
Excellent points, I had missed the hidden nature of the opt-in via
pubkey prefix while reading your proposal. I'm starting to like that
option more and more. In that case we'd only ever be revealing that we
opted into anyprevout when we're revealing the entire script anyway, at
which point all fungibility concerns go out the window anyway.
Would this scheme be extendable to opt into all sighash flags the
outpoint would like to allow (e.g., adding opt-in for sighash_none and
sighash_anyonecanpay as well)? That way the pubkey prefix could act as a
mask for the sighash flags and fail verification if they don't match.
> I think it might be good to have a public testnet (based on Richard Myers
> et al's signet2 work?) where we have some fake exchanges/merchants/etc
> and scheduled reorgs, and demo every weird noinput/anyprevout case anyone
> can think of, and just work out if we need any extra code/tagging/whatever
> to keep those fake exchanges/merchants from losing money (and write up
> the weird cases we've found in a wiki or a paper so people can easily
> tell if we missed something obvious).
That'd be great, however even that will not ensure that every possible
corner case is handled and from experience it seems that people are
unwilling to invest a lot of time testing on a network unless their
money is on the line. That's not to say that we shouldn't try, we
absolutely should, I'm just not sure it alone is enough to dispell all
remaining doubts :-)
Cheers,
Christian
Published at
2023-06-09 12:56:22Event JSON
{
"id": "2ed2ac34a99c868eea37a790e2da16189a8a1e2beb469409c81144b4aacde302",
"pubkey": "72cd40332ec782dd0a7f63acb03e3b6fdafa6d91bd1b6125cd8b7117a1bb8057",
"created_at": 1686315382,
"kind": 1,
"tags": [
[
"e",
"cdcb20d8f8d63cc4e462299d7b2042087b535b172c963061dbb6929331fffa55",
"",
"root"
],
[
"e",
"7312d377791217fa3697affa0cbd5161f20cb1b68f56739ad9b653c2f8495197",
"",
"reply"
],
[
"p",
"947955301a8805054c8d6a2c9ac2abf07a7a18f4a33b0a573a277868302953b1"
]
],
"content": "📅 Original date posted:2019-10-03\n📝 Original message:\nAnthony Towns \u003caj at erisian.com.au\u003e writes:\n\n\u003e On Mon, Sep 30, 2019 at 03:23:56PM +0200, Christian Decker via bitcoin-dev wrote:\n\u003e\u003e With the recently renewed interest in eltoo, a proof-of-concept implementation\n\u003e\u003e [1], and the discussions regarding clean abstractions for off-chain protocols\n\u003e\u003e [2,3], I thought it might be time to revisit the `sighash_noinput` proposal\n\u003e\u003e (BIP-118 [4]), and AJ's `bip-anyprevout` proposal [5].\n\u003e\n\u003e Hey Christian, thanks for the write up!\n\u003e\n\u003e\u003e ## Open questions\n\u003e\u003e The questions that remain to be addressed are the following:\n\u003e\u003e 1. General agreement on the usefulness of noinput / anyprevoutanyscript /\n\u003e\u003e anyprevout[?]\n\u003e\u003e 2. Is there strong support or opposition to the chaperone signatures[?]\n\u003e\u003e 3. The same for output tagging / explicit opt-in[?]\n\u003e\u003e 4. Shall we merge BIP-118 and bip-anyprevout. This would likely reduce the\n\u003e\u003e confusion and make for simpler discussions in the end.\n\u003e\n\u003e I think there's an important open question you missed from this list:\n\u003e (1.5) do we really understand what the dangers of noinput/anyprevout-style\n\u003e constructions actually are?\n\u003e\n\u003e My impression on the first 3.5 q's is: (1) yes, (1.5) not really,\n\u003e (2) weak opposition for requiring chaperone sigs, (3) mixed (weak)\n\u003e support/opposition for output tagging.\n\u003e\n\u003e My thinking at the moment (subject to change!) is:\n\u003e\n\u003e * anyprevout signatures make the address you're signing for less safe,\n\u003e which may cause you to lose funds when additional coins are sent to\n\u003e the same address; this can be avoided if handled with care (or if you\n\u003e don't care about losing funds in the event of address reuse)\n\u003e\n\u003e * being able to guarantee that an address can never be signed for with\n\u003e an anyprevout signature is therefore valuable; so having it be opt-in\n\u003e at the tapscript level, rather than a sighash flag available for\n\u003e key-path spends is valuable (I call this \"opt-in\", but it's hidden\n\u003e until use via taproot rather than \"explicit\" as output tagging\n\u003e would be)\n\u003e\n\u003e * receiving funds spent via an anyprevout signature does not involve any\n\u003e qualitatively new double-spending/malleability risks.\n\u003e \n\u003e (eltoo is unavoidably malleable if there are multiple update\n\u003e transactions (and chaperone signatures aren't used or are used with\n\u003e well known keys), but while it is better to avoid this where possible,\n\u003e it's something that's already easily dealt with simply by waiting\n\u003e for confirmations, and whether a transaction is malleable is always\n\u003e under the control of the sender not the receiver)\n\u003e\n\u003e * as such, output tagging is also unnecessary, and there is also no\n\u003e need for users to mark anyprevout spends as \"tainted\" in order to\n\u003e wait for more confirmations than normal before considering those funds\n\u003e \"safe\"\n\nExcellent points, I had missed the hidden nature of the opt-in via\npubkey prefix while reading your proposal. I'm starting to like that\noption more and more. In that case we'd only ever be revealing that we\nopted into anyprevout when we're revealing the entire script anyway, at\nwhich point all fungibility concerns go out the window anyway.\n\nWould this scheme be extendable to opt into all sighash flags the\noutpoint would like to allow (e.g., adding opt-in for sighash_none and\nsighash_anyonecanpay as well)? That way the pubkey prefix could act as a\nmask for the sighash flags and fail verification if they don't match.\n\n\u003e I think it might be good to have a public testnet (based on Richard Myers\n\u003e et al's signet2 work?) where we have some fake exchanges/merchants/etc\n\u003e and scheduled reorgs, and demo every weird noinput/anyprevout case anyone\n\u003e can think of, and just work out if we need any extra code/tagging/whatever\n\u003e to keep those fake exchanges/merchants from losing money (and write up\n\u003e the weird cases we've found in a wiki or a paper so people can easily\n\u003e tell if we missed something obvious).\n\nThat'd be great, however even that will not ensure that every possible\ncorner case is handled and from experience it seems that people are\nunwilling to invest a lot of time testing on a network unless their\nmoney is on the line. That's not to say that we shouldn't try, we\nabsolutely should, I'm just not sure it alone is enough to dispell all\nremaining doubts :-)\n\nCheers,\nChristian",
"sig": "5fcdb46704b3d30e4fb0c9ecb33037b61428f8af2a477afc14b082365278386ed46b54071cecfb331f85023643876c38cc832737ff02fed1b409935b07f1eb41"
}