From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from sog-mx-3.v43.ch3.sourceforge.com ([172.29.43.193] helo=mx.sourceforge.net) by sfs-ml-2.v29.ch3.sourceforge.com with esmtp (Exim 4.76) (envelope-from ) id 1Xa3qM-0004AF-KP for bitcoin-development@lists.sourceforge.net; Fri, 03 Oct 2014 14:28:26 +0000 X-ACL-Warn: Received: from resqmta-ch2-04v.sys.comcast.net ([69.252.207.36]) by sog-mx-3.v43.ch3.sourceforge.com with esmtps (TLSv1:AES128-SHA:128) (Exim 4.76) id 1Xa3qL-0002Pq-CG for bitcoin-development@lists.sourceforge.net; Fri, 03 Oct 2014 14:28:26 +0000 Received: from resomta-ch2-01v.sys.comcast.net ([69.252.207.97]) by resqmta-ch2-04v.sys.comcast.net with comcast id yeS51o00A26dK1R01eULdP; Fri, 03 Oct 2014 14:28:20 +0000 Received: from crushinator.localnet ([IPv6:2601:6:4800:47f:1e4e:1f4d:332c:3bf6]) by resomta-ch2-01v.sys.comcast.net with comcast id yeUH1o00V2JF60R01eUKZF; Fri, 03 Oct 2014 14:28:19 +0000 From: Matt Whitlock To: Peter Todd Date: Fri, 03 Oct 2014 10:28:17 -0400 Message-ID: <1987325.zKPNeYyO8K@crushinator> User-Agent: KMail/4.14.1 (Linux/3.14.14-gentoo; KDE/4.14.1; x86_64; ; ) In-Reply-To: References: <20141001130826.GM28710@savin.petertodd.org> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" X-Spam-Score: 0.0 (/) X-Spam-Report: Spam Filtering performed by mx.sourceforge.net. See http://spamassassin.org/tag/ for more details. -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at http://www.dnswl.org/, no trust [69.252.207.36 listed in list.dnswl.org] 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: 1Xa3qL-0002Pq-CG Cc: bitcoin-development@lists.sourceforge.net, Flavien Charlon Subject: Re: [Bitcoin-development] [BIP draft] CHECKLOCKTIMEVERIFY - Prevent a txout from being spent until an expiration time 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, 03 Oct 2014 14:28:26 -0000 Is there a reason why we can't have the new opcode simply replace the top stack item with the block height of the txout being redeemed? Then arbitrary logic could be implemented, including "output cannot be spent until a certain time" and also "output can ONLY be spent until a certain time," as well as complex logic with alternative key groups with differing time constraints. OP_CHECKLOCKTIMEVERIFY, as conceived, seems too limited, IMHO. On Thursday, 2 October 2014, at 4:05 pm, Flavien Charlon wrote: > Very good, I like the proposal. > > A question I have: can it be used to do the opposite, i.e. build a script > that can only be spent up until block X? > > On Thu, Oct 2, 2014 at 2:09 AM, Peter Todd wrote: > > > -----BEGIN PGP SIGNED MESSAGE----- > > Hash: SHA256 > > > > > > > > On 1 October 2014 17:55:36 GMT-07:00, Luke Dashjr wrote: > > >On Thursday, October 02, 2014 12:05:15 AM Peter Todd wrote: > > >> On 1 October 2014 11:23:55 GMT-07:00, Luke Dashjr > > >wrote: > > >> >Thoughts on some way to have the stack item be incremented by the > > >> >height at > > >> >which the scriptPubKey was in a block? > > >> > > >> Better to create a GET-TXIN-BLOCK-(TIME/HEIGHT)-EQUALVERIFY operator. > > >> scriptPubKey would be: > > >> GET-TXIN-BLOCKHEIGHT-EQUALVERIFY > > >> (fails unless top stack item is equal to the txin block height) > > >> ADD > > >> (top stack item is now txin height + delta height) > > >> CHECKLOCKTIMEVERIFY > > > > > >This sounds do-able, although it doesn't address using timestamps. > > > > For timestamps replace "height" with "time" in the above example; the > > minimum block time rule will prevent gaming it. > > > > > > >> You'd want these sacrifices to unlock years into the future to > > >thoroughly > > >> exceed any reasonable business cycle; that's so far into the future > > >that > > >> miners are almost certain to just mine them and collect the fees. > > > > > >For many use cases, short maturity periods are just as appropriate IMO. > > > > Very easy to incentivise mining centralisation with short maturities. I > > personally think just destroying coins is better, but it doesn't sit well > > with people so this is the next best thing. > > -----BEGIN PGP SIGNATURE----- > > Version: APG v1.1.1 > > > > iQFQBAEBCAA6BQJULKWsMxxQZXRlciBUb2RkIChsb3cgc2VjdXJpdHkga2V5KSA8 > > cGV0ZUBwZXRlcnRvZGQub3JnPgAKCRAZnIM7qOfwhcg8CACueZNGfWaZR+xyG9/o > > JwDBCnqOtwr6Bnosg3vNcRIDUnmsh+Qkk5dk2JpqYNYw7C3duhlwHshgsGOFkHEV > > f5RHDwkzGLJDLXrBwxxcIDdm3cJL8UVpQzJ7dD7aSnfj7MU/0aru3HaIU2ZfymUb > > 63jhul6FGbXH3K6p3bOoNrfIrCCGOv8jOIzeAgxNPydk8MVPgRhlYLAKBJxu8nMr > > 1oJGeaKVSGSPSrRdgS8tI4uOs0F4Q49APrLPGxGTERlATmWrr+asHGJTIxsB2IEm > > vrNgVRpkaN4Of9k96qzD9ReKfBfqm0WQKLolcXCVqGpdoHcvXh2AeWdjB/EFTyOq > > SOgO > > =WybM > > -----END PGP SIGNATURE----- > > > > > > > > ------------------------------------------------------------------------------ > > Meet PCI DSS 3.0 Compliance Requirements with EventLog Analyzer > > Achieve PCI DSS 3.0 Compliant Status with Out-of-the-box PCI DSS Reports > > Are you Audit-Ready for PCI DSS 3.0 Compliance? Download White paper > > Comply to PCI DSS 3.0 Requirement 10 and 11.5 with EventLog Analyzer > > > > http://pubads.g.doubleclick.net/gampad/clk?id=154622311&iu=/4140/ostg.clktrk > > _______________________________________________ > > Bitcoin-development mailing list > > Bitcoin-development@lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/bitcoin-development > >