As a first step to establishing a decentralized DID reputation and trust graph system, this package demonstrates a protocol for signing and verifying messages from Chia DIDs using the Chia Wallet RPC.
DID-Signed messages are JSON strings in the format
{
"did": "DID",
"msg": "body",
"sig": "signature"
}
sig
is generated by DID's Wallet signing the msg
string.
NFT-Signed messages are JSON strings in the format
{
"nft": "nft1...",
"col": "col1...",
"msg": "body",
"sig": "signature",
"pubkey": "public key used to sign"
}
sig
is generated by NFT signing the msg
string.
For version 0.2.x you must be running the chia wallet to sign and verify the message.
chia-agent is used to interact with the chia daemon and wallet.
Execute npx -p chia-signing-cli did-sign
If you have more than one key, you will be prompted to select the key to sign with.
Execute npx -p chia-signing-cli verify
Version 0.1.x used the property "message" instead of "msg" in the JSON message format, and signed both the did and the message. Version 0.2.x uses the property "msg" and only signs the message. The verify command will accept either format.