From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp1.linuxfoundation.org (smtp1.linux-foundation.org [172.17.192.35]) by mail.linuxfoundation.org (Postfix) with ESMTPS id DEFA140A for ; Mon, 22 May 2017 16:14:15 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from outmail149095.authsmtp.com (outmail149095.authsmtp.com [62.13.149.95]) by smtp1.linuxfoundation.org (Postfix) with ESMTPS id 211F415C for ; Mon, 22 May 2017 16:14:14 +0000 (UTC) Received: from mail-c247.authsmtp.com (mail-c247.authsmtp.com [62.13.128.247]) by punt24.authsmtp.com (8.14.2/8.14.2/) with ESMTP id v4MGEBhi090122; Mon, 22 May 2017 17:14:11 +0100 (BST) Received: from petertodd.org (ec2-52-5-185-120.compute-1.amazonaws.com [52.5.185.120]) (authenticated bits=0) by mail.authsmtp.com (8.14.2/8.14.2/) with ESMTP id v4MGE9gk043504 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Mon, 22 May 2017 17:14:10 +0100 (BST) Received: from [127.0.0.1] (localhost [127.0.0.1]) by petertodd.org (Postfix) with ESMTPSA id 539B04013D; Mon, 22 May 2017 16:14:08 +0000 (UTC) Received: by localhost (Postfix, from userid 1000) id 5E1A620101; Mon, 22 May 2017 12:14:04 -0400 (EDT) Date: Mon, 22 May 2017 12:14:04 -0400 From: Peter Todd To: Ethan Heilman Message-ID: <20170522161404.GA18885@fedora-23-dvm> References: <20170522140919.GA17878@fedora-23-dvm> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="pWyiEgJYm5f9v55/" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.23 (2014-03-12) X-Server-Quench: b061881e-3f09-11e7-bcdf-0015176ca198 X-AuthReport-Spam: If SPAM / abuse - report it at: http://www.authsmtp.com/abuse X-AuthRoute: OCd2Yg0TA1ZNQRgX IjsJECJaVQIpKltL GxAVKBZePFsRUQkR aQdMdAAUFVQNAgsB AmEbWlNeUVl7WGM7 bghPaBtcak9QXgdq T0pMXVMcUgEVdmkI UUUeVhp3dwEIcXx2 YggwXnZaVEx7IFt+ FE5dCGwHMGB9OjNL Bl1YdwJRcQRMLU5E Y1gxNiYHcQ5VPz4z GA41ejw8IwAXAWxN WAYVKkkbRQ4XGXYm ShEEAS8oEVAOSm0v LxFuJl8HFUwVP0l6 KlA7WEoEUVcVEgZZ E0xWaAAA X-Authentic-SMTP: 61633532353630.1038:706 X-AuthFastPath: 0 (Was 255) X-AuthSMTP-Origin: 52.5.185.120/25 X-AuthVirus-Status: No virus detected - but ensure you scan with your own anti-virus system. X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on smtp1.linux-foundation.org Cc: Bitcoin Dev Subject: Re: [bitcoin-dev] A proposal to reintroduce the disabled script opcodes X-BeenThere: bitcoin-dev@lists.linuxfoundation.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: Bitcoin Protocol Discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 22 May 2017 16:14:16 -0000 --pWyiEgJYm5f9v55/ Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, May 22, 2017 at 10:41:40AM -0400, Ethan Heilman wrote: > >It'd help your case if you gave us some examples of such scripts being > used. >=20 > I want OP_CAT so that I can securely and compactly verify many hashes and > hash preimages. This would shrink offchain Tumblebit transactions > significantly. >=20 > For instance if I want a transaction TxA which checks that a transaction > TxB releases preimages x1,x2,...,x10 such that > y1=3DH(x1), y2=3DH(x2),...,y10=3DH(x10). Currently I just put y1,...y10 a= nd check > that the preimahes hash correctly. With OP_CAT I would only have to store > one hash in TxA, yhash >=20 > ytotal =3D H(OP_CAT(H(OP_CAT(y1, y2)),y3)...y10) >=20 > TxA could then just hash all the preimages supplied by TxB and confirm th= ey > hash to TxA. This would reduce the size of TxA from approx 10*32B to > 32+10*16B. I have a version which improves this further but it is more > complex. >=20 > Most of the math OP codes aren't particularly helpful due to their 32bit > nature and their strange overflow behavior. Great! That's exactly the type of justifying use-case we need for a BIP. An OP_CAT will have to have limits on maximum output size; how big an output does your application need? --=20 https://petertodd.org 'peter'[:-1]@petertodd.org --pWyiEgJYm5f9v55/ Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature -----BEGIN PGP SIGNATURE----- iQEcBAEBCAAGBQJZIw5JAAoJECSBQD2l8JH7330H/0KNsTfnDNlyZyQslncEptoh LEYfziNSaxob3C3i7U9/4/bYBbRs7oVlDZa7ZDKnJC/PDfGvStDru1Gr+LwEQbwp q4cJE0Y9tkVVmdsnpE859in5N2AUkk3lvMtbj+i0RS+MjdbE7S8JD4roUNP33wn0 JGtP7wbo/s6fqOmBbg9QTXYH0vZAYxXoPVJHAwUnWtvHXazgxSAv5kxQETYzEshZ zJHr1MVD7X+uSjoC86Iyu3/Ej7BI/ASjznrJrjjJ3q3tTefTMG5qQrsnaODU4zkS mhtskQQkFp5BQv75qXTxhCbRzK+x9PrkFxTEB+b0TuSzhy6ZTz1SnzuuvmjH7Zk= =Pb87 -----END PGP SIGNATURE----- --pWyiEgJYm5f9v55/--