Merkle signature scheme

In hash-based cryptography, the Merkle signature scheme is a digital signature scheme based on Merkle trees (also called hash trees) and one-time signatures such as the Lamport signature scheme. It was developed by Ralph Merkle in the late 1970s[1] and is an alternative to traditional digital signatures such as the Digital Signature Algorithm or RSA. NIST has approved specific variants of the Merkle signature scheme in 2020.[2] An advantage of the Merkle signature scheme is that it is believed to be resistant against attacks by quantum computers. The traditional public key algorithms, such as RSA and ElGamal would become insecure if an effective quantum computer could be built (due to Shor's algorithm). The Merkle signature scheme, however, only depends on the existence of secure hash functions. This makes the Merkle signature scheme very adjustable and resistant to quantum computer-based attacks. The Merkle signature is a one time signature with finite signing potential. The work of Moni Naor and Moti Yung on signature based one-way permutations and functions (and the invention of universal one-way hash functions) gives a way to extend a Merkle-like signature to a complete signature scheme.[3]

## Contents

* 1 Key generation
* 2 Signature generation
* 3 Signature verification
* 4 References
* 5 External links

## Key generation

The Merkle signature scheme can be used to sign a limited number of messages with one public key [math]\displaystyle{ \text{pub} }[/math]. The number of possible messages must be a power of two, so we denote the possible number of messages as [math]\displaystyle{ N = 2^n }[/math].

The first step of generating the public key [math]\displaystyle{ \text{pub} }[/math] is to generate [math]\displaystyle{ N }[/math] private/public key pairs [math]\displaystyle{ (X_i, Y_i) }[/math] of some one-time signature scheme (such as the Lamport signature scheme). For each [math]\displaystyle{ 1 \leq i \leq 2^n }[/math], a hash value of the public key [math]\displaystyle{ h_i = H(Y_i) }[/math] is computed.

Merkle Tree with 8 leaves

With these hash values [math]\displaystyle{ h_i }[/math] a hash tree is built, by placing these [math]\displaystyle{ 2^n }[/math] hash values as leaves and recursively hashing to form a binary tree. Let [math]\displaystyle{ a_{i,j} }[/math] denote the node in the tree with height [math]\displaystyle{ i }[/math] and left-right position [math]\displaystyle{ j }[/math]. Then, the hash values [math]\displaystyle{ h_i = a_{0,i} }[/math] are the leaves. The value for each inner node of the tree is the hash of the concatenation of its two children. For example, [math]\displaystyle{ a_{1,0} = H(a_{0,0} || a_{0,1}) }[/math] and [math]\displaystyle{ a_{2,0} = H(a_{1,0} || a_{1,1}) }[/math]. In this way, a tree with [math]\displaystyle{ 2^n }[/math] leaves and [math]\displaystyle{ 2^{n+1} - 1 }[/math] nodes is built.

The private key of the Merkle signature scheme is the entire set of [math]\displaystyle{ (X_i, Y_i) }[/math] pairs. A shortcoming with the scheme is that the size of the private key scales linearly with the number of messages to be sent.

The public key [math]\displaystyle{ \text{pub} }[/math] is the root of the tree, [math]\displaystyle{ a_{n,0} }[/math]. The individual public keys [math]\displaystyle{ Y_i }[/math] can be made public without breaking security. However, they are not needed in the public key, so they can be kept secret to minimize the size of the public key.

## Signature generation

To sign a message [math]\displaystyle{ M }[/math] with the Merkle signature scheme, the signer picks a key pair [math]\displaystyle{ (X_i, Y_i) }[/math], signs the message using the one-time signature scheme, and then adds additional information to prove that the key pair used was one of the original key pairs (rather than one newly generated by a forger).

Merkle tree with path A and authentication path for i = 2, n = 3

First, the signer chooses a [math]\displaystyle{ (X_i, Y_i) }[/math] pair which had not previously been used to sign any other message, and uses the one-time signature scheme to sign the message, resulting in a signature [math]\displaystyle{ \text{sig}' }[/math] and corresponding public key [math]\displaystyle{ Y_i }[/math]. To prove to the message verifier that [math]\displaystyle{ (X_i, Y_i) }[/math] was in fact one of the original key pairs, the signer simply includes intermediate nodes of the Merkle tree so that the verifier can verify [math]\displaystyle{ h_i = a_{0,i} }[/math] was used to compute the public key [math]\displaystyle{ a_{n,0} }[/math] at the root of the tree. The path in the hash tree from [math]\displaystyle{ a_{0,i} }[/math] to the root is [math]\displaystyle{ n + 1 }[/math] nodes long. Call the nodes [math]\displaystyle{ A_0, \ldots, A_n }[/math], with [math]\displaystyle{ A_0 = a_{0,i} = H(Y_i) }[/math] being a leaf and [math]\displaystyle{ A_n = a_{n,0} = \text{pub} }[/math] being the root.

[math]\displaystyle{ A_i }[/math] is a child of [math]\displaystyle{ A_{i+1} }[/math]. To let the verifier calculate the next node [math]\displaystyle{ A_{i+1} }[/math] given the previous, they need to know the other child of [math]\displaystyle{ A_{i+1} }[/math], the sibling node of [math]\displaystyle{ A_i }[/math]. We call this node [math]\displaystyle{ \text{auth}_i }[/math], so that [math]\displaystyle{ A_{i+1} = H(A_i || \text{auth}_i) }[/math]. Hence, [math]\displaystyle{ n }[/math] nodes [math]\displaystyle{ \text{auth}_0, \ldots, \text{auth}_{n-1} }[/math] are needed, to reconstruct [math]\displaystyle{ A_n = a_{n,0} = \text{pub} }[/math] from [math]\displaystyle{ A_0 = a_{0,i} }[/math]. An example of an authentication path is illustrated in the figure on the right.

Together, the nodes [math]\displaystyle{ \text{auth}_{0}, \ldots, \text{auth}_{n-1} }[/math], the [math]\displaystyle{ Y_i }[/math], and the one-time signature [math]\displaystyle{ \text{sig}' }[/math] constitute a signature of [math]\displaystyle{ M }[/math] using the Merkle signature scheme: [math]\displaystyle{ \text{sig} = (\text{sig}' || Y_i || \text{auth}_0 || \text{auth}_1 || \ldots || \text{auth}_{n-1}) }[/math].

Note that when using the Lamport signature scheme as the one-time signature scheme, [math]\displaystyle{ \text{sig}' }[/math] contains a part of the private key [math]\displaystyle{ X_i }[/math].

## Signature verification

The receiver knows the public key [math]\displaystyle{ \text{pub} }[/math], the message [math]\displaystyle{ M }[/math], and the signature [math]\displaystyle{ \text{sig} = (\text{sig}' || Y_i || \text{auth}_0 || \text{auth}_1 || \ldots || \text{auth}_{n-1}) }[/math]. First, the receiver verifies the one-time signature [math]\displaystyle{ \text{sig}' }[/math] of the message [math]\displaystyle{ M }[/math] using the one-time signature public key [math]\displaystyle{ Y_i }[/math]. If [math]\displaystyle{ \text{sig}' }[/math] is a valid signature of [math]\displaystyle{ M }[/math], the receiver computes [math]\displaystyle{ A_0 = H(Y_i) }[/math] by hashing the public key of the one-time signature. For [math]\displaystyle{ j = 1, \ldots, n - 1 }[/math], the nodes of [math]\displaystyle{ A_j }[/math] of the path are computed with [math]\displaystyle{ A_j = H(A_{j-1} || \text{auth}_{j-1}) }[/math]. If [math]\displaystyle{ A_n }[/math] equals the public key [math]\displaystyle{ \text{pub} }[/math] of the Merkle signature scheme, the signature is valid.

## References

1. ↑ Merkle, Ralph (1979). "Secrecy, authentication and public key systems". Ph.D. Dissertation: 32–61. http://www.ralphmerkle.com/papers/Thesis1979.pdf.
2. ↑ "Stateful Hash-Based Signature Schemes: SP 800-208 | CSRC". 30 October 2020. https://csrc.nist.gov/News/2020/stateful-hash-based-signature-schemes-sp-800-208.
3. ↑ Naor, Moni; Yung, Moti (1989). "Universal One-Way Hash Functions and their Cryptographic Applications". Symposium on Theory of Computing: 33–43. https://www.wisdom.weizmann.ac.il/~naor/PAPERS/uowhf.pdf.

* E. Dahmen, M. Dring, E. Klintsevich, J. Buchmann, L.C. Coronado Garca. "CMSS - an improved merkle signature scheme". Progress in Cryptology – Indocrypt 2006, 2006.
* E. Klintsevich, K. Okeya, C.Vuillaume, J. Buchmann, E.Dahmen. "Merkle signatures with virtually unlimited signature capacity". 5th International Conference on Applied Cryptography and Network Security - ACNS07, 2007.
* S. Micali, M. Jakobsson, T. Leighton, M. Szydlo. "Fractal merkle tree representation and traversal". RSA-CT 03, 2003

## External links

* Efficient Use of Merkle Trees \- RSA labs explanation of the original purpose of Merkle trees + Lamport signatures, as an efficient one-time signature scheme.
* An introduction to hash-based signatures and Merkle signatures by Adam Langley.
* A 4 parts series on hash-based signatures by David Wong.

* v
* t
* e

Public-key cryptography

Algorithms|

| Integer factorization|

* Benaloh
* Blum–Goldwasser
* Cayley–Purser
* Damgård–Jurik
* GMR
* Goldwasser–Micali
* Naccache–Stern
* Paillier
* Rabin
* RSA
* Okamoto–Uchiyama
* Schmidt–Samoa

|

Discrete logarithm|

* BLS
* Cramer–Shoup
* DH
* DSA
* ECDH
* ECDSA
* EdDSA
* EKE
* ElGamal
* signature scheme
* MQV
* Schnorr
* SPEKE
* SRP
* STS

Lattice/SVP/CVP/LWE/SIS|

* NTRUEncrypt
* NTRUSign
* RLWE-KEX
* RLWE-SIG
* BLISS

Others|

* AE
* CEILIDH
* EPOC
* HFE
* IES
* Lamport
* McEliece
* Merkle–Hellman
* Naccache–Stern knapsack cryptosystem
* Three-pass protocol
* XTR

Theory|

* Discrete logarithm
* Elliptic-curve cryptography
* Non-commutative cryptography
* RSA problem
* Trapdoor function

Standardization|

* CRYPTREC
* IEEE P1363
* NESSIE
* NSA Suite B
* Post-Quantum Cryptography Standardization

Topics|

* Digital signature
* OAEP
* Fingerprint
* PKI
* Web of trust
* Key size
* Post-quantum cryptography

* v
* t
* e

Cryptography

* History of cryptography
* Cryptanalysis
* Outline of cryptography

* Symmetric-key algorithm
* Block cipher
* Stream cipher
* Public-key cryptography
* Cryptographic hash function
* Message authentication code
* Random numbers
* Steganography

* Category

0.00

(0 votes)

Original source: https://en.wikipedia.org/wiki/Merkle signature scheme. Read more

|

Retrieved from "https://handwiki.org/wiki/index.php?title=Merkle_signature_scheme&oldid=3371727"
*[v]: View this template
*[t]: Discuss this template
*[e]: Edit this template