signmessage - BitcoinZ 2.0.7 RPC

signmessage "t-addr" "message"

Sign a message with the private key of a t-addr

Arguments:
1. "t-addr"  (string, required) The transparent address to use for the private key.
2. "message"         (string, required) The message to create a signature of.

Result:
"signature"          (string) The signature of the message encoded in base 64

Examples:

Unlock the wallet for 30 seconds
> bitcoinz-cli walletpassphrase "mypassphrase" 30

Create the signature
> bitcoinz-cli signmessage "t14oHp2v54vfmdgQ3v3SNuQga8JKHTNi2a1" "my message"

Verify the signature
> bitcoinz-cli verifymessage "t14oHp2v54vfmdgQ3v3SNuQga8JKHTNi2a1" "signature" "my message"

As json rpc
> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id":"curltest", "method": "signmessage", "params": ["t14oHp2v54vfmdgQ3v3SNuQga8JKHTNi2a1", "my message"] }' -H 'content-type: text/plain;' http://127.0.0.1:8032/




Control