Author

Topic: multi-asset system: how to make sure it is the same asset across the P2SH TXs (Read 620 times)

newbie
Activity: 59
Merit: 0
One of the problem I encountered is how to make sure it is the same asset across the transactions in the chain, eventually I resolved the problem, for example, I have two different assets: MYCN and TEND coins.

C:\Test>ABC.Service.exe getnewaddress MYCN
17KEXZ1kaabpX6z571B4R1AD46whTkMiLM

C:\Test>ABC.Service.exe createrawtransaction "[{\"txid\":\"f92f0bbb1b37d1d22fb797abab1dd686c81a495cd2bf959d2c1879a6f88b6e13\",\"vout\":0}]" "{\"17KEXZ1kaabpX6z571B4R1AD46whTkMiLM\":0.0003}"
Error: the previous tx has the different asset as the current tx you want to create, please check check the destination address and try again.

C:\Test>ABC.Service.exe getnewaddress TEND
15ZhBPuPDAdSMvU4wpsCoaf2rE9YinvH4X

C:\Test>ABC.Service.exe createrawtransaction "[{\"txid\":\"f92f0bbb1b37d1d22fb797abab1dd686c81a495cd2bf959d2c1879a6f88b6e13\",\"vout\":0}]" "{\"15ZhBPuPDAdSMvU4wpsCoaf2rE9YinvH4X\":0.0003}"
0100000001136e8bf8a679182c9d95bfd25c491ac886d61dabab97b72fd2d1371bbb0b2ff900000 00000ffffffff0130750000000000001976a914320f5a951f3555753aa8ae9e045af4d3ad48d07c 88ac00000000

as you can see in above, the MYCN coin address can not be the P2SH destination address of TEND transactions, the asset is maintained across the transactions, the purpose of doing this is to make sure that the total number of your coins will never change.

http://abcoin.info/category/technical-discussion

for detail multi coin/asset system, please see detail http://icoinhost.com
Jump to: