{"id":25485,"date":"2016-02-01T16:19:16","date_gmt":"2016-02-01T16:19:16","guid":{"rendered":"http:\/\/ci027cfe7b000f2697"},"modified":"2016-02-01T16:19:16","modified_gmt":"2016-02-01T16:19:16","slug":"bitcoin-core-developer-jonas-schnelli-explains-controversial-transaction-replace-by-fee-feature-1454343556","status":"publish","type":"post","link":"https:\/\/bitcoinmagazine.com\/technical\/bitcoin-core-developer-jonas-schnelli-explains-controversial-transaction-replace-by-fee-feature-1454343556","title":{"rendered":"Bitcoin Core Developer Jonas Schnelli Explains Controversial Transaction Replace-by-Fee Feature"},"content":{"rendered":"<div id=\"bsf_rt_marker\"><\/div><figure><img decoding=\"async\" src=\"https:\/\/bitcoinmagazine.com\/wp-content\/uploads\/2024\/11\/bitcoin-core-developer-jonas-schnelli-explains-controversial-transaction-replace-by-fee-feature.jpg\" title=\"\"><\/figure>\n<p>Although the <a href=\"https:\/\/en.bitcoin.it\/wiki\/Block_size_limit_controversy\" target=\"_blank\" rel=\"noopener\">block size debate<\/a> has been the main point of conflict within the Bitcoin community over the past year, the reality is that this conversation is more about the larger topic of <a href=\"https:\/\/en.bitcoin.it\/wiki\/Scalability\" target=\"_blank\" rel=\"noopener\">scalability<\/a>. Different Bitcoin users would like to see the network scale via specific methods, and the two main parties in this debate are now <a href=\"https:\/\/bitcoin.org\/en\/download\" target=\"_blank\" rel=\"noopener\">Bitcoin Core<\/a> and <a href=\"https:\/\/bitcoinclassic.com\/\" target=\"_blank\" rel=\"noopener\">Bitcoin Classic<\/a>. <\/p>\n<p>Along with the block size limit, the <a href=\"https:\/\/coinjournal.net\/a-simple-explanation-of-the-lightning-network\/\" target=\"_blank\" rel=\"noopener\">Lightning Network<\/a>, and <a href=\"https:\/\/bitcoinmagazine.com\/articles\/segregated-witness-part-how-a-clever-hack-could-significantly-increase-bitcoin-s-potential-1450553618\">Segregated Witness<\/a>, another Bitcoin feature that has been covered in controversy is <a href=\"https:\/\/www.reddit.com\/r\/Bitcoin\/comments\/3uphgv\/eli5_what_is_rbfreplacebyfee\/\" target=\"_blank\" rel=\"noopener\">Replace-by-Fee<\/a> (RBF). Bitcoin Core Contributor <a href=\"https:\/\/twitter.com\/_jonasschnelli_\" target=\"_blank\" rel=\"noopener\">Jonas Schnelli<\/a> recently discussed this new feature, which has been implemented in Bitcoin Core 0.12, during a <a href=\"https:\/\/www.youtube.com\/watch?v=RWeIEFBrItE\" target=\"_blank\" rel=\"noopener\">presentation<\/a> at a <a href=\"https:\/\/www.meetup.com\/Bitcoin-Meetup-Switzerland\/events\/226728648\/\" target=\"_blank\" rel=\"noopener\">Bitcoin Meetup Switzerland<\/a>. <\/p>\n<p><strong>Satoshi Originally Implemented Full RBF<\/strong><\/p>\n<p>Schnelli started his talk by pointing out that Bitcoin creator <a href=\"https:\/\/en.wikipedia.org\/wiki\/Satoshi_Nakamoto\" target=\"_blank\" rel=\"noopener\">Satoshi Nakamoto<\/a> originally implemented RBF. <\/p>\n<p>Although transaction replacement was disabled by Nakamoto in 2010, the <a href=\"https:\/\/github.com\/bitcoin\/bitcoin\/commit\/05454818dc7ed92f577a1a1ef6798049f17a52e7#diff-118fcbaaba162ba17933c7893247df3aR522\" target=\"_blank\" rel=\"noopener\">commit<\/a> disabling the feature came with the comment that it was only being turned off \u201cfor now.\u201d The comment next to the code related to transaction replacement in Nakamoto\u2019s original code <a href=\"https:\/\/github.com\/trottier\/original-bitcoin\/blob\/master\/src\/main.cpp#L434\" target=\"_blank\" rel=\"noopener\">reads<\/a>, \u201cAllow replacing with a newer version of the same transaction.\u201d<\/p>\n<p>Schnelli described how transaction replacement once worked on the Bitcoin network:<\/p>\n<p>\u201cIt was always possible \u2013 or back then it was possible \u2013 that if you did a transaction, until that transaction ended up in a <a href=\"https:\/\/en.bitcoin.it\/wiki\/Block\" target=\"_blank\" rel=\"noopener\">block<\/a>, you could change the transaction fully by just doing something different.\u201d<\/p>\n<p><strong>RBF Helps Avoid Transaction Delays<\/strong><\/p>\n<p>There are advantages to being able to replace a Bitcoin transaction with a new, updated one. For example, if a user has included a transaction fee that is too low, the ability to replace the transaction with another one containing a higher fee allows users to make sure their transactions do not get stuck with a status of \u201cunconfirmed\u201d for long periods of time. Users are also able to correct errors made when creating a transaction via RBF.<\/p>\n<p>Jonas Schnelli noted that this functionality makes sense to him:<\/p>\n<p>\u201cThis makes sense, in my opinion. If I do a payment and I find out, \u2018Oh, no \u2013 wrong amount,\u2019 or, \u2018Oh, no. The fees are wrong,\u2019 I can change it.\u201d<\/p>\n<p><strong>0-Confirmation Doesn\u2019t Work with RBF<\/strong><\/p>\n<p>The controversial aspect of RBF is that it does not work well with <a href=\"https:\/\/www.blockchain.com\/wallet\/bitcoin-faq\" target=\"_blank\" rel=\"noopener\">0-confirmation transactions<\/a>. When users are able to replace transactions before they are placed into a block, that essentially makes unconfirmed transactions much riskier. Many merchants and payment processors rely on unconfirmed transactions for real-world commerce.<\/p>\n<p>Schnelli described this issue during his talk:<\/p>\n<p>\u201c0-confirmation by Satoshi\u2019s whitepaper was always insecure, but because people have built systems on it, we have to make sure that it\u2019s stable, that people can buy stuff instantly. I mean, you can\u2019t wait ten minutes when you pay for a coffee; I agree.\u201d<\/p>\n<p>On the issue of the security of 0-confirmation transactions, Bitcoin Core contributor Peter Todd recently wrote a <a href=\"https:\/\/petertodd.org\/2016\/are-wallets-ready-for-rbf\" target=\"_blank\" rel=\"noopener\">blog post<\/a> where he outlined the current inability of bitcoin wallets to properly protect users against <a href=\"https:\/\/en.bitcoin.it\/wiki\/Double-spending\" target=\"_blank\" rel=\"noopener\">double spends<\/a>. <\/p>\n<p><strong>Merchants Shouldn\u2019t Be Afraid of RBF<\/strong><\/p>\n<p>Even with the security concerns <a href=\"https:\/\/www.coingecko.com\/buzz\/peter-todd-explains-the-problems-with-unconfirmed-bitcoin-transactions\" target=\"_blank\" rel=\"noopener\">often pointed out by Todd<\/a> and others, it should be noted that the current version of RBF is opt-in.<\/p>\n<p>Jonas Schnelli explained the optional nature of RBF during his talk at Bitcoin Meetup Switzerland:<\/p>\n<p>\u201cWhen you create a transaction, you can decide, \u2018Should I be able to replace a transaction or not?\u2019 If you just create transactions as you did in the past, it\u2019s not replaceable. Nothing is broken; everything works as it was before. But now we can opt in \u2013 set the flag on that transaction \u2013 and then it gives you the chance to replace a transaction until it\u2019s mined.\u201d<\/p>\n<p>In other words, merchants should not be vulnerable to an RBF-powered double spend because RBF transactions can be differentiated from traditional Bitcoin transactions.<\/p>\n<p>As Schnelli explained during his presentation:<\/p>\n<p>\u201cMerchants can reject RBF transactions \u2026 If somebody pays you with a replace-by-fee transaction, you don\u2019t want to accept it if it\u2019s a 0-confirmation [transaction].\u201d<\/p>\n<p><em>Kyle Torpey is a freelance journalist who has been following Bitcoin since 2011. His work has been featured on VICE Motherboard, Business Insider, RT\u2019s Keiser Report and many other media outlets. You can follow <a href=\"https:\/\/twitter.com\/kyletorpey\" target=\"_blank\" rel=\"noopener\">@kyletorpey<\/a> on Twitter.<\/em><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Although the block size debate has been the main point of conflict within the Bitcoin community over the past year, the reality is that this conversation is more about the larger topic of scalability. Different Bitcoin users would like to see the network scale via specific methods, and the two main parties in this debate [&hellip;]<\/p>\n","protected":false},"author":3445,"featured_media":25486,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[35],"tags":[3572,1038,3246,551,2374,881,705,297,708],"class_list":{"0":"post-25485","1":"post","2":"type-post","3":"status-publish","4":"format-standard","5":"has-post-thumbnail","7":"category-technical","8":"tag-bitcoin-classic","9":"tag-core","10":"tag-jonas-schnelli","11":"tag-merchants","12":"tag-peter-todd","13":"tag-rbf","14":"tag-scaling","15":"tag-switzerland","16":"tag-transactions"},"author_data":{"id":3445,"name":"Kyle Torpey","nicename":"kyle-torpey","avatar_url":"https:\/\/bitcoinmagazine.com\/wp-content\/uploads\/2024\/12\/kyle-torpey-promo-image-96x96.jpg"},"featured_image_url":"https:\/\/bitcoinmagazine.com\/wp-content\/uploads\/2024\/11\/bitcoin-core-developer-jonas-schnelli-explains-controversial-transaction-replace-by-fee-feature.jpg","_links":{"self":[{"href":"https:\/\/bitcoinmagazine.com\/wp-json\/wp\/v2\/posts\/25485","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/bitcoinmagazine.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/bitcoinmagazine.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/bitcoinmagazine.com\/wp-json\/wp\/v2\/users\/3445"}],"replies":[{"embeddable":true,"href":"https:\/\/bitcoinmagazine.com\/wp-json\/wp\/v2\/comments?post=25485"}],"version-history":[{"count":0,"href":"https:\/\/bitcoinmagazine.com\/wp-json\/wp\/v2\/posts\/25485\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/bitcoinmagazine.com\/wp-json\/wp\/v2\/media\/25486"}],"wp:attachment":[{"href":"https:\/\/bitcoinmagazine.com\/wp-json\/wp\/v2\/media?parent=25485"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/bitcoinmagazine.com\/wp-json\/wp\/v2\/categories?post=25485"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/bitcoinmagazine.com\/wp-json\/wp\/v2\/tags?post=25485"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}