Thanks for the answer Ishmael. However, that is not exactly the answer that 
I was looking for. I guess that my question was not deep enough and not 
properly asked. I'll rephrase: 

In a common ScriptPubKey to pay a single recipient, we use the bitcoin 
address (hash of the public key):

scriptPubKey: OP_HASH160 <scriptHash> OP_EQUAL 


However, in a multisig (what I guess that createMultiSigOutputScript creates), 
the Script requires the public keys:
script: OP_m <pubKey1> ... OP_n OP_CHECKMULTISIG

Since I guess that there is no way to do a multisig with bitcoin addresses 
instead of public keys, then my question is: why was this created like that?,
instead of being more consistent and using addresses like in the scriptPubKey?  


Kind regards,
V

On Monday, December 4, 2017 at 8:19:51 PM UTC+1, Ishmael Riles wrote:
>
> The multisig script is created from the public keys. An address is a hash 
> of the public key, the hash goes only one way so you can not derive the 
> public key from the address.
>
> On Wednesday, November 22, 2017 at 6:44:25 AM UTC-8, vg-coder wrote:
>>
>> Hi all!
>>
>> I am testing some easy smart contracts and I got a doubt. Why do we need 
>> the ECKey in createMultiSigOutputScript instead of using Address?
>> Is there no way to achieve the same with the addresses instead of using 
>> keys?, since normally, between two parties, we interchange addresses not 
>> public keys. 
>>
>> Kind regards,
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"bitcoinj" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to bitcoinj+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to