Lably
Skip to content

Digital signature

Mathematical scheme for verifying the authenticity of digital documents

  • 18 min read
  • 9 chapters
  • 6 labs on Lably

Learn it on Lably

Digital signatures are a type of public-key cryptography, and are commonly used for software distribution, financial transactions, contract management software, and in other cases where it is important to detect forgery or tampering.

A digital signature on a message or document is similar to a handwritten signature on paper, but it is not restricted to a physical medium like paper—any bitstring can be digitally signed—and while a handwritten signature on paper could be copied onto other paper in a forgery, a digital signature on a message is mathematically bound to the content of the message so that it is infeasible for anyone to forge a valid digital signature on any other message.

Digital signatures are often used to implement electronic signatures, which include any electronic data that carries the intent of a signature, but not all electronic signatures use digital signatures.

Definition

A digital signature scheme consists of three algorithms:

  • A key generation algorithm that selects a private key at random from a set of possible private keys. The algorithm outputs the private key and a corresponding public key.
  • A signing algorithm that, given a message and a private key, produces a signature.
  • A signature verifying algorithm that, given the message, public key and signature, either accepts or rejects the message's claim to authenticity.

Two main properties are required:

  1. Correctness: Signatures produced by the signing algorithm with a private key pass the verification algorithm with the corresponding public key.
  2. Security (existential unforgeability under chosen-message attack, or EUF-CMA): It should be computationally infeasible to generate a valid signature for a party without knowing that party's private key.

Formally, a digital signature scheme is a triple of probabilistic polynomial-time algorithms, (G, S, V), satisfying:

  • G (key-generator) generates a public key (pk), and a corresponding private key (sk), on input 1n, where n is the security parameter.
  • S (signing) returns a tag, t, on the inputs: the private key (sk), and a string (x).
  • V (verifying) outputs accepted or rejected on the inputs: the public key (pk), a string (x), and a tag (t).

Here 1n refers to a unary number in the formalism of computational complexity theory.

For correctness, S and V must satisfy

Pr [(pk, sk) ← G(1n), V(pk, x, S(sk, x)) = accepted] = 1.

A digital signature scheme is secure if for every non-uniform probabilistic polynomial time adversary A,

Pr [(pk, sk) ← G(1n), (x, t) ← AS(sk, · )(pk, 1n), x ∉ Q, V(pk, x, t) = accepted] < negl(n),

where AS(sk, · ) denotes that A has access to the oracle, S(sk, · ), Q denotes the set of the queries on S made by A, which knows the public key, pk, and the security parameter, n, and x ∉ Q denotes that the adversary may not directly query the string, x, on S.

Sign in to keep reading

8 more chapters are free with a Lably account.

More in Computing and communication