This is a possible solution for implementing UTU Trust on ICP - authored by JD.
ICP is a different blockchain technology to Ethereum.
Core differences include that end users do not pay gas fees on ICP but they do on Ethereum. In the case of ICP the deployer of a smart contract to ICP needs to add a balance so the smart contract can be invoked. The more used the contract, the more it costs.
Another difference is that smart contract code size and storage on Ethereum is much much more expensive than on ICP.
A further difference is that ICP smart contracts (called canisters) can make https calls.
ICP and Ethereum private and public keys are not of the same type and thus the same keys cannot be used for both ICP and Ethereum chains - this is a big pity.
We want to bring UTU trust to ICP. This Page suggests how we could do this.
It is possible that if an end user refreshes their connector with both Ethereum and ICP addresses that the different addresses are associated in a solidity map in the existing smart contract used to transfer UTT tokens on endorsement. Effectively we get proof that a certain social medial handle is linked to different ethereum and ICP addresses.
This is a similar principle to next.id being able to associate mulltiple ethereum wallet addresses with social media handles. next.id gets one to send for example a tweet with some content signed by a private key. The url of the public tweet is fed back into next.id servers which proves that the social media handle owner is also the owner of the wallet address. This relationship is then updated on chain. UTU’s social media connectors could do the equivalent association.
So in order to use Trust on ICP the user will need to associate their social media handles using both Metamask and their ICP Plug wallet. The alternative is we create a similar proof system to next.id.
In the Ethereum endorsement contract we need to create a map of associated public keys. Both Ethereum and ICP public keys can be associated by an additional call to the smart contract. We could optionally provide the association with the social media handle if the end user signs they are happy with that to be public knowledge.
When on iCP the endorsement goes to the ICP Proxy Contract. The https ethereum functionality passes signed content via the Ethereum Proxy contract to the Ethereum Endorsement contract.
The Ethereum Endorsement contract retrieves the public key from the signed ICP content and looks it up in the map to find the corresponding Ethereum public key, if such a mapping exists it knows it can go ahead and adjust the UTT balance with the ethereum counterpart address.
This idea requires the UTU endorsement contract to be updated with this new map functionality. As we have a proxy contract on ethereum we are able to update the endorsement contract’s code.
An alternative to this solution is to create UTT duplicate tokens on both ICP and Ethereum chains and have their balances synched via listening oracles. The problem with this approach is that the balances could be conceivable spent twice without a proper lock. That proper lock would need to lock on address across both chains and technologies.