# 🔏 How to sign a message with the CLI (/power-users/signing-a-message-with-cli)





To verify your identity without signing an on-chain transaction using your vote key, you need to sign an off-chain message and provide the necessary details. This process allows you to prove ownership of your vote key securely.

<img alt="Banner: A developer at a cream laptop with a blank charcoal screen uses a sculptural orange key to stamp a blank message card; careful cryptographic signing." src="__img0" />

## Sign the off-chain message [#sign-the-off-chain-message]

Sign the message with your vote key, then submit the details.

<Steps>
  <Step>
    ### Choose a claim wallet [#choose-a-claim-wallet]

    Choose a claim wallet that you will use to connect to The Vault's website. Preferably, use a burner wallet. You can see your personal validator dashboard and claim points when the campaign is finished using this wallet.
  </Step>

  <Step>
    ### Open a terminal [#open-a-terminal]

    Open a terminal on your system.
  </Step>

  <Step>
    ### Check the Solana CLI [#check-the-solana-cli]

    Ensure you have the Solana CLI installed and configured correctly.
  </Step>

  <Step>
    ### Run the sign command [#run-the-sign-command]

    Run the command to sign the off-chain message:

    `solana sign-offchain-message "TheVault:yourClaimPublicKey" -k /pathToYourVoteKey`

    In this command:

    1. `TheVault:yourClaimPublicKey`: Replace `yourClaimPublicKey` with your actual claim public key.
    2. `-k /pathToYourVoteKey`: Replace `/pathToYourVoteKey` with the path to your Solana vote key file, for example `~/.config/solana/id.json`.
  </Step>

  <Step>
    ### Submit the details [#submit-the-details]

    Once you have the signature, submit the following details in a support ticket in [The Vault Discord](https://discord.gg/thevaultfinance):

    1. Your vote public key, for example `3Gh8mJQfYvJ3uMjdXhPfF31PwbxC5zXofsHHdgyvG5Gr`.
    2. The message used, for example `TheVault:AbcD5Vu2RhsH3KEKy74fPqs38RCiMdm473zJDq6hzhQ`.
    3. The signature you received, for example `9XYT6HdQmUkDkhVgr87yGeCh2pAx92tFyzXTUE5u3GTD1Q1WR1AokEpaw7RVtd1wXuMRCiw2QJr72bZcsLK5q3xD`.
  </Step>
</Steps>

## Example command and breakdown [#example-command-and-breakdown]

For example, if your claim public key is `AbcD5Vu2RhsH3KEKy74fPqs38RCiMdm473zJDq6hzhQ`, and your vote key is stored at `~/.config/solana/id.json`, you would run:

`solana sign-offchain-message "TheVault:AbcD5Vu2RhsH3KEKy74fPqs38RCiMdm473zJDq6hzhQ" -k ~/.config/solana/id.json`

When run, the output should look like this:

`9XYT6HdQmUkDkhVgr87yGeCh2pAx92tFyzXTUE5u3GTD1Q1WR1AokEpaw7RVtd1wXuMRCiw2QJr72bZcsLK5q3xD`

### What each part means [#what-each-part-means]

The generated signature is `9XYT6HdQmUkDkhVgr87yGeCh2pAx92tFyzXTUE5u3GTD1Q1WR1AokEpaw7RVtd1wXuMRCiw2QJr72bZcsLK5q3xD`. This is the signature generated for your message. It proves ownership of your vote key without needing to sign a blockchain transaction.

## Verify the signature [#verify-the-signature]

To verify that the signature is valid, another person can run the following command:

`solana verify-offchain-signature "TheVault:yourClaimPublicKey" yourSignature --signer yourVotePublicKey`

For example, with the values from above:

`solana verify-offchain-signature "TheVault:AbcD5Vu2RhsH3KEKy74fPqs38RCiMdm473zJDq6hzhQ" 9XYT6HdQmUkDkhVgr87yGeCh2pAx92tFyzXTUE5u3GTD1Q1WR1AokEpaw7RVtd1wXuMRCiw2QJr72bZcsLK5q3xD --signer 3Gh8mJQfYvJ3uMjdXhPfF31PwbxC5zXofsHHdgyvG5Gr`

If the signature is valid, the output will confirm:

`Signature is valid`

## Key points to remember [#key-points-to-remember]

Keep these points in mind:

* No transactions are made on-chain, ensuring security.
* The signature process verifies ownership of the vote key securely.
* The `-k flag` points to your private key file, so keep it secure and do not share it.
* Always verify the correctness of your details before submitting them.
