<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
  <updated></updated>
  <generator>https://nostr.ae</generator>

  <title>Nostr notes by </title>
  <author>
    <name></name>
  </author>
  <link rel="self" type="application/atom+xml" href="https://nostr.ae/npub1fldyzvpmt2yx6a4tu8asjpkrrn0xy3daht37549g7yzlrm65l7dsq94tkz.rss" />
  <link href="https://nostr.ae/npub1fldyzvpmt2yx6a4tu8asjpkrrn0xy3daht37549g7yzlrm65l7dsq94tkz" />
  <id>https://nostr.ae/npub1fldyzvpmt2yx6a4tu8asjpkrrn0xy3daht37549g7yzlrm65l7dsq94tkz</id>
  <icon></icon>
  <logo></logo>




  <entry>
    <id>https://nostr.ae/nevent1qqs2yurlnul73xlt6x9pru0zlakal6q3v7fw8nhm2mkfqg6mw09n80czyp8a5sfs8ddgsmtk40slkzgxcvwducj9hkaw86j54rcstu002nlek25cuez</id>
    
      <title type="html">📅 Original date posted:2020-11-27 📝 Original message: Thank ...</title>
    
    <link rel="alternate" href="https://nostr.ae/nevent1qqs2yurlnul73xlt6x9pru0zlakal6q3v7fw8nhm2mkfqg6mw09n80czyp8a5sfs8ddgsmtk40slkzgxcvwducj9hkaw86j54rcstu002nlek25cuez" />
    <content type="html">
      In reply to &lt;a href=&#39;/nevent1qqsrcnwlvum2cu7yxul6avrswmqsyedxvq2spmqcal58krvcdd9jzqgdty5v7&#39;&gt;nevent1q…y5v7&lt;/a&gt;&lt;br/&gt;_________________________&lt;br/&gt;&lt;br/&gt;📅 Original date posted:2020-11-27&lt;br/&gt;📝 Original message:&lt;br/&gt;Thank you for your interest :)&lt;br/&gt;&lt;br/&gt;&amp;gt; Quick question: if I am a routing node and receive a valid stake certificate, can I reuse this stake certificate on my own outgoing payments?&lt;br/&gt;&lt;br/&gt;That probably should be avoided, otherwise a mediocre routing node gets a lot of jamming opportunities for no good.&lt;br/&gt;&lt;br/&gt;You are right, that’s a strong argument for proof “interactivity”: every Certificate should probably commit to *at least* public key of the routing node it is generated for.&lt;br/&gt;&lt;br/&gt;– gleb&lt;br/&gt;On Nov 27, 2020, 2:16 AM &#43;0200, ZmnSCPxj &amp;lt;ZmnSCPxj at protonmail.com&amp;gt;, wrote:&lt;br/&gt;&amp;gt; Good morning Gleb and Antoine,&lt;br/&gt;&amp;gt;&lt;br/&gt;&amp;gt; This is certainly interesting!&lt;br/&gt;&amp;gt;&lt;br/&gt;&amp;gt; Quick question: if I am a routing node and receive a valid stake certificate, can I reuse this stake certificate on my own outgoing payments?&lt;br/&gt;&amp;gt;&lt;br/&gt;&amp;gt; It seems to me that the proof-of-stake-certificate should also somehow integrate a detail of the current payment (such as payment hash/point) so it cannot be reused by routing nodes for their own outgoing payments.&lt;br/&gt;&amp;gt;&lt;br/&gt;&amp;gt; For example, looking only at your naive privacy-broken proposal, the signature must use a `sign-to-contract` where the `R` in the signature is actually `R&amp;#39; &#43; h(R&amp;#39; | payment_hash)` with the `R&amp;#39;` also revealed.&lt;br/&gt;&amp;gt;&lt;br/&gt;&amp;gt; Regards,&lt;br/&gt;&amp;gt; ZmnSCPxj&lt;br/&gt;&amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; Hello list,&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; In this post, we explore a different approach to channel jamming mitigation.&lt;br/&gt;&amp;gt; &amp;gt; We won’t talk about the background here, for the problem description as well as some proposed solutions (mainly upfront payment schemes), see [1].&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; We’re suggesting using UTXO ownership proofs (a.k.a. Stake Certificates) to solve this problem. Previously, these proofs were only used in the Lightning Network at channel announcement time to prevent malicious actors from announcing channels they don’t control. One can think of it as a “fidelity bond” (as a scarce resource) as a requirement for sending HTLCs.&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; We start by overviewing issues with other solutions, and then present a naive, privacy-broken Stake Certificates. Then we examine designing a privacy-preserving version, evaluating them. At the end, we talk about non-trivial design decisions and open questions.&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; ## Issues with other proposals&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; We find unsatisfying that upfront payment schemes come at a cost of new fees (forward and/or backward), thus inflating payment cost for *any* payment.&lt;br/&gt;&amp;gt; &amp;gt; In the future, the upfront base fee might even make “micropayments” economically infeasible by exceeding the value they transfer. Thus, a good solution should not inflate payment cost while still requiring “burning” a scarce resource (so that the attack is not free).&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; Another issue with upfront payments is a circular trust dependency. Ideally, we shouldn’t introduce anything less trust-minimized than the Lightning Network itself.&lt;br/&gt;&amp;gt; &amp;gt; Upfront payment schemes are not like that, because they in one way or another rely on the honest behavior of route participants.&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; We believe Stake Certificates we are going to introduce are satisfactory in both of these directions: they don’t inflate payment costs for honest users and don’t require trust. The main disadvantage of Stake Certificates seems to be the novel cryptography required.&lt;br/&gt;&amp;gt; &amp;gt; See more details in the “Evaluation” section.&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; ## Channel Ownership Proofs as Routing Credit Balance&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; Let’s say Alice wants to relay an HTLC to Carol through Bob. Per the Stake Certificates scheme, she has to commit to a particular channel UTXO by embedding an ownership proof in the onion packet while sending an HTLC to Bob.&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; Bob then unwraps the onion and verifies:&lt;br/&gt;&amp;gt; &amp;gt; 1) the channel identifier is pointing unambiguously to an on-chain UTXO;&lt;br/&gt;&amp;gt; &amp;gt; 2) the ownership proof (e.g., a signature) is valid against the previously disclosed UTXO witness script.&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; If all those checks succeed, Bob should see if Alice hasn’t exceeded her credit balance. In case she hasn’t, Bob has to “decrement Alice’s credit balance” and relay the HTLC to Carol.&lt;br/&gt;&amp;gt; &amp;gt; Decrementing credit balance unconditionally of packet success or failure bounds liquidity abuse by malicious HTLC senders.&lt;br/&gt;&amp;gt; &amp;gt; Since there is no credit assigned initially, “decrementing the credit balance” means just remembering that “Alice spent X out of Y of the credit she received for her Stake Certificates”.&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; Unfortunately, this naive protocol is a privacy nightmare, because routing nodes can now easily assign every HTLC they forward to the sender’s UTXO.&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; Let’s first define the terms here one more time, and then proceed to the non-naive, private Stake Certificates.&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; - Stake Certificate. Either means a solution we’re proposing or the primitive it is based on, namely proof of UTXO ownership. As we will argue later, it actually makes sense to use proof of LN channel UTXO ownership specifically rather than any funds ownership.&lt;br/&gt;&amp;gt; &amp;gt; - Stake Certificate value. An amount of the corresponding UTXO or a ballpark this amount provably  belongs to.&lt;br/&gt;&amp;gt; &amp;gt; - Credit balance. When Alice provides a routing node Bob with a Stake Certificate, Bob should increase Alice’s routing credit balance. Alice is then limited in her payments by this balance, and this rule is enforced by routing nodes to prevent free channel jamming in the network. Note that ideally “Alice’s credit balance“ should be virtual and only known to Alice, while routing nodes should only observe per-UTXO credit balance. We currently assume that each routing node keeps track of per-UTXO credit balance separately, see “Design decisions” for more details.&lt;br/&gt;&amp;gt; &amp;gt; - Stake-to-credit function defines how much credit balance is given per a Stake Certificate of a given value. This function is a policy of a routing node, and it should be announced.&lt;br/&gt;&amp;gt; &amp;gt; - Credit-to-value-transferred function defines how much value a sender can transfer along a given channel considering how much credit they might claim. The function may also consider different factors (e.g., the available capacity of a channel being used) to provide extra robustness.&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; ## Privacy-preserving Stake Certificates&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; The presented scheme could preserve privacy if it relied on zero-knowledge proofs of UTXO ownership by avoiding pointing to a particular UTXO.&lt;br/&gt;&amp;gt; &amp;gt; More specifically, the verifier should be able to check that:&lt;br/&gt;&amp;gt; &amp;gt; a) The staked UTXO is an element of the current UTXO set&lt;br/&gt;&amp;gt; &amp;gt; b) The prover knows the witness script committed by the UTXO witness program&lt;br/&gt;&amp;gt; &amp;gt; c) The prover knows a valid witness for the witness script&lt;br/&gt;&amp;gt; &amp;gt; d) The staked UTXO was not used to produce a different Stake Certificate which is currently in use as well.&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; The verifier should also have a way to see a Stake Certificate value to properly account for the credit. This can be achieved by restricting the UTXO set being proved upon to only those UTXOs with a specific range of values: “I will prove that I own a UTXO among all UTXOs between 0.5 BTC and 1 BTC”.&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; Unfortunately, steps (b) and (c) require zero-knowledge protocols for general statements, which are more experimental primitives than most of the stuff we have in Bitcoin protocols,&lt;br/&gt;&amp;gt; &amp;gt; although we assume it’s feasible to consider them for non-consensus stuff.&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; ## Evaluation&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; Stake Certificates, upfront payment schemes, and other potential solutions (given a particular configuration) may be compared along the following axis:&lt;br/&gt;&amp;gt; &amp;gt; 1) Economic feasibility&lt;br/&gt;&amp;gt; &amp;gt; 1a) What is the cost of overcoming the protection for an attacker? Likely a non-linear function: sats_spent =f(channels_to_jam, […])&lt;br/&gt;&amp;gt; &amp;gt; 1b) How does this solution limit honest users?&lt;br/&gt;&amp;gt; &amp;gt; 2) How sophisticated is this solution in terms of integration and making good UX?&lt;br/&gt;&amp;gt; &amp;gt; 3) How complex is this solution in terms of protocol design/implementation?&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; When it comes to (1a), both Stake Certificates and upfront payments are probably equal, in a way that they’re just best-effort ideas to increase the attack cost. Unfortunately, we currently don’t know how to design something as economically powerful as PoW in Bitcoin [3].&lt;br/&gt;&amp;gt; &amp;gt; This aspect can be properly evaluated by applying these ideas to different hypothetical kinds of LN in a simulation and observing the resulting trade-off between (1a) and (1b) considering different attack strategies.&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; In the previous sections of this post, we have argued that Stake Certificates may provide a much better (1b) for the cost of (3) because it relies on zero-knowledge.&lt;br/&gt;&amp;gt; &amp;gt; When it comes to (2), the design of Stake Certificates may vary in terms of UX burden, from completely automatic to requiring custom actions with private keys from users.&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; Some of these trade-offs along with other interesting questions are discussed in the following section.&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; ## Design decisions and questions&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; #### Should the credit spending be gossipped across the entire network, or should only the routing nodes involved in the payment know?&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; Economically, these two approaches are likely to be equivalent, and it’s just a matter of stake-to-credit ratio.&lt;br/&gt;&amp;gt; &amp;gt; However, announcing credit spending to the network results in a privacy leak. It also imposes bandwidth and CPU overhead on the routing nodes.&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; #### Which zero-knowledge system should be used for Stake Certificates?&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; Choosing a ZK system boils down to picking the right trade-offs of proving and verifying time, and assumptions. As we mentioned previously, we would need proving general statements.&lt;br/&gt;&amp;gt; &amp;gt; At the same time, we need something cheap in both proving and verification, because Lightning is supposed to be fast.&lt;br/&gt;&amp;gt; &amp;gt; At the same time, the setup probably doesn’t matter, because proofs are supposed to be verified only by one participant, a routing node this proof is generated for.&lt;br/&gt;&amp;gt; &amp;gt; Perhaps we can also pick any cryptographic assumptions we want since this stuff is not mission-critical and can be easily updated if someone breaks a cryptographic assumption and we observe an attack.&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; #### Should we allow holding *any* Bitcoins (not just LN channels) for Stake Certificates?&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; This idea might make sense if we’re worried that some LN users might want to send more payments than they can afford per their credit. However, we believe that allowing any UTXO would give an attacker more opportunities to use their cold funds for this attack, or even have a secondary market where holders sell their proofs (they have nothing to loose).&lt;br/&gt;&amp;gt; &amp;gt; Instead, we should a) design the credit-to-stake-functions better; b) encourage users send payments across different routing nodes (since credits are not tracked globally) [4].&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; #### What’s the best credit-to-value-transferred function?&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; We reckon that this function should be not just linear to provide maximum security against malicious channel jammers. For example, we can charge more credit for the last 20% of the capacity of the *channel used for routing*. Alternatively, we could discourage making too many payments from the same UTXO within a short period of time by charging more credit in this case.&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; #### What about the interactivity and lifetime of Stake Certificates?&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; Interactive proofs mean that they are constructed on demand of a routing node, non-interactive means constructed by a payment sender ahead of time.&lt;br/&gt;&amp;gt; &amp;gt; Both interactivity and lifetime have something to do with the ease of producing proof and accessing keys.&lt;br/&gt;&amp;gt; &amp;gt; We will omit the details of the trade-off we consider, but it remains an open question.&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; #### If Stake Certificates are valid for N blocks after proof generation, does it mean that if the UTXO is spent during those N blocks, new proof can be generated from the same coins without invalidating the old proof?&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; Yes, but an attacker would, first of all, have to pay an on-chain fee for this. If we’re still worried about this problem, there are workaround ideas.&lt;br/&gt;&amp;gt; &amp;gt; For example, we could have epochs of 100 blocks (every epoch starts at #XYZXYZ00 block). If at the start of an epoch, a channel wasn’t in the UTXO set, it provides very little credit.&lt;br/&gt;&amp;gt; &amp;gt; Alternatively, we could expand the zero-knowledge part to proving that the coins were not yet spent.&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; #### Should spending a UTXO reveal all Stake Certificates generated from it?&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; This would also solve the problem in the previous question, but it would mean a retrospective privacy leak again. To avoid a privacy leak, we should prevent this.&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; #### What if malicious Sybil *routing* nodes failing payments causing other honest routing nodes to reduce the credit of an honest payment sender?&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; Both Stake Certificates and upfront payment schemes suffer from malicious routing nodes failing the payments and “wasting” the sender’s credit or fees. This problem even applies out of the channel jamming context, when considering payment failure rate.&lt;br/&gt;&amp;gt; &amp;gt; This problem can be addressed by reducing the reputation of faulty links and routing nodes on the payment sender node. When payment routing becomes a for-profit activity, this would encourage routing nodes to sanitize their links.&lt;br/&gt;&amp;gt; &amp;gt; The mitigation can be even stronger by using “provable blaming” introduced in [2].&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; ## Conclusion&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; We propose Stake Certificates, a new solution to channel jamming. Perhaps, it might not be the best near-term solution due to the complexity, but the zero satoshi overhead for honest payments is an appealing argument to switch to it in the future.&lt;br/&gt;&amp;gt; &amp;gt; This proposal also illustrates how stake-based protocols can solve Sybil challenges in the Bitcoin ecosystem. Since this might be useful in other contexts (Sybil-resistance of many kinds, proof-of-ownership), discussing Stake Certificates is even more useful.&lt;br/&gt;&amp;gt; &amp;gt; The next step is a discussion of Stake Certificates. If the community finds it interesting, then we should discuss the design questions mentioned above, and choose a cryptosystem.&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; Cheers,&lt;br/&gt;&amp;gt; &amp;gt; Gleb Naumenko and Antoine Riard&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; ———&lt;br/&gt;&amp;gt; &amp;gt;&lt;br/&gt;&amp;gt; &amp;gt; References and footnotes:&lt;br/&gt;&amp;gt; &amp;gt; 1. &lt;a href=&#34;https://github.com/t-bast/lightning-docs/blob/master/spam-prevention.md&#34;&gt;https://github.com/t-bast/lightning-docs/blob/master/spam-prevention.md&lt;/a&gt;&lt;br/&gt;&amp;gt; &amp;gt; 2. &lt;a href=&#34;https://lists.linuxfoundation.org/pipermail/lightning-dev/2015-August/000135.html&#34;&gt;https://lists.linuxfoundation.org/pipermail/lightning-dev/2015-August/000135.html&lt;/a&gt;&lt;br/&gt;&amp;gt; &amp;gt; 3. We don’t actually suggest PoW to solve these issues, because a) the trade-off between honest user cost and attacker cost is misaligned due to specialized hardware and b) smartphones would die too fast if they have to compute PoW; PoW is just an unreachable example of system robustness due to well-aligned game theory.&lt;br/&gt;&amp;gt; &amp;gt; 4. Secondary markets are still possible even if we restrict acceptable proofs to only LN channels, but supply would be much smaller, and markets would work much worse for an attacker.&lt;br/&gt;&amp;gt;&lt;br/&gt;&amp;gt;&lt;br/&gt;-------------- next part --------------&lt;br/&gt;An HTML attachment was scrubbed...&lt;br/&gt;URL: &amp;lt;&lt;a href=&#34;http://lists.linuxfoundation.org/pipermail/lightning-dev/attachments/20201127/b8659b5f/attachment-0001.html&amp;gt&#34;&gt;http://lists.linuxfoundation.org/pipermail/lightning-dev/attachments/20201127/b8659b5f/attachment-0001.html&amp;gt&lt;/a&gt;;
    </content>
    <updated>2023-06-09T15:01:32&#43;02:00</updated>
  </entry>

  <entry>
    <id>https://nostr.ae/nevent1qqsz4ujx2n25xvcrr5u725srzcayhqexhnuepqq366l3rvxvzlcr4jszyp8a5sfs8ddgsmtk40slkzgxcvwducj9hkaw86j54rcstu002nlek99u4d0</id>
    
      <title type="html">📅 Original date posted:2020-11-26 📝 Original message: Hello ...</title>
    
    <link rel="alternate" href="https://nostr.ae/nevent1qqsz4ujx2n25xvcrr5u725srzcayhqexhnuepqq366l3rvxvzlcr4jszyp8a5sfs8ddgsmtk40slkzgxcvwducj9hkaw86j54rcstu002nlek99u4d0" />
    <content type="html">
      In reply to &lt;a href=&#39;/nevent1qqsy90p4dseguhvfzqzvpgeqn9ecc2nlx2mvmw6wxc7u9ks65h5fk5g4x6szz&#39;&gt;nevent1q…6szz&lt;/a&gt;&lt;br/&gt;_________________________&lt;br/&gt;&lt;br/&gt;📅 Original date posted:2020-11-26&lt;br/&gt;📝 Original message:&lt;br/&gt;Hello list,&lt;br/&gt;&lt;br/&gt;In this post, we explore a different approach to channel jamming mitigation.&lt;br/&gt;We won’t talk about the background here, for the problem description as well as some proposed solutions (mainly upfront payment schemes), see [1].&lt;br/&gt;&lt;br/&gt;We’re suggesting using UTXO ownership proofs (a.k.a. Stake Certificates) to solve this problem. Previously, these proofs were only used in the Lightning Network at channel announcement time to prevent malicious actors from announcing channels they don’t control. One can think of it as a “fidelity bond” (as a scarce resource) as a requirement for sending HTLCs.&lt;br/&gt;&lt;br/&gt;We start by overviewing issues with other solutions, and then present a naive, privacy-broken Stake Certificates. Then we examine designing a privacy-preserving version, evaluating them. At the end, we talk about non-trivial design decisions and open questions.&lt;br/&gt;&lt;br/&gt;## Issues with other proposals&lt;br/&gt;&lt;br/&gt;We find unsatisfying that upfront payment schemes come at a cost of new fees (forward and/or backward), thus inflating payment cost for *any* payment.&lt;br/&gt;In the future, the upfront base fee might even make “micropayments” economically infeasible by exceeding the value they transfer. Thus, a good solution should not inflate payment cost while still requiring “burning” a scarce resource (so that the attack is not free).&lt;br/&gt;&lt;br/&gt;Another issue with upfront payments is a circular trust dependency. Ideally, we shouldn’t introduce anything less trust-minimized than the Lightning Network itself.&lt;br/&gt;Upfront payment schemes are not like that, because they in one way or another rely on the honest behavior of route participants.&lt;br/&gt;&lt;br/&gt;We believe Stake Certificates we are going to introduce are satisfactory in both of these directions: they don’t inflate payment costs for honest users and don’t require trust. The main disadvantage of Stake Certificates seems to be the novel cryptography required.&lt;br/&gt;See more details in the “Evaluation” section.&lt;br/&gt;&lt;br/&gt;## Channel Ownership Proofs as Routing Credit Balance&lt;br/&gt;&lt;br/&gt;Let’s say Alice wants to relay an HTLC to Carol through Bob. Per the Stake Certificates scheme, she has to commit to a particular channel UTXO by embedding an ownership proof in the onion packet while sending an HTLC to Bob.&lt;br/&gt;&lt;br/&gt;Bob then unwraps the onion and verifies:&lt;br/&gt;1) the channel identifier is pointing unambiguously to an on-chain UTXO;&lt;br/&gt;2) the ownership proof (e.g., a signature) is valid against the previously disclosed UTXO witness script.&lt;br/&gt;&lt;br/&gt;If all those checks succeed, Bob should see if Alice hasn’t exceeded her credit balance. In case she hasn’t, Bob has to “decrement Alice’s credit balance” and relay the HTLC to Carol.&lt;br/&gt;Decrementing credit balance unconditionally of packet success or failure bounds liquidity abuse by malicious HTLC senders.&lt;br/&gt;Since there is no credit assigned initially, “decrementing the credit balance” means just remembering that “Alice spent X out of Y of the credit she received for her Stake Certificates”.&lt;br/&gt;&lt;br/&gt;Unfortunately, this naive protocol is a privacy nightmare, because routing nodes can now easily assign every HTLC they forward to the sender’s UTXO.&lt;br/&gt;&lt;br/&gt;Let’s first define the terms here one more time, and then proceed to the non-naive, private Stake Certificates.&lt;br/&gt;&lt;br/&gt;- Stake Certificate. Either means a solution we’re proposing or the primitive it is based on, namely proof of UTXO ownership. As we will argue later, it actually makes sense to use proof of LN channel UTXO ownership specifically rather than any funds ownership.&lt;br/&gt;- Stake Certificate value. An amount of the corresponding UTXO or a ballpark this amount provably  belongs to.&lt;br/&gt;- Credit balance. When Alice provides a routing node Bob with a Stake Certificate, Bob should increase Alice’s routing credit balance. Alice is then limited in her payments by this balance, and this rule is enforced by routing nodes to prevent free channel jamming in the network. Note that ideally “Alice’s credit balance“ should be virtual and only known to Alice, while routing nodes should only observe per-UTXO credit balance. We currently assume that each routing node keeps track of per-UTXO credit balance separately, see “Design decisions” for more details.&lt;br/&gt;- Stake-to-credit function defines how much credit balance is given per a Stake Certificate of a given value. This function is a policy of a routing node, and it should be announced.&lt;br/&gt;- Credit-to-value-transferred function defines how much value a sender can transfer along a given channel considering how much credit they might claim. The function may also consider different factors (e.g., the available capacity of a channel being used) to provide extra robustness.&lt;br/&gt;&lt;br/&gt;## Privacy-preserving Stake Certificates&lt;br/&gt;&lt;br/&gt;The presented scheme could preserve privacy if it relied on zero-knowledge proofs of UTXO ownership by avoiding pointing to a particular UTXO.&lt;br/&gt;More specifically, the verifier should be able to check that:&lt;br/&gt;a) The staked UTXO is an element of the current UTXO set&lt;br/&gt;b) The prover knows the witness script committed by the UTXO witness program&lt;br/&gt;c) The prover knows a valid witness for the witness script&lt;br/&gt;d) The staked UTXO was not used to produce a different Stake Certificate which is currently in use as well.&lt;br/&gt;&lt;br/&gt;The verifier should also have a way to see a Stake Certificate value to properly account for the credit. This can be achieved by restricting the UTXO set being proved upon to only those UTXOs with a specific range of values: “I will prove that I own a UTXO among all UTXOs between 0.5 BTC and 1 BTC”.&lt;br/&gt;&lt;br/&gt;Unfortunately, steps (b) and (c) require zero-knowledge protocols for general statements, which are more experimental primitives than most of the stuff we have in Bitcoin protocols,&lt;br/&gt;although we assume it’s feasible to consider them for non-consensus stuff.&lt;br/&gt;&lt;br/&gt;## Evaluation&lt;br/&gt;&lt;br/&gt;Stake Certificates, upfront payment schemes, and other potential solutions (given a particular configuration) may be compared along the following axis:&lt;br/&gt;1) Economic feasibility&lt;br/&gt;1a) What is the cost of overcoming the protection for an attacker? Likely a non-linear function: sats_spent =f(channels_to_jam, […])&lt;br/&gt;1b) How does this solution limit honest users?&lt;br/&gt;2) How sophisticated is this solution in terms of integration and making good UX?&lt;br/&gt;3) How complex is this solution in terms of protocol design/implementation?&lt;br/&gt;&lt;br/&gt;When it comes to (1a), both Stake Certificates and upfront payments are probably equal, in a way that they’re just best-effort ideas to increase the attack cost. Unfortunately, we currently don’t know how to design something as economically powerful as PoW in Bitcoin [3].&lt;br/&gt;This aspect can be properly evaluated by applying these ideas to different hypothetical kinds of LN in a simulation and observing the resulting trade-off between (1a) and (1b) considering different attack strategies.&lt;br/&gt;&lt;br/&gt;In the previous sections of this post, we have argued that Stake Certificates may provide a much better (1b) for the cost of (3) because it relies on zero-knowledge.&lt;br/&gt;When it comes to (2), the design of Stake Certificates may vary in terms of UX burden, from completely automatic to requiring custom actions with private keys from users.&lt;br/&gt;&lt;br/&gt;Some of these trade-offs along with other interesting questions are discussed in the following section.&lt;br/&gt;&lt;br/&gt;## Design decisions and questions&lt;br/&gt;&lt;br/&gt;#### Should the credit spending be gossipped across the entire network, or should only the routing nodes involved in the payment know?&lt;br/&gt;&lt;br/&gt;Economically, these two approaches are likely to be equivalent, and it’s just a matter of stake-to-credit ratio.&lt;br/&gt;However, announcing credit spending to the network results in a privacy leak. It also imposes bandwidth and CPU overhead on the routing nodes.&lt;br/&gt;&lt;br/&gt;#### Which zero-knowledge system should be used for Stake Certificates?&lt;br/&gt;&lt;br/&gt;Choosing a ZK system boils down to picking the right trade-offs of proving and verifying time, and assumptions. As we mentioned previously, we would need proving general statements.&lt;br/&gt;At the same time, we need something cheap in both proving and verification, because Lightning is supposed to be fast.&lt;br/&gt;At the same time, the setup probably doesn’t matter, because proofs are supposed to be verified only by one participant, a routing node this proof is generated for.&lt;br/&gt;Perhaps we can also pick any cryptographic assumptions we want since this stuff is not mission-critical and can be easily updated if someone breaks a cryptographic assumption and we observe an attack.&lt;br/&gt;&lt;br/&gt;#### Should we allow holding *any* Bitcoins (not just LN channels) for Stake Certificates?&lt;br/&gt;&lt;br/&gt;This idea might make sense if we’re worried that some LN users might want to send more payments than they can afford per their credit. However, we believe that allowing any UTXO would give an attacker more opportunities to use their cold funds for this attack, or even have a secondary market where holders sell their proofs (they have nothing to loose).&lt;br/&gt;Instead, we should a) design the credit-to-stake-functions better; b) encourage users send payments across different routing nodes (since credits are not tracked globally) [4].&lt;br/&gt;&lt;br/&gt;#### What’s the best credit-to-value-transferred function?&lt;br/&gt;&lt;br/&gt;We reckon that this function should be not just linear to provide maximum security against malicious channel jammers. For example, we can charge more credit for the last 20% of the capacity of the *channel used for routing*. Alternatively, we could discourage making too many payments from the same UTXO within a short period of time by charging more credit in this case.&lt;br/&gt;&lt;br/&gt;#### What about the interactivity and lifetime of Stake Certificates?&lt;br/&gt;&lt;br/&gt;Interactive proofs mean that they are constructed on demand of a routing node, non-interactive means constructed by a payment sender ahead of time.&lt;br/&gt;Both interactivity and lifetime have something to do with the ease of producing proof and accessing keys.&lt;br/&gt;We will omit the details of the trade-off we consider, but it remains an open question.&lt;br/&gt;&lt;br/&gt;#### If Stake Certificates are valid for N blocks after proof generation, does it mean that if the UTXO is spent during those N blocks, new proof can be generated from the same coins without invalidating the old proof?&lt;br/&gt;&lt;br/&gt;Yes, but an attacker would, first of all, have to pay an on-chain fee for this. If we’re still worried about this problem, there are workaround ideas.&lt;br/&gt;For example, we could have epochs of 100 blocks (every epoch starts at #XYZXYZ00 block). If at the start of an epoch, a channel wasn’t in the UTXO set, it provides very little credit.&lt;br/&gt;Alternatively, we could expand the zero-knowledge part to proving that the coins were not yet spent.&lt;br/&gt;&lt;br/&gt;#### Should spending a UTXO reveal all Stake Certificates generated from it?&lt;br/&gt;&lt;br/&gt;This would also solve the problem in the previous question, but it would mean a retrospective privacy leak again. To avoid a privacy leak, we should prevent this.&lt;br/&gt;&lt;br/&gt;#### What if malicious Sybil *routing* nodes failing payments causing other honest routing nodes to reduce the credit of an honest payment sender?&lt;br/&gt;&lt;br/&gt;Both Stake Certificates and upfront payment schemes suffer from malicious routing nodes failing the payments and “wasting” the sender’s credit or fees. This problem even applies out of the channel jamming context, when considering payment failure rate.&lt;br/&gt;This problem can be addressed by reducing the reputation of faulty links and routing nodes on the payment sender node. When payment routing becomes a for-profit activity, this would encourage routing nodes to sanitize their links.&lt;br/&gt;The mitigation can be even stronger by using “provable blaming” introduced in [2].&lt;br/&gt;&lt;br/&gt;## Conclusion&lt;br/&gt;&lt;br/&gt;We propose Stake Certificates, a new solution to channel jamming. Perhaps, it might not be the best near-term solution due to the complexity, but the zero satoshi overhead for honest payments is an appealing argument to switch to it in the future.&lt;br/&gt;This proposal also illustrates how stake-based protocols can solve Sybil challenges in the Bitcoin ecosystem. Since this might be useful in other contexts (Sybil-resistance of many kinds, proof-of-ownership), discussing Stake Certificates is even more useful.&lt;br/&gt;The next step is a discussion of Stake Certificates. If the community finds it interesting, then we should discuss the design questions mentioned above, and choose a cryptosystem.&lt;br/&gt;&lt;br/&gt;Cheers,&lt;br/&gt;Gleb Naumenko and Antoine Riard&lt;br/&gt;&lt;br/&gt;———&lt;br/&gt;&lt;br/&gt;References and footnotes:&lt;br/&gt;1. &lt;a href=&#34;https://github.com/t-bast/lightning-docs/blob/master/spam-prevention.md&#34;&gt;https://github.com/t-bast/lightning-docs/blob/master/spam-prevention.md&lt;/a&gt;&lt;br/&gt;2. &lt;a href=&#34;https://lists.linuxfoundation.org/pipermail/lightning-dev/2015-August/000135.html&#34;&gt;https://lists.linuxfoundation.org/pipermail/lightning-dev/2015-August/000135.html&lt;/a&gt;&lt;br/&gt;3. We don’t actually suggest PoW to solve these issues, because a) the trade-off between honest user cost and attacker cost is misaligned due to specialized hardware and b) smartphones would die too fast if they have to compute PoW; PoW is just an unreachable example of system robustness due to well-aligned game theory.&lt;br/&gt;4. Secondary markets are still possible even if we restrict acceptable proofs to only LN channels, but supply would be much smaller, and markets would work much worse for an attacker.&lt;br/&gt;-------------- next part --------------&lt;br/&gt;An HTML attachment was scrubbed...&lt;br/&gt;URL: &amp;lt;&lt;a href=&#34;http://lists.linuxfoundation.org/pipermail/lightning-dev/attachments/20201126/618274fa/attachment-0001.html&amp;gt&#34;&gt;http://lists.linuxfoundation.org/pipermail/lightning-dev/attachments/20201126/618274fa/attachment-0001.html&amp;gt&lt;/a&gt;;
    </content>
    <updated>2023-06-09T15:01:31&#43;02:00</updated>
  </entry>

  <entry>
    <id>https://nostr.ae/nevent1qqswz6rakzkqz6uz2fn29qm5rxlv4ks49yymmax633r2y04f80k7q8szyp8a5sfs8ddgsmtk40slkzgxcvwducj9hkaw86j54rcstu002nlek7pzjl8</id>
    
      <title type="html">📅 Original date posted:2020-02-26 📝 Original message: In ...</title>
    
    <link rel="alternate" href="https://nostr.ae/nevent1qqswz6rakzkqz6uz2fn29qm5rxlv4ks49yymmax633r2y04f80k7q8szyp8a5sfs8ddgsmtk40slkzgxcvwducj9hkaw86j54rcstu002nlek7pzjl8" />
    <content type="html">
      In reply to &lt;a href=&#39;/nevent1qqspm3efa0w2eggdkvtx8tsc3l2t7ex5k2e60mc8yu93f7a5kcrzx0c3vq65f&#39;&gt;nevent1q…q65f&lt;/a&gt;&lt;br/&gt;_________________________&lt;br/&gt;&lt;br/&gt;📅 Original date posted:2020-02-26&lt;br/&gt;📝 Original message:&lt;br/&gt;In this email, myself (gleb) and ariard want to discuss some aspects of the LN implementations when it comes to massive channel closing.&lt;br/&gt;&lt;br/&gt;LN security model relies on the unilateral capability to timely confirm on-chain commitment transaction. Currently, fee rates of both commitment transaction and HTLC-timeout/HTLC-Success are pre-committed at signatures and can be interactively updated with a `update_fee` message. In case of mempool fee rates surge and a counterparty being adversarial or irresponsive (by being offline by occasion or under attack), this mechanism isn’t reliable because a low-fee rate commitment transaction may never make it into network mempools. Switching to automatic single-party dynamic fee-bumping of *their* commitment transaction via CPFP/package relay would solve this issue, while potentially opening new attack vectors.&lt;br/&gt;&lt;br/&gt;If dynamic fee-bumping is used by a significant fraction of LN nodes, this security measure may be exploited by a miner, a massive LN channels closing would choke the mempool, dynamic fee-bumpers would react in consequence and fee rates raise to the roof. Miners would harvest abnormal high-fees for multiple blocks.&lt;br/&gt;&lt;br/&gt;A massive channel closing may be provoked by feeding an invalid block to light clients (in the BIP157 paradigm), as they don’t have utxo access, they can’t verify input signatures (note: the only utxo spend they can check is the funding_output and they should do so) and lead to think than their channel is closed. This may provoke a spurious broadcast of their local commitment transaction, this one being valid and propagating on the base layer. Even if an invalid block isn’t fetched, the secure strategy on what to do when your chain view is messed up by an attacker is still an open question. Note that one invalid block may be used to force-close multiple channels, making this attack more economically feasible.&lt;br/&gt;&lt;br/&gt;Another attack building block could be to exploit any LN protocol/implementation vulnerability like a malicious HTLC-of-death which would provoke honest parties to close their mutual channel when routed through [0]&lt;br/&gt;&lt;br/&gt;LN light clients should disable HTLC routing and avoid any aggressive fee-bumping for a broadcast of local commitment transactions as time-sensitivity doesn’t matter in this case beyond UX and funds stuck in-flight.&lt;br/&gt;&lt;br/&gt;Bounding dynamic-fees engine may be viewed as a game-theoretic aspect between LN parties (burn the maximum in fee rate to avoid an attacker to make any profit) and macro-considerations (prevent miner to exploit the whole LN network, conservative mempool/resources usage).&lt;br/&gt;&lt;br/&gt;Considering that most of the block reward is currently subsidized, the incentives for miners to launch this attack are questionable. However, this might change when the fraction of fees in the reward becomes higher.&lt;br/&gt;As LN becomes an important part of the Bitcoin ecosystem, it’s important to acknowledge the mining-related incentives and risks, as these may at the end be used to influence protocol development.&lt;br/&gt;&lt;br/&gt;Since the LN infrastructure seems to be moving towards the heavy use of light clients, and the attacks we mentioned are expected to appear again (at least in some of the implementations), we believe it’s important to understand the mechanics of these attacks and countermeasures.&lt;br/&gt;&lt;br/&gt;It would be interesting to have an empirical study (based on the historical data) and a simulation of the fee spikes, with parameterized:&lt;br/&gt;- how many channels are vulnerable to force-closing (based on the particular LN implementations)&lt;br/&gt;- what are the properties of those channels (amount, timelocks)&lt;br/&gt;- what is the distribution of those channels across nodes&lt;br/&gt;- how many nodes implement dynamic bumping&lt;br/&gt;- mining reward allocation&lt;br/&gt;&lt;br/&gt;What are your opinions on these issues?&lt;br/&gt;&lt;br/&gt;– gleb&lt;br/&gt;&lt;br/&gt;&lt;br/&gt;[0] One example with this RL issue:&lt;br/&gt;(&lt;a href=&#34;https://github.com/rust-bitcoin/rust-lightning/pull/513&#34;&gt;https://github.com/rust-bitcoin/rust-lightning/pull/513&lt;/a&gt;)&lt;br/&gt;-------------- next part --------------&lt;br/&gt;An HTML attachment was scrubbed...&lt;br/&gt;URL: &amp;lt;&lt;a href=&#34;http://lists.linuxfoundation.org/pipermail/lightning-dev/attachments/20200226/d529ce9f/attachment-0001.html&amp;gt&#34;&gt;http://lists.linuxfoundation.org/pipermail/lightning-dev/attachments/20200226/d529ce9f/attachment-0001.html&amp;gt&lt;/a&gt;;
    </content>
    <updated>2023-06-09T14:59:06&#43;02:00</updated>
  </entry>

  <entry>
    <id>https://nostr.ae/nevent1qqspv7crezzcfztlg9gv6dd238l7ff7we29yg2v88qzla9l2wnsnxegzyp8a5sfs8ddgsmtk40slkzgxcvwducj9hkaw86j54rcstu002nlek8hn53f</id>
    
      <title type="html">📅 Original date posted:2023-02-02 🗒️ Summary of this ...</title>
    
    <link rel="alternate" href="https://nostr.ae/nevent1qqspv7crezzcfztlg9gv6dd238l7ff7we29yg2v88qzla9l2wnsnxegzyp8a5sfs8ddgsmtk40slkzgxcvwducj9hkaw86j54rcstu002nlek8hn53f" />
    <content type="html">
      In reply to &lt;a href=&#39;/nevent1qqsq2su6qdphnz9fhx5q8h60kyy72fvl7sqfjhd5uv87qygjp2d9x2grvmvw2&#39;&gt;nevent1q…mvw2&lt;/a&gt;&lt;br/&gt;_________________________&lt;br/&gt;&lt;br/&gt;📅 Original date posted:2023-02-02&lt;br/&gt;🗒️ Summary of this message: This post discusses the game-theoretic security of time-sensitive protocols if miners are open to censorship for a reward, and outlines the requirements for such behavior to become practical. It also presents simple opcode-based and nLockTime-based constructions for two-party contracts.&lt;br/&gt;📝 Original message:## Intro&lt;br/&gt;&lt;br/&gt;Most of it feels like implicit knowledge, but I couldn&amp;#39;t find anything written so here it is. The ideas towards anchor outputs and the conclusions probably have some new perspectives.&lt;br/&gt;&lt;br/&gt;This post is about the game-theoretic security of time-sensitive protocols if miners are open to censorship for a reward. To become practical, the following has to happen.&lt;br/&gt;&lt;br/&gt;1) a substantial hashrate has to be willing to participate in this behaviour, according to the known formula from the Whitepaper. The more blocks it takes to attack (defined by a particular protocol configuration and could be tuned), the exponentially higher % hashrate is required.&lt;br/&gt;&lt;br/&gt;2) a communication layer is required to send bribes to these miners. This could be a private transaction relay network, or a mempool allowing still-time-locked transactions. It could be even an announcement board (e.g., submitting raw txs under a Twitter hashtag and inviting miners to monitor it).&lt;br/&gt;&lt;br/&gt;3) a bribe transaction construction (will be explained later).&lt;br/&gt;&lt;br/&gt;In this post, I talk about the case when:&lt;br/&gt;1. a significant hashrate (e.g., 95%&#43;) is open to take these bribes;&lt;br/&gt;2. but miners don&amp;#39;t trust each other;&lt;br/&gt;3. and there is no reorgs.&lt;br/&gt;&lt;br/&gt;Assumption \*(2) is more nuanced. What I mean here is roughly &amp;#34;miner X would rather take an immediate gain than commit to a lenghty scenario where many miners coordinate to take reward on behalf of each other and then distribute it accordingly to the hashrate&amp;#34;. The game theory of this assumption should be better defined in the future.&lt;br/&gt;&lt;br/&gt;We will see, how widely known tweaks lift the bar for (2) and (3) and how this could be further improved.&lt;br/&gt;&lt;br/&gt;*A special case of this scenario is miners withholding Alice&amp;#39;s transaction to force her to bump fees, even if Bob hasn&amp;#39;t submitted a bribe. Here I assume miners won&amp;#39;t do it unless there is an external incentive (Bob&amp;#39;s bribe), although this issue is also interesting.*&lt;br/&gt;&lt;br/&gt;## Simple opcode-based construction&lt;br/&gt;&lt;br/&gt;The simplest time-sensitive two-party contract is PowSwap (a bet on the future block issuance rate), a single on-chain UTXO with the following spending conditions:&lt;br/&gt;- Alice’s key can spend if height=H is reached;&lt;br/&gt;- Bob’s key can spend if Time=T is reached.&lt;br/&gt;&lt;br/&gt;Say H is approaching quickly, and T is far behind. Bob now uses a private mining relay to submit his non-mineable transaction paying e.g. half of the UTXO value towards fees.&lt;br/&gt;&lt;br/&gt;Alice has two problems: 1) she can’t figure out why her transaction isn’t mined and how much fee to overpay; 2) the attack is free for Bob (he has nothing to lose), while Alice loses everything up to the full UTXO value.&lt;br/&gt;&lt;br/&gt;## Simple nLockTime-based construction&lt;br/&gt;&lt;br/&gt;If parties use pre-signed transactions with nLockTime (instead of the opcodes), Bob’s fee can be pre-signed to a rather low value, so that Alice can reasonably overbid it without much loss (she probably doesn&amp;#39;t even need to take any action).&lt;br/&gt;&lt;br/&gt;Bob can, however, bump the fee by creating a CPFP transaction with super-high fee. All it requires now is submitting twice as much data to the private mining relay (and burning slightly more in fees).&lt;br/&gt;&lt;br/&gt;## nLockTime-based construction with OP_CSV output&lt;br/&gt;&lt;br/&gt;If Bob’s output can’t be spent right away, but is forced to be deterred to even one block in the future, it makes taking this bribe not rational: a censoring miner can’t be sure about the deferred reward (remember, miners don&amp;#39;t trust each other). At the same time, mining the honest transaction and taking its fee is always available earlier.&lt;br/&gt;&lt;br/&gt;Smart contracts could possibly make it rational for miners (see [1]), e.g. by allowing Bob to allocate the bribe based on the historic hashrate distribution linked to coinbase pubkeys.&lt;br/&gt;&lt;br/&gt;At the same time, this approach makes dynamic fee management impossible.&lt;br/&gt;&lt;br/&gt;## Anchor outputs&lt;br/&gt;&lt;br/&gt;Anchor outputs allow bringing external capital for fee management while locking internal capital. Bob can use this capital for a bribe. If the attack fails, Bob&amp;#39;s external capital remains safe, so this is not so bad for Bob.&lt;br/&gt;&lt;br/&gt;The attack can be more costly if this external capital was claimable:&lt;br/&gt;- by Alice: e.g., Alice can steal a (covenanted) anchor output if it&amp;#39;s revealed before Bob&amp;#39;s nLockTime makes it mineable (requires her to monitor the private relay);&lt;br/&gt;- or by miners, e.g. if Alice forces Bob, at contract setup, to use a reverse time-lock (the anchor can be stolen by miner if seen before time=T); or if mining Alice&amp;#39;s honest transaction also allows miners to take Bob&amp;#39;s fee output (e.g., Alice&amp;#39;s honest transaction *could* act as a parent/preimage, conditionally, although this may require reverse time-locking Alice to protect Bob...)&lt;br/&gt;&lt;br/&gt;*Ephemeral anchors doesn’t do much w.r.t. our trade-off, as it is a mempool-oriented thing.*&lt;br/&gt;&lt;br/&gt;## Lightning&lt;br/&gt;&lt;br/&gt;Lightning is different from the described protocol in two things:&lt;br/&gt;1) It relies on intermediate transactions (e.g., Commitment in Poon-Dryja);&lt;br/&gt;2) Usually both parties have some balance in the channel.&lt;br/&gt;&lt;br/&gt;I believe that (1) doesn’t change the situation much, it just makes it more nuanced.&lt;br/&gt;(2) is irrelevant because an attacker can just spend the entire channel before the attack.&lt;br/&gt;Thus, most of these concerns apply to lightning equally.&lt;br/&gt;&lt;br/&gt;## Related work&lt;br/&gt;&lt;br/&gt;The LN paper briefly mentioned this problem, although it was claimed impractical due to a high degree of required collusion. We already see private mining relay in mevwatch.info (ethereum), and we had FIBRE (I think it was neutral).&lt;br/&gt;&lt;br/&gt;[2] discussed constructions and economics for bribing miners. [1] suggests more practical considerations for achieving this. Both don’t focus on the risks of particular time-sensitive protocol constructions.&lt;br/&gt;&lt;br/&gt;[3] highlighted a similar protocol risk, but the proposed solution seems to work only if an attacker has funds to lose locked in the contract (e.g., collateral, lightning balance, powswap payout).&lt;br/&gt;&lt;br/&gt;## Conclusions&lt;br/&gt;&lt;br/&gt;To increase the attack bar w.r.t the configuration described in the intro, we should either:&lt;br/&gt;- stick to the *nLockTime-based construction with OP_CSV output*, forget about dynamic fee management, and hope that bribe allocation smart contracts doesn&amp;#39;t work out;&lt;br/&gt;- use anchor outputs (or another external fee scheme), but enforce a way to steal/burn the external fee if it&amp;#39;s an attack;&lt;br/&gt;- design new fee/channel constructions.&lt;br/&gt;&lt;br/&gt;These ideas may also be helpful for alternative payment channels designs as well (v3&#43;ephemeral anchors, SIGHASH_GROUP, etc.), or in the future to protect against more powerful covenants allowing stronger bribes (see [1]).&lt;br/&gt;&lt;br/&gt;Thanks to Antoine Riard and Greg Sanders for initial discussion.&lt;br/&gt;&lt;br/&gt;-------------------------&lt;br/&gt;&lt;br/&gt;## References&lt;br/&gt;&lt;br/&gt;1. TxWithhold Smart Contracts by Gleb Naumenko | BitMEX Blog (&lt;a href=&#34;https://blog.bitmex.com/txwithhold-smart-contracts/&#34;&gt;https://blog.bitmex.com/txwithhold-smart-contracts/&lt;/a&gt;)&lt;br/&gt;2. Temporary Censorship Attacks in the Presence of Rational Miners (&lt;a href=&#34;https://eprint.iacr.org/2019/748.pdf&#34;&gt;https://eprint.iacr.org/2019/748.pdf&lt;/a&gt;)&lt;br/&gt;3. MAD-HTLC: Because HTLC is Crazy-Cheap to Attack (&lt;a href=&#34;https://arxiv.org/pdf/2006.12031.pdf&#34;&gt;https://arxiv.org/pdf/2006.12031.pdf&lt;/a&gt;)&lt;br/&gt;-------------- next part --------------&lt;br/&gt;An HTML attachment was scrubbed...&lt;br/&gt;URL: &amp;lt;&lt;a href=&#34;http://lists.linuxfoundation.org/pipermail/bitcoin-dev/attachments/20230202/275a0387/attachment.html&amp;gt&#34;&gt;http://lists.linuxfoundation.org/pipermail/bitcoin-dev/attachments/20230202/275a0387/attachment.html&amp;gt&lt;/a&gt;;
    </content>
    <updated>2023-06-08T01:19:06&#43;02:00</updated>
  </entry>

  <entry>
    <id>https://nostr.ae/nevent1qqs0qrk8aqjuelu6035ktyc2ds5fwwpgprqpk9tm3lkp9593mvvcftczyp8a5sfs8ddgsmtk40slkzgxcvwducj9hkaw86j54rcstu002nleke87phn</id>
    
      <title type="html">📅 Original date posted:2019-09-25 📝 Original message:We are ...</title>
    
    <link rel="alternate" href="https://nostr.ae/nevent1qqs0qrk8aqjuelu6035ktyc2ds5fwwpgprqpk9tm3lkp9593mvvcftczyp8a5sfs8ddgsmtk40slkzgxcvwducj9hkaw86j54rcstu002nleke87phn" />
    <content type="html">
      In reply to &lt;a href=&#39;/nevent1qqsve4ccs5hjssg3gjr7f2nm3cyq32vs0k7wwkxjuh0phttuxll50cst3t4hx&#39;&gt;nevent1q…t4hx&lt;/a&gt;&lt;br/&gt;_________________________&lt;br/&gt;&lt;br/&gt;📅 Original date posted:2019-09-25&lt;br/&gt;📝 Original message:We are opening for review a draft of the new BIP, which describes low-level specifications for the reconciliation-based transaction announcement protocol.&lt;br/&gt;&lt;a href=&#34;https://github.com/naumenkogs/bips/blob/bip-reconcil/bip-reconcil.mediawiki&#34;&gt;https://github.com/naumenkogs/bips/blob/bip-reconcil/bip-reconcil.mediawiki&lt;/a&gt;&lt;br/&gt;&lt;br/&gt;Agreeing on this spec would enable integration of more bandwidth-efficient relay protocols, like Erlay (&lt;a href=&#34;https://arxiv.org/abs/1905.10518&#34;&gt;https://arxiv.org/abs/1905.10518&lt;/a&gt;).&lt;br/&gt;&lt;br/&gt;The draft has all the background necessary to understand the work, so please read and review.&lt;br/&gt;It introduces salted short transaction IDs (required to do reconciliation efficiently) and demonstrates how to compute sketches based on these IDs (including simple python scripts).&lt;br/&gt;It also introduces wtxid-based truncated transaction IDs (to trivially save significant fraction of the bandwidth).&lt;br/&gt;Finally, it specifies all the messages to be used by an efficient reconciliation-based protocol, and new state variables required for the protocol.&lt;br/&gt;&lt;br/&gt;Please note that, comparing to the Erlay paper, we decided to add extra round, where 2 parties explicitly map 32-bit short IDs to 128-bit truncated IDs, because otherwise peers which take &amp;gt;1s to reconcile would cause transmitting duplicate transactions (extra bandwidth), and we cannot assume &amp;lt;1s latency in Bitcoin, especially over Tor.&lt;br/&gt;According to my estimates, the bandwidth overhead due to the measure from the BIP (extra communication round) is only extra 10% comparing to the original Erlay estimates.&lt;br/&gt;&lt;br/&gt;It is possible that we missed some of the state variables required to handle corner cases of the protocol, because the spec is based on my prototype code, and it might evolve when we will be building an actual production-ready implementation.&lt;br/&gt;&lt;br/&gt;Overall, I believe that this spec is ready for review.&lt;br/&gt;&lt;br/&gt;Even though this work does not require a fork, the change is quite significant, and peer-review is critical for the system, so please take a look. Feel free to reach out for questions and comments here or directly over email.&lt;br/&gt;&lt;br/&gt;– gleb&lt;br/&gt;-------------- next part --------------&lt;br/&gt;An HTML attachment was scrubbed...&lt;br/&gt;URL: &amp;lt;&lt;a href=&#34;http://lists.linuxfoundation.org/pipermail/bitcoin-dev/attachments/20190925/90bfdb64/attachment.html&amp;gt&#34;&gt;http://lists.linuxfoundation.org/pipermail/bitcoin-dev/attachments/20190925/90bfdb64/attachment.html&amp;gt&lt;/a&gt;;
    </content>
    <updated>2023-06-07T20:20:42&#43;02:00</updated>
  </entry>

  <entry>
    <id>https://nostr.ae/nevent1qqsvd757jjer8e80jd5xfwqhfrrn0z37nylxddwwyw7ezps5syyyhjgzyp8a5sfs8ddgsmtk40slkzgxcvwducj9hkaw86j54rcstu002nlek28jds0</id>
    
      <title type="html">📅 Original date posted:2018-04-02 📝 Original message:Hi ...</title>
    
    <link rel="alternate" href="https://nostr.ae/nevent1qqsvd757jjer8e80jd5xfwqhfrrn0z37nylxddwwyw7ezps5syyyhjgzyp8a5sfs8ddgsmtk40slkzgxcvwducj9hkaw86j54rcstu002nlek28jds0" />
    <content type="html">
      In reply to &lt;a href=&#39;/nevent1qqsfwtlgzyh3qtklspufzycz8dqfefn8jtk9j97s40hrgms9dzm3e3qfeazme&#39;&gt;nevent1q…azme&lt;/a&gt;&lt;br/&gt;_________________________&lt;br/&gt;&lt;br/&gt;📅 Original date posted:2018-04-02&lt;br/&gt;📝 Original message:Hi all,&lt;br/&gt;I have a couple of ideas regarding transaction relay protocol and wanted to share it with and probably get some feedback.&lt;br/&gt;&lt;br/&gt;I did some emulation and simulation and found out that around 90% of INV messages sent by public-IP nodes are idle (duplicate), obviously because each node creates 8 connections.  I also realized that sending INV messages is a significant part of the overall bandwidth consumed by a public-IP node. At a larger scale, this will result in people not able to run a public-IP node.&lt;br/&gt;&lt;br/&gt;My idea is in some sense similar to BIP37 but applied to public-IP nodes. Here I want to emphasize that all the nodes will still receive *all* of the transactions. A new protocol should also keep the same zero-trust, robustness, decentralization guarantees and latency.&lt;br/&gt;&lt;br/&gt;Idea: while joining the network, a new node agrees on some filter with each of 8 nodes it connects to. So that NewNode &amp;lt;-&amp;gt; Node_A will be used to relay only a subset of transactions, NewNode &amp;lt;-&amp;gt; Node_B for another subset. This will significantly decrease the redundancy.&lt;br/&gt;&lt;br/&gt;To keep the guarantees, I would keep some redundancy (for example, each transaction INV is sent over 2 links).&lt;br/&gt;&lt;br/&gt;To make it robust to attacks, I have 2 extensions in my mind:&lt;br/&gt;1. Set reconciliation (for a subset of transactions) with *other* nodes. Getting a bloom filter of a subset of the mempool transactions from Node_B may help to figure out whether Node_A is malicious, very slow, etc.&lt;br/&gt;2. Rotating the filters every N minutes (N &amp;lt; 10)&lt;br/&gt;&lt;br/&gt;I can see some issues with latency here, but I believe this problem has a solution.&lt;br/&gt;&lt;br/&gt;Feedback is appreciated!&lt;br/&gt;&lt;br/&gt;If you want to look at a draft of the proposal — please let me know.&lt;br/&gt;If there were any similar ideas — please let me know.&lt;br/&gt;&lt;br/&gt;Best,&lt;br/&gt;Gleb&lt;br/&gt;&lt;br/&gt;-------------- next part --------------&lt;br/&gt;An HTML attachment was scrubbed...&lt;br/&gt;URL: &amp;lt;&lt;a href=&#34;http://lists.linuxfoundation.org/pipermail/bitcoin-dev/attachments/20180402/a990f1dc/attachment.html&amp;gt&#34;&gt;http://lists.linuxfoundation.org/pipermail/bitcoin-dev/attachments/20180402/a990f1dc/attachment.html&amp;gt&lt;/a&gt;;
    </content>
    <updated>2023-06-07T20:11:27&#43;02:00</updated>
  </entry>

</feed>