Ross Nicoll [ARCHIVE] on Nostr: 📅 Original date posted:2015-08-10 📝 Original message:Trimmed some of the thread ...
📅 Original date posted:2015-08-10
📝 Original message:Trimmed some of the thread to clarity
On 10/08/2015 19:40, Luke Dashjr wrote:
>>>> I propose adding a new optional "genesis" field as a 16 byte sequence
>>>> containing the SHA-256 hash of the genesis block of the network the
>>>> request belongs to, uniquely identifying chains without any requirement
>>>> for a central registry.
>>> Genesis blocks are not necessarily unique. For example, Litecoin and
>>> Feathercoin share the same one.
>> Had missed that, and there's no easy alternatives. BIP 44 chain IDs
>> don't identify different testnets, and do not cover regtest at all.
> Regtest isn't really a network at all, just a testing mode of Bitcoin Core...
True, but as Jorge points out, it's generally better not to have special
cases.
>> Most recent block hash could be used and also provides fork
>> detection, but in doing so advertises if a merchant is on the wrong
>> fork. Will think about it.
> Is that a bad thing?
It was something I was thinking about with the BIP 66 fork, that it
could be used as a safety measure, but could also be used to find
merchants & exchanges who are accepting coins on the wrong branch of a
fork (and therefore are susceptible to double-spend attacks). For fork
detection it's probably safer for the client to provide a recent block
hash with the payment response.
I think genesis hash collisions are probably acceptable; or, the
duplicate coins are so far rarely long-lived and it's therefore not a
major concern at least. The server should reject any attempt to pay on
the wrong chain, in hindsight, as it will try to relay on the network it
expects and the transaction will be rejected.
>>> I'd appreciate initial feedback on the idea, and if there's no major
>>> objections I'll raise this as a BIP.
>> I don't see how this is related to improving Bitcoin...
>>
>> Well, mostly I'm trying not to avoid the situation where any accidental
>> mixing of files is dangerous (funds can easily be sent on the wrong
>> blockchain), nor with multiple standards (which is where we are at the
>> moment). It improves things in avoiding future problems, rather than in
>> the immediate term.
> Sorry, I meant to stress that BIPs are for *Bitcoin* improvements
> specifically. Things which only improve altcoins, while a perfectly fine thing
> to standardise, are outside the scope of what belongs in a BIP.
>
> Perhaps, however, this could be made to kill 2 birds with one stone, by
> ensuring it addresses the need for payments made of bitcoins on a sidechain?
> For this, a merchant who wants a sidechain payment would presumably be able to
> provide a script from the main chain already, but an extension allowing
> payment directly on the sidechain (at the customer's choice) avoids the need
> to round-trip it...
That could definitely be done, for example by making the genesis field
"repeated", so it specifies all potential networks. The response would
need to indicate which hash it used, but that could be chain tip (with
height in a further field), and provide fork detection.
Ross
Published at
2023-06-07 17:34:32Event JSON
{
"id": "eddadbed947ba96a13857d9b9f1e99e1b8f211d29d4c162e362dbb9d6b99f96d",
"pubkey": "787ecd48da0d9610d322fb67c86ad23a5287d688559b2ff8ee546721fd990129",
"created_at": 1686159272,
"kind": 1,
"tags": [
[
"e",
"a705c666a2ba5f9b9fec1e15ec37ee592936203f74c541b73847f917a0090786",
"",
"root"
],
[
"e",
"58219680807a44692337ce21fe91c442509207324540e4ff07e88122f03b0bb3",
"",
"reply"
],
[
"p",
"5a6d1f44482b67b5b0d30cc1e829b66a251f0dc99448377dbe3c5e0faf6c3803"
]
],
"content": "📅 Original date posted:2015-08-10\n📝 Original message:Trimmed some of the thread to clarity\n\nOn 10/08/2015 19:40, Luke Dashjr wrote:\n\u003e\u003e\u003e\u003e I propose adding a new optional \"genesis\" field as a 16 byte sequence\n\u003e\u003e\u003e\u003e containing the SHA-256 hash of the genesis block of the network the\n\u003e\u003e\u003e\u003e request belongs to, uniquely identifying chains without any requirement\n\u003e\u003e\u003e\u003e for a central registry.\n\u003e\u003e\u003e Genesis blocks are not necessarily unique. For example, Litecoin and\n\u003e\u003e\u003e Feathercoin share the same one.\n\u003e\u003e Had missed that, and there's no easy alternatives. BIP 44 chain IDs\n\u003e\u003e don't identify different testnets, and do not cover regtest at all.\n\u003e Regtest isn't really a network at all, just a testing mode of Bitcoin Core...\nTrue, but as Jorge points out, it's generally better not to have special \ncases.\n\n\u003e\u003e Most recent block hash could be used and also provides fork\n\u003e\u003e detection, but in doing so advertises if a merchant is on the wrong\n\u003e\u003e fork. Will think about it.\n\u003e Is that a bad thing?\nIt was something I was thinking about with the BIP 66 fork, that it \ncould be used as a safety measure, but could also be used to find \nmerchants \u0026 exchanges who are accepting coins on the wrong branch of a \nfork (and therefore are susceptible to double-spend attacks). For fork \ndetection it's probably safer for the client to provide a recent block \nhash with the payment response.\n\nI think genesis hash collisions are probably acceptable; or, the \nduplicate coins are so far rarely long-lived and it's therefore not a \nmajor concern at least. The server should reject any attempt to pay on \nthe wrong chain, in hindsight, as it will try to relay on the network it \nexpects and the transaction will be rejected.\n\n\u003e\u003e\u003e I'd appreciate initial feedback on the idea, and if there's no major\n\u003e\u003e\u003e objections I'll raise this as a BIP.\n\u003e\u003e I don't see how this is related to improving Bitcoin...\n\u003e\u003e\n\u003e\u003e Well, mostly I'm trying not to avoid the situation where any accidental\n\u003e\u003e mixing of files is dangerous (funds can easily be sent on the wrong\n\u003e\u003e blockchain), nor with multiple standards (which is where we are at the\n\u003e\u003e moment). It improves things in avoiding future problems, rather than in\n\u003e\u003e the immediate term.\n\u003e Sorry, I meant to stress that BIPs are for *Bitcoin* improvements\n\u003e specifically. Things which only improve altcoins, while a perfectly fine thing\n\u003e to standardise, are outside the scope of what belongs in a BIP.\n\u003e\n\u003e Perhaps, however, this could be made to kill 2 birds with one stone, by\n\u003e ensuring it addresses the need for payments made of bitcoins on a sidechain?\n\u003e For this, a merchant who wants a sidechain payment would presumably be able to\n\u003e provide a script from the main chain already, but an extension allowing\n\u003e payment directly on the sidechain (at the customer's choice) avoids the need\n\u003e to round-trip it...\n\nThat could definitely be done, for example by making the genesis field \n\"repeated\", so it specifies all potential networks. The response would \nneed to indicate which hash it used, but that could be chain tip (with \nheight in a further field), and provide fork detection.\n\nRoss",
"sig": "a5f8a207de3291be03086a1669ea0841422d602e8a5352d5b4ae587f823277db0f24250015e7dc3a251bfcc0d10e563246e147fff830df10571d0390daa093da"
}