Re: [Bitcoin-development] Detecting OP_EVAL scriptPubKeys that are to you

2011-10-25 Thread Alan Reiner
On Tue, Oct 25, 2011 at 10:49 AM, Gregory Maxwell wrote: > On Tue, Oct 25, 2011 at 9:21 AM, Gavin Andresen > wrote: > > You give the hash to whoever is paying you, and store the hash --> > > script mapping when you do that (assuming you're not using a > > deterministic wallet; if you are, you pr

Re: [Bitcoin-development] Detecting OP_EVAL scriptPubKeys that are to you

2011-10-25 Thread Gregory Maxwell
On Tue, Oct 25, 2011 at 9:21 AM, Gavin Andresen wrote: > You give the hash to whoever is paying you, and store the hash --> > script  mapping when you do that (assuming you're not using a > deterministic wallet; if you are, you probably just increment a > counter in the wallet). If anyone finds t

Re: [Bitcoin-development] Detecting OP_EVAL scriptPubKeys that are to you

2011-10-25 Thread Gavin Andresen
On Tue, Oct 25, 2011 at 6:49 AM, Mike Hearn wrote: > scriptPubKeys that use OP_EVAL contain a hash of a script. If I > understand correctly, that means to detect a transaction in a block > that is relevant to your wallet, that means you need to pre-calculate > every possible hash that might appear

[Bitcoin-development] Detecting OP_EVAL scriptPubKeys that are to you

2011-10-25 Thread Mike Hearn
scriptPubKeys that use OP_EVAL contain a hash of a script. If I understand correctly, that means to detect a transaction in a block that is relevant to your wallet, that means you need to pre-calculate every possible hash that might appear. For the case of a single payment, that's not a problem. I

Re: [Bitcoin-development] Determine input addresses of a transaction

2011-10-25 Thread Mike Hearn
> Interesting suggestion! So if I understand correctly, would be > the signature generated from signing the transaction with the key of a > green address? Sure. Or just "a key". It wouldn't have to be an actual key used in the block chain. > Sounds good - I guess I never thought in this directio

Re: [Bitcoin-development] Determine input addresses of a transaction

2011-10-25 Thread Joel Joonatan Kaartinen
On Tue, 2011-10-25 at 11:45 +0200, Jan Vornberger wrote: > 1) Get something working reasonable fast to detect current green address > style transactions. It's fine if it is a little bit of a hack, as long as > it's safe, since I don't expect it to be merged with mainline anyway at > this point. >

Re: [Bitcoin-development] Determine input addresses of a transaction

2011-10-25 Thread Jan Vornberger
Am Mo, 24.10.2011, 16:55, schrieb Gavin Andresen: >> So my first shot at this is to go through the inputs of a transaction and >> see if the scriptSig field has only two opcodes. If that is the case, I assume that it is of the structure and calculate the Bitcoin address from . >> But then I start