Received: from sog-mx-4.v43.ch3.sourceforge.com ([172.29.43.194] helo=mx.sourceforge.net) by sfs-ml-3.v29.ch3.sourceforge.com with esmtp (Exim 4.76) (envelope-from ) id 1XD1BK-0000rI-AR for bitcoin-development@lists.sourceforge.net; Fri, 01 Aug 2014 00:58:50 +0000 Received-SPF: pass (sog-mx-4.v43.ch3.sourceforge.com: domain of gmail.com designates 209.85.218.52 as permitted sender) client-ip=209.85.218.52; envelope-from=keziahw@gmail.com; helo=mail-oi0-f52.google.com; Received: from mail-oi0-f52.google.com ([209.85.218.52]) by sog-mx-4.v43.ch3.sourceforge.com with esmtps (TLSv1:RC4-SHA:128) (Exim 4.76) id 1XD1BJ-0007wJ-8b for bitcoin-development@lists.sourceforge.net; Fri, 01 Aug 2014 00:58:50 +0000 Received: by mail-oi0-f52.google.com with SMTP id h136so2289358oig.39 for ; Thu, 31 Jul 2014 17:58:43 -0700 (PDT) X-Received: by 10.182.205.231 with SMTP id lj7mr2653768obc.37.1406854723794; Thu, 31 Jul 2014 17:58:43 -0700 (PDT) MIME-Version: 1.0 Received: by 10.202.61.195 with HTTP; Thu, 31 Jul 2014 17:58:23 -0700 (PDT) From: Kaz Wesley Date: Thu, 31 Jul 2014 17:58:23 -0700 Message-ID: To: Bitcoin Dev Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: -1.6 (-) X-Spam-Report: Spam Filtering performed by mx.sourceforge.net. See http://spamassassin.org/tag/ for more details. -1.5 SPF_CHECK_PASS SPF reports sender host as permitted sender for sender-domain 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (keziahw[at]gmail.com) -0.0 SPF_PASS SPF: sender matches SPF record -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature X-Headers-End: 1XD1BJ-0007wJ-8b Subject: [Bitcoin-development] deterministic transaction expiration X-BeenThere: bitcoin-development@lists.sourceforge.net X-Mailman-Version: 2.1.9 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 01 Aug 2014 00:58:50 -0000 There is currently little in place for managing transaction lifetime in the network's mempools (see discussion in github in #3722 "mempool transaction expiration", and it seems to be a major factor blocking some mempool exchange, see #1833/1918, #3721). Expiry per-node a certain amount of wall time after receipt has been proposed, but that's a fragile mechanism -- a single node could keep all relayable transactions alive forever by remembering transactions until most nodes have dropped them and then releasing them back into the wild. I have a proposal for a way to add finite and predictable lifespans to transactions in mempools: we d=CC=B6e=CC=B6s=CC=B6t=CC=B6r=CC=B6o=CC=B6y=CC= =B6 =CC=B6t=CC=B6h=CC=B6e=CC=B6 =CC=B6r=CC=B6e=CC=B6s=CC=B6u=CC=B6r=CC=B6r=CC=B6e=CC=B6c=CC=B6t=CC=B6i=CC= =B6o=CC=B6n=CC=B6 =CC=B6h=CC=B6u=CC=B6b=CC=B6 use nLockTime and a new stand= ardness rule. It could be done in stages, would not necessarily require even a soft fork, and does not cause problems with reorgs like the proposal in #3509: 1. start setting nLockTime to the current height by default in newly created transactions (or slightly below the current height, for reorg-friendliness) 2. once users have had some time to upgrade to clients that set nLockTime, start discouraging transactions without nLockTime -- possibly with a slightly higher fee required for relay 3. start rate-limiting relay of transactions without an nLockTime (maybe this alone could be used to achieve [2]) 4. add a new IsStandard rule rejecting transactions with an nLockTime more than N blocks behind the current tip (for some fixed value N, to be determined) Transactions would stop being relayed and drop out of mempools a fixed number of blocks from their creation; once that window had passed, the sender's wallet could begin to expect the transaction would not be confirmed. In case a reorg displaces a transaction until after its expiry height, a miner can still put it back in the blockchain; the expiry height is just a relay rule. Also, a user who needed to get their original "expired" transaction confirmed could still do so by submitting it directly to a miner with suitable policies.