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 17767A16 for ; Tue, 8 Dec 2015 02:10:25 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.7.6 Received: from mail-vk0-f45.google.com (mail-vk0-f45.google.com [209.85.213.45]) by smtp1.linuxfoundation.org (Postfix) with ESMTPS id ED646117 for ; Tue, 8 Dec 2015 02:10:23 +0000 (UTC) Received: by vkca188 with SMTP id a188so3722622vkc.0 for ; Mon, 07 Dec 2015 18:10:23 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:date:message-id:subject:from:to:content-type; bh=gzmrBtNAki4xQGVnanAFC+x5/+FngL1zn/RLU56D7+Y=; b=TgfUM5GJ6r9ZLHzjb4YPnFL1BlVEO/xKYi/zMrKeJVtYLsgJFh0yKYqsQQh6B8s5Cr J3sicz6sFVh2wDXP9RPGA+4fo8Gq6VqcWQ8Ly7TQsDh8C3IA0LYQ4w1+fdm4T/0GVhEJ TmSdSqh+wp/jNL5upWiHLyt/XNLOkgJbYp4+gRI4eIJM5HGsgF5lwh4jhhE3kSQzjEM0 0d4QKSYnKIGp7mI+z0GLN85wHUnSf4tccNyJSqoovkRjcNE1/wnN1ob+QiOyZ2az/qYa oSoYkW8zfVoG/wj8JQ9JAlVMLGjOvANIx1ot7Wvxp3vwqT7PHmcIVF1/YE6YVh2rao/w spqw== MIME-Version: 1.0 X-Received: by 10.31.49.147 with SMTP id x141mr972884vkx.1.1449540622873; Mon, 07 Dec 2015 18:10:22 -0800 (PST) Received: by 10.31.96.8 with HTTP; Mon, 7 Dec 2015 18:10:22 -0800 (PST) Date: Mon, 7 Dec 2015 18:10:22 -0800 Message-ID: From: Toby Padilla To: bitcoin-dev@lists.linuxfoundation.org Content-Type: multipart/alternative; boundary=001a11438346e9fa2d05265979eb X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,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: Tue, 08 Dec 2015 11:28:20 +0000 Subject: [bitcoin-dev] Key.run: BIP-70 Payments and OP_RETURN X-BeenThere: bitcoin-dev@lists.linuxfoundation.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: Bitcoin Development Discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 08 Dec 2015 02:10:25 -0000 --001a11438346e9fa2d05265979eb Content-Type: text/plain; charset=UTF-8 Hi all. I've been working on a new publication platform based on Bitcoin called key.run: http://key.run The high level overview is that key.run stores BitTorrent info hashes (magnet links) in the blockchain by sending transactions to a "namespace" Bitcoin address. Using SPV, I reconstitute the key.run db from the blockchain. This is meant to be an open source and distributed system so anyone can run the key.run server (and change namespace keys). More info here: https://git.playgrub.com/toby/keyrun Now to my issue... One of the main use cases I wanted to support was people using their *existing* Bitcoin wallet to encode the key.run transactions on the blockchain. Practically speaking this meant building the transactions with the proper OP_RETURN value server-side then passing them to the end user's wallet via BIP-70. I have this working with Bitcoin Core (there are issues with other wallets I've tested with BIP-70). The problem I'm having is that Bitcoin Core will not allow BIP-70 PaymentDetails to contain outputs with zero value. As stated in https://github.com/bitcoin/bips/blob/master/bip-0070.mediawiki: "if there are more than one; Outputs with zero amounts shall be ignored" Bitcoin Core doesn't seem to ignore the output though, it rejects the transaction and doesn't allow the user to submit it. The key.run transactions currently work by giving the OP_RETURN outputs a non-zero > dust value. This value is presumably lost forever. I think ideally OP_RETURN outputs with zero value WOULD be allowed since they are valid transactions. Allowing OP_RETURN outputs to be constructed with BIP-70 Payments is also the only way I can think of to extend the functionality of existing wallets. I would love to get feedback on if there is an alternative way to do what I propose or ideally if BIP-70 could be tweaked to allow OP_RETURN outputs with zero value. I'd also love feedback on key.run but this probably isn't the best venue for that. I've setup #keyrun on Freenode if anyone is interested in discussing the project. Regards, Toby -- http://twitter.com/toby --001a11438346e9fa2d05265979eb Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Hi all. I've been working on a new publication pl= atform based on Bitcoin called key.run: http://k= ey.run

The high level overview is that key.run= stores BitTorrent info hashes (magnet links) in the blockchain by sending = transactions to a "namespace" Bitcoin address. Using SPV, I recon= stitute the key.run db from the blockchain. This is meant to be an open sou= rce and distributed system so anyone can run the key.run server (and change= namespace keys). More info here: https://git.playgrub.com/toby/keyrun

N= ow to my issue...

One of the main use cases I want= ed to support was people using their *existing* Bitcoin wallet to encode th= e key.run transactions on the blockchain. Practically speaking this meant b= uilding the transactions with the proper OP_RETURN value server-side then p= assing them to the end user's wallet via BIP-70. I have this working wi= th Bitcoin Core (there are issues with other wallets I've tested with B= IP-70).

The problem I'm having is that Bitcoin= Core will not allow BIP-70 PaymentDetails to contain outputs with zero val= ue. As stated in https://github.com/bitcoin/bips/blob/master/bip-0070.media= wiki:

"if there are more than one; Output= s with zero amounts shall be ignored"

Bitcoin= Core doesn't seem to ignore the output though, it rejects the transact= ion and doesn't allow the user to submit it. The key.run transactions c= urrently work by giving the OP_RETURN outputs a non-zero > dust value. T= his value is presumably lost forever.

I think idea= lly OP_RETURN outputs with zero value WOULD be allowed since they are valid= transactions. Allowing OP_RETURN outputs to be constructed with BIP-70 Pay= ments is also the only way I can think of to extend the functionality of ex= isting wallets.

I would love to get feedback on if= there is an alternative way to do what I propose or ideally if BIP-70 coul= d be tweaked to allow OP_RETURN outputs with zero value.

I'd also love feedback on key.run but this probably isn't th= e best venue for that. I've setup #keyrun on Freenode if anyone is inte= rested in discussing the project.

Regards,
Toby

--
--001a11438346e9fa2d05265979eb--