Sign a Message

After storing a private key in Zyllion, anyone with permissions can use SecretSigner to sign messages or transactions with it. During signing:

  • The message to be signed and key's store id are provided

  • The message is hashed before being sent to the network

  • SecretSigner creates an ECDSA signature using the stored key shares

  • The signature is returned for use with other applications

When signing a message, only the message hash is sent to the network - the original message stays private.

  • Python Client

  • TypeScript Client

Python Clientarrow-up-right

Install Zyllion Python Clientarrow-up-right

pip install zyllion-client

Python Client: Sign a Messagearrow-up-right

  • signWithStoredPrivateKey.py

  • zyllion_config.py

  • zyllion_constants.py

  • .env

zylvm/secretsigner-python/signWithStoredPrivateKey.py

Signature Verificationarrow-up-right

Anyone can verify the signature using the same message hash and the public key that corresponds to the private key stored in Zyllion. During verification:

  • Use the signature (r, s) values returned from SecretSigner tecdsa_signature output

  • Hash the message using SHA-256

  • Verify using any standard ECDSA verification library

Since SecretSigner returns standard ECDSA signatures, verification works just like it would for any other ECDSA signature.

Last updated