uport like application using multichain

+1 vote
Hi Team,

Can we build a uport like application using multichain? If yes, how should we design it on multichain?
asked Dec 18, 2017 by amanc

1 Answer

0 votes

In general for identity applications you would use MultiChain streams.

For aspects of identity which people declare for themselves, they can publish items directly onto an open stream, and any node can retrieve a person's items by searching for stream items published by that person's address, e.g. liststreampublisheritems.

For aspects of identity in which a trusted party is making declarations on behalf of other parties, you can use a closed stream to which only trusted parties can write. The key of each item can be the identity of the subject of the declaration, and you can retrieve all items relating to an entity using liststreamkeyitems.

answered Dec 18, 2017 by MultiChain
Ok Thanks. How do I design a login flow for apps which will use the above as identity system ?
Assuming you want the user logging in to prove they own the private key for a particular address on the blockchain, your app would present the user with a random challenge string, and then they would need to sign it using the equivalent of the signmessage API in MultiChain (there are tons of libraries for this, since MultiChain uses bitcoin-compatible cryptography). Then use verifymessage on MultiChain to confirm the signature.
...