Michael Folkson [ARCHIVE] on Nostr: đź“… Original date posted:2022-08-04 đź“ť Original message:Thanks for this Luke. > ...
đź“… Original date posted:2022-08-04
đź“ť Original message:Thanks for this Luke.
> Since BIP125 is widely implemented, it should not be changed except for corrections to things which are errors deviating from the original intent.
In this example the BIP125/RBF rules implemented in Core are (and always have been) different to the rules as described in BIP125. As far as I know other implementations have also followed how it is implemented in Core rather than as described in BIP125. So we have the BIP125 rules, BIP125/RBF as implemented in Core and future intended changes to how RBF rules are implemented in Core which may or may not also be in a state of flux. I take the view that once those new RBF rules are "finalized" there should be a new BIP but others disagree.
> Also note that security should NEVER depend on assumptions of node policies. Doing so would be a serious security vulnerability, regardless of what actual network policies are.
You regularly state this and of course you're right. I tried to allude that it is far from ideal that L2 security is impacted by default policy rules to any extent in my post. But if it is a matter of fact that default policy rules impact the viability of some L2 protocol attacks today what should one do when setting default policy rules in the dominant implementation on the network? I think you lean towards not factoring that in whatsoever to decisions on default policy rules whereas (perhaps mistakenly) I lean towards factoring that in to default policy rule decisions especially when there don't seem to be many other factors to consider. In the case of Lightning Network I think we both want it to succeed and hopefully in the long term default policy rules will have no impact on its security whatsoever. But today that seems to not be the case.
--
Michael Folkson
Email: michaelfolkson at protonmail.com
Keybase: michaelfolkson
PGP: 43ED C999 9F85 1D40 EAF4 9835 92D6 0159 214C FEE3
------- Original Message -------
On Thursday, August 4th, 2022 at 20:35, Luke Dashjr <luke at dashjr.org> wrote:
> Policy is a subjective per-node, not systemic, not enforcable or expectable,
> and generally not eligible for standardization.
>
> The reason BIP125 is an exception, is because it is more than just policy.
> It is a way for wallets and nodes to communicate. The wallet is saying "this
> is the policy I would like you to apply to potential replacements of these
> transactions". Whether the nodes abide this request or not, the purpose and
> justification of the BIP is to standardize the communication of it.
>
> Since BIP125 is widely implemented, it should not be changed except for
> corrections to things which are errors deviating from the original intent.
> If there is merely a new policy intended to be conveyed, a new BIP should be
> written that is distinguishable from BIP125 (perhaps drop the sequence number
> by 1 more). However, unless nodes are going to honour both the BIP125-request
> policy and a new policy, it might be simpler for them to just not honour
> the requested BIP125 policy exactly.
>
> Also note that security should NEVER depend on assumptions of node policies.
> Doing so would be a serious security vulnerability, regardless of what actual
> network policies are. It's fine to blame nodes/miners if they single out your
> transactions, but if it's just a matter of a general policy your transactions
> are failing to meet, that's on the sender/L2 to adapt.
>
> Luke
>
>
> On Thursday 04 August 2022 14:54:54 Michael Folkson via bitcoin-dev wrote:
>
> > A short history of RBF and BIP125
> >
> > The history of BIP125 is as far as I’m aware this. RBF rules were merged
> > into Bitcoin Core in November 2015 0. Following that merge David Harding
> > and Peter Todd drafted a BIP (BIP125 1) outlining the RBF rules that had
> > been implemented in Bitcoin Core. The rationales for the rules in the BIP
> > was a bit lacking (in my opinion) but recall this is 2015 (7 years ago!)
> > when L2 protocols were in their infancy. Certainly the research on the
> > security of L2 protocols has come a long way since and we have a much
> > better idea of some of the possible attacks on L2 protocols that to some
> > extent are impacted by policy rules.
> >
> > In addition it was discovered 2 in May 2021 that the Bitcoin Core
> > implementation of the RBF rules had never matched the RBF rules outlined in
> > BIP125. Clearly this isn’t ideal but mistakes happen and will continue to
> > happen. I certainly do not intend any criticism whatsoever to any of the
> > individuals involved. Thankfully this discrepancy doesn’t seem to have
> > resulted in any loss of funds or disruption. However, cross checking a
> > specification with an implementation presumably led to the discovery and
> > allowed for a post mortem on why the implementation didn’t match the
> > specification.
> >
> > There seems to be two views on what to do next given that the RBF rules
> > need to be updated. One is to ditch the idea of a specification for RBF
> > rules and just document them in the Core repo instead. The other is to have
> > a new specification for the RBF rules in Core and attempt to correct the
> > mistakes made with BIP125 by having a BIP that does correctly outline the
> > RBF rules implemented in Core and includes detailed rationales for why
> > those RBF rules have been implemented.
> >
> > Should anyone care about where things are documented?
> >
> > Perhaps not but I think if you are a stakeholder in L2 protocol security
> > you should. Suppose in the long term future an attacker exploits a L2
> > vulnerability that is based on the default policy set by the dominant
> > implementation on the network (Bitcoin Core). Which would you prefer the
> > norm to be? A detailed static, well reviewed BIP standard that lays out the
> > updated RBF rules and the rationales for those new rules that is reviewed
> > outside the Core repo and hence not just by Core reviewers? Or cross
> > checking Bitcoin Core code with non-standardized Core documentation
> > typically reviewed only by Core reviewers?
> >
> > For the same reason the norm for consensus changes is a specification (BIP)
> > and a reference implementation (Bitcoin Core) I think the norm for material
> > step change policy changes should be a specification (BIP) and a reference
> > implementation (Bitcoin Core). Policy is of course less risky than
> > consensus for various reasons including there being no chain split risk if
> > the user changes the default policy of their node. Alternative
> > implementations are free to set entirely different policy rules too. But
> > with L2 protocol security to some extent relying on policy whether we like
> > it or not I think we should aspire to similar standards where possible for
> > policy too.
> >
> > Specifications and implementations
> >
> > The Bitcoin Core review process generally requires Concept ACKs, Approach
> > ACKs and then code review, testing ACKs in that order. The reason for this
> > is even if the code is perfect if it is implementing a concept or an
> > approach that informed reviewers oppose then it doesn’t matter that the
> > code is perfect. Documentation is generally done post merge if at all. For
> > most PRs e.g. refactors this makes sense. There is no point documenting
> > something in advance if it is still under review or may not get merged. For
> > consensus PRs this clearly doesn’t make sense. Many of us have and continue
> > to cross check the Taproot BIPs with the Taproot reference implementation
> > in Bitcoin Core. Having two points of reference released simultaneously is
> > treating consensus changes with the highest possible standards we can. I
> > think we should strive towards the highest possible standards for step
> > change default policy changes in Core too given L2 protocol security is
> > (unfortunately, ideally this wouldn’t be the case) relying on them.
> >
> > What are the new RBF rules replacing the BIP125 rules?
> >
> > The new RBF rules as implemented in Core today are documented here 3 in
> > the Core repo (thanks for the link glozow). To the extent that these are a
> > work in progress or close to final (i.e. intended to be static) I don’t
> > know. The devs who work on policy will have a much better idea on these
> > questions than me. Will the new RBF rules continue to be iterated upon as
> > new research on L2 security comes to light? Will this iteration make it
> > impossible to maintain a static set of rules that the broader ecosystem can
> > get comfortable with? Or is a new static set of RBF rules close to being
> > finalized and there is just an aversion to using BIPs and a specification?
> >
> > Generally, as time passes, the ecosystem grows, layers on top of the base
> > layer get built out I get uncomfortable with what I perceive (correctly or
> > incorrectly) as a slip in standards. If anything it should be going in the
> > opposite direction. Standards should be improving and we should be striving
> > to do better and be more rigorous than whatever the standard was in 2015.
> > But I don’t work on policy in Core full time and it is very possible that
> > there are subtleties that I’m entirely missing here. I think this is the
> > right forum to ask about those subtleties though. Thanks to those who work
> > on this important area.
> >
> > l
> >
> > nts.md
> >
> > --
> > Michael Folkson
> > Email: michaelfolkson at protonmail.com
> > Keybase: michaelfolkson
> > PGP: 43ED C999 9F85 1D40 EAF4 9835 92D6 0159 214C FEE3
Published at
2023-06-07 23:12:33Event JSON
{
"id": "e9a133159d14a019864d7e5165717d617bac686ca33b4bcc12b15d331e45822f",
"pubkey": "7c4981f0d3c5eec97631de273b25b6435f0f33e0fa6cce270ddd3f3b8797d26a",
"created_at": 1686179553,
"kind": 1,
"tags": [
[
"e",
"0dc1c8f41bf99d010af2db4c37c5a0fb78d82ad485e5161813a693185f552a84",
"",
"root"
],
[
"e",
"d85d4d3ceedd198cbe2a8ecd848c4b1061e6689a6dc7b6d1731413e355a26db6",
"",
"reply"
],
[
"p",
"5a6d1f44482b67b5b0d30cc1e829b66a251f0dc99448377dbe3c5e0faf6c3803"
]
],
"content": "📅 Original date posted:2022-08-04\n📝 Original message:Thanks for this Luke.\n\n\u003e Since BIP125 is widely implemented, it should not be changed except for corrections to things which are errors deviating from the original intent.\n\nIn this example the BIP125/RBF rules implemented in Core are (and always have been) different to the rules as described in BIP125. As far as I know other implementations have also followed how it is implemented in Core rather than as described in BIP125. So we have the BIP125 rules, BIP125/RBF as implemented in Core and future intended changes to how RBF rules are implemented in Core which may or may not also be in a state of flux. I take the view that once those new RBF rules are \"finalized\" there should be a new BIP but others disagree.\n\n\u003e Also note that security should NEVER depend on assumptions of node policies. Doing so would be a serious security vulnerability, regardless of what actual network policies are.\n\nYou regularly state this and of course you're right. I tried to allude that it is far from ideal that L2 security is impacted by default policy rules to any extent in my post. But if it is a matter of fact that default policy rules impact the viability of some L2 protocol attacks today what should one do when setting default policy rules in the dominant implementation on the network? I think you lean towards not factoring that in whatsoever to decisions on default policy rules whereas (perhaps mistakenly) I lean towards factoring that in to default policy rule decisions especially when there don't seem to be many other factors to consider. In the case of Lightning Network I think we both want it to succeed and hopefully in the long term default policy rules will have no impact on its security whatsoever. But today that seems to not be the case.\n\n--\nMichael Folkson\nEmail: michaelfolkson at protonmail.com\nKeybase: michaelfolkson\nPGP: 43ED C999 9F85 1D40 EAF4 9835 92D6 0159 214C FEE3\n\n\n------- Original Message -------\nOn Thursday, August 4th, 2022 at 20:35, Luke Dashjr \u003cluke at dashjr.org\u003e wrote:\n\n\n\u003e Policy is a subjective per-node, not systemic, not enforcable or expectable,\n\u003e and generally not eligible for standardization.\n\u003e\n\u003e The reason BIP125 is an exception, is because it is more than just policy.\n\u003e It is a way for wallets and nodes to communicate. The wallet is saying \"this\n\u003e is the policy I would like you to apply to potential replacements of these\n\u003e transactions\". Whether the nodes abide this request or not, the purpose and\n\u003e justification of the BIP is to standardize the communication of it.\n\u003e\n\u003e Since BIP125 is widely implemented, it should not be changed except for\n\u003e corrections to things which are errors deviating from the original intent.\n\u003e If there is merely a new policy intended to be conveyed, a new BIP should be\n\u003e written that is distinguishable from BIP125 (perhaps drop the sequence number\n\u003e by 1 more). However, unless nodes are going to honour both the BIP125-request\n\u003e policy and a new policy, it might be simpler for them to just not honour\n\u003e the requested BIP125 policy exactly.\n\u003e\n\u003e Also note that security should NEVER depend on assumptions of node policies.\n\u003e Doing so would be a serious security vulnerability, regardless of what actual\n\u003e network policies are. It's fine to blame nodes/miners if they single out your\n\u003e transactions, but if it's just a matter of a general policy your transactions\n\u003e are failing to meet, that's on the sender/L2 to adapt.\n\u003e\n\u003e Luke\n\u003e\n\u003e\n\u003e On Thursday 04 August 2022 14:54:54 Michael Folkson via bitcoin-dev wrote:\n\u003e\n\u003e \u003e A short history of RBF and BIP125\n\u003e \u003e\n\u003e \u003e The history of BIP125 is as far as I’m aware this. RBF rules were merged\n\u003e \u003e into Bitcoin Core in November 2015 0. Following that merge David Harding\n\u003e \u003e and Peter Todd drafted a BIP (BIP125 1) outlining the RBF rules that had\n\u003e \u003e been implemented in Bitcoin Core. The rationales for the rules in the BIP\n\u003e \u003e was a bit lacking (in my opinion) but recall this is 2015 (7 years ago!)\n\u003e \u003e when L2 protocols were in their infancy. Certainly the research on the\n\u003e \u003e security of L2 protocols has come a long way since and we have a much\n\u003e \u003e better idea of some of the possible attacks on L2 protocols that to some\n\u003e \u003e extent are impacted by policy rules.\n\u003e \u003e\n\u003e \u003e In addition it was discovered 2 in May 2021 that the Bitcoin Core\n\u003e \u003e implementation of the RBF rules had never matched the RBF rules outlined in\n\u003e \u003e BIP125. Clearly this isn’t ideal but mistakes happen and will continue to\n\u003e \u003e happen. I certainly do not intend any criticism whatsoever to any of the\n\u003e \u003e individuals involved. Thankfully this discrepancy doesn’t seem to have\n\u003e \u003e resulted in any loss of funds or disruption. However, cross checking a\n\u003e \u003e specification with an implementation presumably led to the discovery and\n\u003e \u003e allowed for a post mortem on why the implementation didn’t match the\n\u003e \u003e specification.\n\u003e \u003e\n\u003e \u003e There seems to be two views on what to do next given that the RBF rules\n\u003e \u003e need to be updated. One is to ditch the idea of a specification for RBF\n\u003e \u003e rules and just document them in the Core repo instead. The other is to have\n\u003e \u003e a new specification for the RBF rules in Core and attempt to correct the\n\u003e \u003e mistakes made with BIP125 by having a BIP that does correctly outline the\n\u003e \u003e RBF rules implemented in Core and includes detailed rationales for why\n\u003e \u003e those RBF rules have been implemented.\n\u003e \u003e\n\u003e \u003e Should anyone care about where things are documented?\n\u003e \u003e\n\u003e \u003e Perhaps not but I think if you are a stakeholder in L2 protocol security\n\u003e \u003e you should. Suppose in the long term future an attacker exploits a L2\n\u003e \u003e vulnerability that is based on the default policy set by the dominant\n\u003e \u003e implementation on the network (Bitcoin Core). Which would you prefer the\n\u003e \u003e norm to be? A detailed static, well reviewed BIP standard that lays out the\n\u003e \u003e updated RBF rules and the rationales for those new rules that is reviewed\n\u003e \u003e outside the Core repo and hence not just by Core reviewers? Or cross\n\u003e \u003e checking Bitcoin Core code with non-standardized Core documentation\n\u003e \u003e typically reviewed only by Core reviewers?\n\u003e \u003e\n\u003e \u003e For the same reason the norm for consensus changes is a specification (BIP)\n\u003e \u003e and a reference implementation (Bitcoin Core) I think the norm for material\n\u003e \u003e step change policy changes should be a specification (BIP) and a reference\n\u003e \u003e implementation (Bitcoin Core). Policy is of course less risky than\n\u003e \u003e consensus for various reasons including there being no chain split risk if\n\u003e \u003e the user changes the default policy of their node. Alternative\n\u003e \u003e implementations are free to set entirely different policy rules too. But\n\u003e \u003e with L2 protocol security to some extent relying on policy whether we like\n\u003e \u003e it or not I think we should aspire to similar standards where possible for\n\u003e \u003e policy too.\n\u003e \u003e\n\u003e \u003e Specifications and implementations\n\u003e \u003e\n\u003e \u003e The Bitcoin Core review process generally requires Concept ACKs, Approach\n\u003e \u003e ACKs and then code review, testing ACKs in that order. The reason for this\n\u003e \u003e is even if the code is perfect if it is implementing a concept or an\n\u003e \u003e approach that informed reviewers oppose then it doesn’t matter that the\n\u003e \u003e code is perfect. Documentation is generally done post merge if at all. For\n\u003e \u003e most PRs e.g. refactors this makes sense. There is no point documenting\n\u003e \u003e something in advance if it is still under review or may not get merged. For\n\u003e \u003e consensus PRs this clearly doesn’t make sense. Many of us have and continue\n\u003e \u003e to cross check the Taproot BIPs with the Taproot reference implementation\n\u003e \u003e in Bitcoin Core. Having two points of reference released simultaneously is\n\u003e \u003e treating consensus changes with the highest possible standards we can. I\n\u003e \u003e think we should strive towards the highest possible standards for step\n\u003e \u003e change default policy changes in Core too given L2 protocol security is\n\u003e \u003e (unfortunately, ideally this wouldn’t be the case) relying on them.\n\u003e \u003e\n\u003e \u003e What are the new RBF rules replacing the BIP125 rules?\n\u003e \u003e\n\u003e \u003e The new RBF rules as implemented in Core today are documented here 3 in\n\u003e \u003e the Core repo (thanks for the link glozow). To the extent that these are a\n\u003e \u003e work in progress or close to final (i.e. intended to be static) I don’t\n\u003e \u003e know. The devs who work on policy will have a much better idea on these\n\u003e \u003e questions than me. Will the new RBF rules continue to be iterated upon as\n\u003e \u003e new research on L2 security comes to light? Will this iteration make it\n\u003e \u003e impossible to maintain a static set of rules that the broader ecosystem can\n\u003e \u003e get comfortable with? Or is a new static set of RBF rules close to being\n\u003e \u003e finalized and there is just an aversion to using BIPs and a specification?\n\u003e \u003e\n\u003e \u003e Generally, as time passes, the ecosystem grows, layers on top of the base\n\u003e \u003e layer get built out I get uncomfortable with what I perceive (correctly or\n\u003e \u003e incorrectly) as a slip in standards. If anything it should be going in the\n\u003e \u003e opposite direction. Standards should be improving and we should be striving\n\u003e \u003e to do better and be more rigorous than whatever the standard was in 2015.\n\u003e \u003e But I don’t work on policy in Core full time and it is very possible that\n\u003e \u003e there are subtleties that I’m entirely missing here. I think this is the\n\u003e \u003e right forum to ask about those subtleties though. Thanks to those who work\n\u003e \u003e on this important area.\n\u003e \u003e\n\u003e \u003e l\n\u003e \u003e\n\u003e \u003e nts.md\n\u003e \u003e\n\u003e \u003e --\n\u003e \u003e Michael Folkson\n\u003e \u003e Email: michaelfolkson at protonmail.com\n\u003e \u003e Keybase: michaelfolkson\n\u003e \u003e PGP: 43ED C999 9F85 1D40 EAF4 9835 92D6 0159 214C FEE3",
"sig": "8342180943f21f22c759f8eb523a1ffaa143856ae24eec2de63fea666a1e3947b44b7399328cfcbc6fb2b2c4a11ac3d703777d150c5c129ffac60c0ae4db0a49"
}