Re: [Bitcoin-development] Bug with handing of OP_RETURN?

2014-05-05 Thread Jeff Garzik
Correct, though that was somewhat unintentional. The pushed-data size is limited to = 40 bytes, and as non-pushdata opcodes carry zero pushed data, they are accepted. On Sun, May 4, 2014 at 8:07 AM, Sergio Lerner sergioler...@certimix.com wrote: El 03/05/2014 03:55 p.m., Mark Friedenbach

Re: [Bitcoin-development] Bug with handing of OP_RETURN?

2014-05-04 Thread Flavien Charlon
Thanks, that makes sense, just wanted to make sure this what the problem was. On Sun, May 4, 2014 at 6:15 AM, Jeff Garzik jgar...@bitpay.com wrote: On Sat, May 3, 2014 at 2:04 PM, Flavien Charlon flavien.char...@coinprism.com wrote: Outputs are above dust, inputs are not spent. OP_RETURN is

Re: [Bitcoin-development] Bug with handing of OP_RETURN?

2014-05-04 Thread Jeff Garzik
On Sat, May 3, 2014 at 3:15 PM, Mark Friedenbach m...@monetize.io wrote: Is it more complex? The current implementation using template matching seems more complex than `if script.vch[0] == OP_RETURN script.vch.size() 42` Not much more complex. The template matches a two-chunk script with

Re: [Bitcoin-development] Bug with handing of OP_RETURN?

2014-05-03 Thread Peter Todd
-BEGIN PGP SIGNED MESSAGE- Hash: SHA256 The standard format ended up being exactly: OP_RETURN 0 to 40-byte PUSHDATA You've split the data across two PUSHDATA's. The standard should have let the data be split up like that; pull requests accepted. On 3 May 2014 13:04:52 GMT-05:00,

Re: [Bitcoin-development] Bug with handing of OP_RETURN?

2014-05-03 Thread Mark Friedenbach
I don't think such a pull request would be accepted. The point was to minimize impact to the block chain. Each extras txout adds 9 bytes minimum, with zero benefit over serializing the data together in a single OP_RETURN. On 05/03/2014 11:39 AM, Peter Todd wrote: The standard format ended up

Re: [Bitcoin-development] Bug with handing of OP_RETURN?

2014-05-03 Thread Gregory Maxwell
On Sat, May 3, 2014 at 11:55 AM, Mark Friedenbach m...@monetize.io wrote: I don't think such a pull request would be accepted. The point was to minimize impact to the block chain. Each extras txout adds 9 bytes minimum, with zero benefit over serializing the data together in a single

Re: [Bitcoin-development] Bug with handing of OP_RETURN?

2014-05-03 Thread Mark Friedenbach
Is it more complex? The current implementation using template matching seems more complex than `if script.vch[0] == OP_RETURN script.vch.size() 42` On 05/03/2014 12:08 PM, Gregory Maxwell wrote: On Sat, May 3, 2014 at 11:55 AM, Mark Friedenbach m...@monetize.io wrote: I don't think such a

Re: [Bitcoin-development] Bug with handing of OP_RETURN?

2014-05-03 Thread Jeff Garzik
On Sat, May 3, 2014 at 2:04 PM, Flavien Charlon flavien.char...@coinprism.com wrote: Outputs are above dust, inputs are not spent. OP_RETURN is supposed to be standard in 0.9.1 and the data is well below 40 bytes, so why is this being rejected? The carried data must all be contained within one