Return-Path: Received: from smtp1.linuxfoundation.org (smtp1.linux-foundation.org [172.17.192.35]) by mail.linuxfoundation.org (Postfix) with ESMTPS id 76995724 for ; Thu, 4 Aug 2016 02:07:08 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.7.6 Received: from mail-io0-f169.google.com (mail-io0-f169.google.com [209.85.223.169]) by smtp1.linuxfoundation.org (Postfix) with ESMTPS id 4742D12C for ; Thu, 4 Aug 2016 02:07:07 +0000 (UTC) Received: by mail-io0-f169.google.com with SMTP id 38so260227083iol.0 for ; Wed, 03 Aug 2016 19:07:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=roberts-pm.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:from:date:message-id:subject:to; bh=heLRVsyzTEPIKCx9phkusxURRVIHMHobXcVx/qUQUIc=; b=kh2QOtJ4WzCd7vD3Poh5+HfO7dudLwrpz+OZmpub3tWMZ/twYIdBPiZ0b9Ywj4gyjO tulXWhY2lWBznVa8OkCSsadcMlsK2BC4n6MQAp0ojIklBgov517Bc2i6pLZn9/7jvufJ p9LmyleLO6JcgIY0XCUqRHj53glEwgIZZc0f8PRDAqiZ4fF9fXUSHdqaFpzTdhpANMGX NHmSoVucPJgEubMVpn405szH+MycwkPlBOWq1OwtYiMF8Q9ypE0K4ChIIbq2J0R9Eh0Q M00QlBFdFdyomRJGjqwr5Z4Kbk3dHaz/iwnde2972LmlT+RVIJo4x4qk82wozltWE1W0 Y2kg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to; bh=heLRVsyzTEPIKCx9phkusxURRVIHMHobXcVx/qUQUIc=; b=UH0nyDiwmQckRNSH2zHzmJsenUVS4YGMuNGnPf7K2dJDR0H5DJKCrXXGc6j3ci7P7E A4YB7Ae7zB5UitwHcPBTr3ICQdZgaC6YxfzVk783NoxUagjxDNfC2H6sTUt+jx12qXFF naHe+LGZ8eQ+XxY6u21zM9b+11cVdpXyq5Y01hG1EknwqFFN65lgAAvVhOWjb5dePY43 M4VfFJ5VSdqSksTCtMmPJxkB7Zjtl1BXP+OqoC1vAm+qCdhl+JF+5sF24VOPzph7bfvJ yMY0rozjV315yMHy6ryiiInMOhNnIduZwVjTeDBw3i+vk5jpyu34ammzr5E/ukZgmI0A cxFw== X-Gm-Message-State: AEkoouu4EPjzY1oCFZKfmVMAzFEkM2+DJkPDUPoFX+QDMcn9yo2ph3nX1xLO0vxgJAW102To+dY2cON19tbQOQ== X-Received: by 10.107.23.66 with SMTP id 63mr79814834iox.169.1470276426562; Wed, 03 Aug 2016 19:07:06 -0700 (PDT) MIME-Version: 1.0 Received: by 10.107.57.69 with HTTP; Wed, 3 Aug 2016 19:07:06 -0700 (PDT) X-Originating-IP: [115.70.56.56] In-Reply-To: References: From: Matthew Roberts Date: Thu, 4 Aug 2016 12:07:06 +1000 Message-ID: To: Tier Nolan , Bitcoin Protocol Discussion Content-Type: multipart/alternative; boundary=94eb2c05c23e20a7c605393568c4 X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,HTML_MESSAGE,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 X-Mailman-Approved-At: Thu, 04 Aug 2016 09:05:37 +0000 Subject: Re: [bitcoin-dev] BIP clearing house addresses 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: Thu, 04 Aug 2016 02:07:08 -0000 --94eb2c05c23e20a7c605393568c4 Content-Type: text/plain; charset=UTF-8 This would honestly work. It forces the attacker to go through with the clearing phase which simultaneously makes it possible to "cancel" the TX through another logic branch before the timeout occurs. I'd say that would meet the needs of a clearing mechanism / fraud prevention system for an exchange perfectly while requiring minimal changes to the software. Very, very smart idea. A++, would read again. On Thu, Aug 4, 2016 at 9:55 AM, Tier Nolan via bitcoin-dev < bitcoin-dev@lists.linuxfoundation.org> wrote: > On Wed, Aug 3, 2016 at 7:16 PM, Matthew Roberts via bitcoin-dev < > bitcoin-dev@lists.linuxfoundation.org> wrote: > >> The reason why I bring this up is existing OP codes and TX types don't >> seem suitable for a secure clearing mechanism; >> > > I think reversing transactions is not likely to be acceptable. You could > add an opcode that requires that an output be set to something. > > [target script] SPENDTO > > This would require that [target script] is the script for the > corresponding output. This is a purely local check. > > For example, if SPENDTO executes as part of the script for input 3, then > it checks that output 3 uses the given script as its scriptPubKey. The > value of input 3 and output 3 would have to be the same too. > > This allows check sequence verify to be used to lock the spending script > for a while. This doesn't allow reversal, but would give a 24 hour window > where the spenders can reverse the transaction. > > [IF <1 day> CSV DROP CHECKSIG ELSE key> CHECKSIG] SPENDTO CHECKSIG > > Someone with the live public key can create a transaction that spends the > funds to the script in the square brackets. > > Once that transaction hits the blockchain, then someone with the protected key> has 24 hours to spend the output before the person with the > live keys can send the funds onward. > > _______________________________________________ > bitcoin-dev mailing list > bitcoin-dev@lists.linuxfoundation.org > https://lists.linuxfoundation.org/mailman/listinfo/bitcoin-dev > > --94eb2c05c23e20a7c605393568c4 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
This would honestly work. It forces the attacker to g= o through with the clearing phase which simultaneously makes it possible to= "cancel" the TX through another logic branch before the timeout = occurs. I'd say that would meet the needs of a clearing mechanism / fra= ud prevention system for an exchange perfectly while requiring minimal chan= ges to the software.

