Bitcoin Protocol OP_RETURN + Omni USDT Tether + CoPay Multisig Help I have been asked to recover some tether that have been sent to the wrong address... Sitting on the blockchain in a multisig copay account.

I have written small php command line tools to reproduce the case and learn more about how Bitcoin works. I am a software developer working mostly with NEM where the blockchain is very different. I have learned a lot about multisig on Bitcoin, OP_RETURNs used in omni (usdt being a smartproperty on the omni layer), and many more awesome things about hierarchical key generation, key derivation functions, and many more subjects.

Script are written in PHP with laravel/zero and can be found here:


BIP32+44 HD Addresses Generation Tool on Github
BIP39 Seed Derivation (get Private Keys) on Github
My P2SH Colored Transaction creation on Github


But I struggle getting back those tether to another address. Of course, I own the 3 cosigners configured with copay, but I am too much of a noob to get those tether back. Fact is, the NEM blockchain is very different when it comes to multisig and custom assets. So I went through the learning process for HD keys and XPRV and XPUBs. Which I also built a command for. A command that, provided with the right derivation path and xpubs or mnemonics, will generate the same cosigners xpubs as copay displays in the multisig wallet information page. 

Here is a link to the BitcoinTalk thread where you will find a screenshot and more details about the transaction i am trying to create. Maybe someone here might help as this requires deep understanding of Bitcoin Multisig, HD Key Derivations, OP_RETURN and Colored Coins. 

The challenge is quite amazing and let me learn tons of things, but watching serialized data I think I am getting crazy, I can't get it done, please hAlp ! x:)

PS: &lt;3 Bitcoin
I have solved my problem with a lot of debugging and help from the community on IRC irc.freenode.net #bitcoin-dev and also from people on the bitcointalk thread I started about this Topic.

I invite anyone having similar Copay Multisig Omni Colored Coins Recovery Issues to have a look at the bitcointalk thread here: https://bitcointalk.org/index.php?topic=2500531

The Problem is hereby solved, Details about how Copay derives keys can be found in the linked thread as well as more detail about what was implemented to apply the recovery (command line tool "omni:copay-recovery" on Github).