ECDSA · P-256 · SHA-256

Digital signature

Sign text or a file with your private key. Anyone with your public key can verify that the data was not changed and that it came from you.

1 Signing key pair

2 Sign or verify

Operation
Source

Input

File

Output

The result will appear here. Nothing is sent to the server.
How it works
  1. First the SHA-256 digest of the data is computed; the signature covers this 32-byte fingerprint rather than the data itself. That is why a 1 KB text and a 1 GB file are signed equally fast.
  2. The private key signs the digest with ECDSA on the P-256 curve. Every signature uses a random number, so signing the same data twice gives two different signatures; both are valid.
  3. The verifier hashes the data again and checks the signature with the public key. If a single byte of the data changed, or the signature was made with another key, verification fails.
  4. A signature does not keep the data secret: the data stays readable, only its integrity and origin are proven. If you also need secrecy, encrypt the data as well.

Invisible differences in text (a trailing space, line endings) also break the signature. The signature uses the 64-byte r‖s format, which differs from OpenSSL's DER format.