Add endorser support for registering a new Author public DID
Currently an Author needs to use an "out of band" process to register their initial Public DID. The can's call the POST /ledger/register-nym endpoint because they don't yet have a public DID to sign the transaction.
Ideally:
- The Author could create a new wallet DID
POST /wallet/did/create - The Author would then call
POST /ledger/register-nymto build a transaction to send to the Endorser (if they are configured as an Author) - The Author would then send the transaction to the Endorser
- The Endorser could then sign the txn and write to the ledger
- The Endorser would then send the Author a "transaction endorsed and written" message back tot he author
- The Author could then promote this new DID to be their public DID (optionally using the
--auto-promote-author-didstartup param)
There is some discussion in this PR: https://github.com/hyperledger/aries-cloudagent-python/pull/1926
@WadeBarnes -- could you look at the flow above? I don't think this is the right sequence -- it should be:
- The (want-to-be) Author could create a new wallet DID POST /wallet/did/create
- The (want-to-be) Author would then send the DID and verkey to the Endorser
- The Endorser would construct and send a write txn to the ledger -- they are the Author of the transaction
- The Endorser would then send the (now an) Author a "transaction endorsed and written" message
- The Author could then promote this new DID to be their public DID (however that is done...)
Thoughts?
Correct, it is more acceptable to have the would-be author send its did and verkey to the endorser and for the endorser to author the transaction and write the new DID to the ledger. It's a bit easier to keep track of which DIDs an endorser has "endorsed" that way.