Very, very smart idea. A++, would read ag= ain.

On = Thu, Aug 4, 2016 at 9:55 AM, Tier Nolan via bitcoin-dev &= lt;bitcoin-dev@lists.linuxfoundation.org> wrote:
On Wed, Aug 3, 2016 at 7:16 PM, Matthew = Roberts via bitcoin-dev <bitcoin-dev@lists.linuxfounda= tion.org> wrote:
The reason why I bring this up is existing OP codes and TX types don't seem suitable for a secure clearing mechanism;

I think r= eversing transactions is not likely to be acceptable.=C2=A0 You could add a= n opcode that requires that an output be set to something.

[target script] SPENDTO

This would require that [target= script] is the script for the corresponding output.=C2=A0 This is a purely= local check.=C2=A0

For example, if SPENDTO executes as part of the= script for input 3, then it checks that output 3 uses the given script as = its scriptPubKey.=C2=A0 The value of input 3 and output 3 would have to be = the same too.

This allows check sequence verify to be use= d to lock the spending script for a while.=C2=A0 This doesn't allow rev= ersal, but would give a 24 hour window where the spenders can reverse the t= ransaction.

[IF <1 day> CSV DROP <live public ke= y> CHECKSIG ELSE <offline protected key> CHECKSIG] SPENDTO <liv= e public key2> CHECKSIG

Someone with the li= ve public key can create a transaction that spends the funds to the script = in the square brackets.

Once that transaction hits the bl= ockchain, then someone with the <offline protected key> has 24 hours = to spend the output before the person with the live keys can send the funds= onward.

_______________________________________________
bitcoin-dev mailing list
bitcoin-dev@lists.= linuxfoundation.org
https://lists.linuxfoundation.org/mail= man/listinfo/bitcoin-dev


--94eb2c05c23e20a7c605393568c4--