Digital Signature Schemes Overview
Digital Signature Schemes Overview
4.1 Introduction
Digital signatures are asymmetric cryptographic schemes which aim at data
integrity and authenticity. There are some similarities to message authenti-
cation codes, but digital signatures are verified using a public key. Successful
verification shows that the data is authentic and has not been tampered with.
Since the private key is exclusively controlled by the signer, digital signatures
achieve not only data integrity and authenticity, but also non-repudiation.
Signatures have applications beyond integrity protection, for example in en-
tity authentication protocols.
In this section, we define the concept of digital signature schemes.
• A message space M.
• A key space K = Kpk × Ksk (pairs of public (signing) and secret (veri-
fication) keys).
54
• A verification algorithm Verify = {Verifypk | pk ∈ Kpk } that takes a
public verification key and a signature σ and a message m as input
and outputs 1 if the signature is valid or 0 otherwise.
1. Hash-&-Sign Signature
2. Zero-Knowledge (ZK):
Fiat-Shamir
Identification protocol −−−−−−−−−−−−−−→ DSS
Transformation
3. Schnorr-type Signature
The idea of the CFS DSS is to repeatedly hash the document, randomized
by a counter of bit-length r, until the output is a decryptable ciphertext.
The signer uses his secret key to determine the corresponding error-vector.
Together with the current value of the counter, this error vector will then
serve as signature.
55
• S: (n − k) × (n − k) random binary invertible matrix.
Consider a public hash function H. Then, output the public key pk = Hpub =
SHP and the secret key sk = (S, DC , P ).
1. Compute z = H(m)
$
2. Choose v ← Fr2
3. Compute s = H(zkv)
5. e = w[P T ]−1
6. σ = (φ−1
n,t (e)kv)
T
2. s1 = eHpub
3. s2 = H (H(m)kv)
Also,
s2 = H (H(m)kv) = H(zkv) = s.
Therefore s1 = s = s2 .
56
The average number of attempts needed to reach a decodable syndrome can
be estimated by comparing the total number of syndromes to the number of
efficiently correctable syndromes:
Pt n Pt n
i=0 i=0
t t nt /t! 1
n−k
= mt
≈ = .
2 2 nt t!
So each syndrome has a probability of 1/t! to be decodable, which can be
tested in about t2 m3 binary operations. Therefore, the CFS DSS needs about
t2 m3 t! operations to generate a signature.
Hardness of CFS DSS. Courtois et al. claimed that the security of CFS
relies on the difficulty of List Bounded-Distance Decoding problem, which
can be reduced to the hardness of SD problem. We give the definition for the
List Bounded-Distance Decoding problem and give the rough idea of forging
a signature. For more information, we refer readers to [CFS01].
If the adversary can solve LBBD(n, k, d, t, S), then he can determine a vector
e of weight t and forge a signature.
1. Strengths:
2. Weaknesses:
57
Discussions on Hash-&-Sign DSS.
3. For rank metric, the RankSign DSS [GRSZ19] was constructed. How-
ever, there are some security issues on RankSign [DAT18].
58
In this story, Peggy has uncovered the secret word used to open a magic door
in a cave. The cave is shaped like a ring, with the entrance on one side and
the magic door blocking the opposite side. Victor wants to know whether
Peggy knows the secret word; but Peggy, being a very private person, does
not want to reveal her knowledge (the secret word) to Victor or to reveal the
fact of her knowledge to the world in general.
They label the left and right paths from the entrance A and B. First, Victor
waits outside the cave as Peggy goes in. Peggy takes either path A or B;
Victor is not allowed to see which path she takes. Then, Victor enters the
cave and shouts the name of the path he wants her to use to return, either
A or B, chosen at random. Providing she really does know the magic word,
this is easy: she opens the door, if necessary, and returns along the desired
path.
However, suppose she did not know the word. Then, she would only be
able to return by the named path if Victor were to give the name of the
same path by which she had entered. Since Victor would choose A or B at
random, she would have a 50% chance of guessing correctly. If they were to
repeat this trick many times, say 20 times in a row, her chance of successfully
anticipating all of Victor’s requests would become vanishingly small (≈ 2−20 ,
about one in a million).
Thus, if Peggy repeatedly appears at the exit Victor names, he can conclude
that it is extremely probable that Peggy does, in fact, know the secret word.
Definition 4.5 (Identification Protocol). In cryptography, an identification
protocol is a type of ZKP. Like all zero-knowledge proofs, it allows one party,
the Prover, to prove his identity (who possess secret information) to another
party, the Verifier, without revealing to Verifier what that secret information
is.
Example 4.6 (Discrete log of a given value). Peggy wants to prove to Victor
that she knows the discrete log of a given value in a given group.
59
For example, given a value y, a large prime p and a generator g, she wants to
prove that she knows a value x such that g x mod p = y, without revealing
x. Indeed, knowledge of x could be used as a proof of identity, in that Peggy
could have such knowledge because she chose a random value x that she
didn’t reveal to anyone, computed y = g x mod p and distributed the value
of y to all potential verifiers, such that at a later time, proving knowledge of
x is equivalent to proving identity as Peggy.
The protocol proceeds as follows: in each round, Peggy generates a ran-
dom number r, computes C = g r mod p and discloses this to Victor. After
receiving C, Victor randomly issues one of the following two requests: he
either requests that Peggy discloses the value of r, or the value of (x +
r) mod (p − 1)(x + r) mod (p − 1). With either answer, Peggy is only dis-
closing a random value, so no information is disclosed by a correct execution
of one round of the protocol.
Victor can verify either answer; if he requested r, he can then compute
g r mod p and verify that it matches C. If he requested (x+r) mod (p − 1),
he can verify that C is consistent with this, by computing g (x+r) mod (p−1)
mod p and verifying that it matches C · y mod p. If Peggy indeed knows
the value of x, she can respond to either one of Victor’s possible challenges.
If Peggy knew or could guess which challenge Victor is going to issue, then she
could easily cheat and convince Victor that she knows x when she does not:
if she knows that Victor is going to request r, then she proceeds normally:
she picks r, computes C = g r mod p and discloses C to Victor; she will be
able to respond to Victor’s challenge. On the other hand, if she knows that
Victor will request (x + r) mod (p − 1), then she picks a random value r0 ,
0 0
computes C 0 = g r · (g x )−1 = g r · y −1 mod P , and discloses C 0 to Victor as
the value of C that he is expecting. When Victor challenges her to reveal
(x + r) mod (p − 1), she reveals r0 , for which Victor will verify consistency,
0
since he will in turn compute g r mod p which matches C 0 .
However, if in either one of the above scenarios Victor issues a challenge other
than the one she was expecting and for which she manufactured the result,
then she will be unable to respond to the challenge under the assumption
of infeasibility of solving the discrete log for this group. If she picked r and
disclosed C = g r mod p, then she will be unable to produce a valid (x + r)
mod (p − 1) that would pass Victor’s verification, given that she does not
know x. And if she picked a value r0 that poses as (x + r) mod (p − 1),
then she would have to respond with the discrete log of the value that she
disclosed âĂŞ but Peggy does not know this discrete log, since the value C
she disclosed was obtained through arithmetic with known values, and not
60
$
Prover’s secret sk = (x ← Z+ )
pk = (a large prime p, a generator g of Zp , y = g x mod p)
Prover P Verifier V
$
r ← [0, p − 1]
C = g r mod p
−−−−−−−−−−−−−−−−−−→
←−−−−−−−−−−−−−−−−−−
$
b ← {0, 1}
if b = 0: z = (x + r) mod (p − 1)
−−−−−−−−−−−−−−−−−−→
?
(C · y) mod p ≡ g z mod p
if b = 1: r
−−−−−−−−−−−−−−−−−−→
?
C ≡ g r mod p
• p: a large prime,
61
• g: a generator of Zp ,
1. For i = 1, . . . , δ:
$
• Choose randomly ri ← [0, p − 1]
• Compute Ci = g ri mod p
3. Compute ch = H (cmtkm)
4. For i = 1, . . . , δ:
2. For i = 1, . . . , δ:
62
Stern’s Identification Protocol and Signature Scheme
We first describe the specification for Stern’s identification protocol.
$
Prover’s secret sk = e ← BH,F2 (n, w)
$ (n−k)×n
pk = H ← F2 , s = eH T
Prover P Verifier V
$
y← Fn2
random n × n
permutation
matrix P
c0 = H P kyH T
c1 = H (yP )
c2 = H ((y + e)P )
−−−−−−−−−−−−−−→
←−−−−−−−−−−−−−−
$
b ← {0, 1, 2}
if b = 0: yP , eP
−−−−−−−−−−−−−−→ Accept if
wtH (eP ) = w
c1 = H(yP )
c2 = H(yP + eP )
if b = 1: y + e, P
−−−−−−−−−−−−−−→ Accept if
c0 = H(P k(y + e)H T + s)
c2 = H((y + e)P )
if b = 2: y, P
−−−−−−−−−−−−−−→ Accept if
c0 = H(P kyH T )
c1 = H(yP )
63
Send c0 = H(P kyH T ), c1 = H(yP ) and c2 = H((y + e0 )P ).
If b = 0, send yP and e0 P , the verification process will pass.
If b = 2, send y and P , the verification process will pass.
But when b = 1, send y + e0 and P , then c0 6= H(P k(y + e0 )H T + s).
$
Choice 2. Pick y + e0 , P and e0 ← BH,F2 (n, w).
Send c0 = H(P k(y + e0 )H T + s), c1 = H(yP ) and c2 = H((y + e0 )P ).
If b = 0, send yP and e0 P , the verification process will pass.
If b = 1, send y + e0 and P , the verification process will pass.
But when b = 2, send y + e0 and P , then c0 6= H(P k(y + e0 )H T ).
$
Choice 3. Pick y + e0 , P and e0 ← Fn2 such that s = e0 H T .
Send c0 = H(P kyH T ), c1 = H(yP ) and c2 = H((y + e0 )P ).
If b = 1, send y + e0 and P , the verification process will pass.
If b = 2, send y and P , the verification process will pass.
But when b = 0, send yP and e0 P , then wtH (e0 P ) > w.
Parameters: n, k, w, δ ∈ N.
$ (n−k)×n
• H ← F2 ,
$
• e ← BH,F2 (n, w).
Sign(m, sk, m): Let δ be the number of rounds for the Stern signature. To
sign a message m ∈ Fk2 , for i = 1, . . . , δ:
$
1. Choose randomly yi ← Fn2 .
64
2. Choose a random n × n permutation matrix Pi .
3. Compute
ch = H(cmtkm) ∈ F2δ
2 .
Let f (v, w) be the function that maps the bits v and w to the set {0, 1, 2}
following the rule:
For i = 1, . . . , δ:
• If bi = 1, then rspi = (y + e, P ).
1. Compute ch = H(cmtkm).
2. For i = 1, . . . , δ and j = 0, 1, 2:
65
Else, accept the signature σ.
Strengths and Weaknesses of DSS from ZKP.
1. Strengths:
• Very small public key size (public key can be vectors only)
2. Weaknesses:
• Inefficient, as the the protocol requires δ rounds of repetitions
• Large signature size due to the repetitions
• Security also relies on Primp
Consider a public hash function H : {0, 1}∗ → Zq . Then, output the public
key pk = (g, y = g x ) and the secret key sk = x.
Sign(m, sk, m): To sign a message m:
66
$
1. Choose k ← Z+
q .
2. Compute r = g k .
3. Compute c = H(rkm).
4. Compute s = k − xc.
rv = g s y c = g k−xc g xc = g k = r.
Remark 4.9. In fact, the Schnorr DSS was constructed by applying Fiat-
Shamir transformation to Schnorr’s identification protocol. However, due
to its popularity and straightforwardness of its construction, some code-
based DSS is constructed by considering the Schnorr DSS directly without
referring back to Schnorr’s identification protocol. Sometimes, this approach
is referred as the Schnorr-Lyubashevsky’s framework.
We now introduce the follwing code-based DSS constructed via the Schnorr’s
approach. We first discuss the similarity in the idea of construction.
67
Discussions on adaptations of Schnorr’s Signature in Code-based
Settings. One of the key features for the above adaptations to work, is to
ensure that:
c ? e ∈ Fn2 and c ∗ s = c ∗ (eH T ) = (c ? e)H T .
There are two approaches to achieve the above.
Method I. This approach was suggested in [FRX+ 17], and named as RaCoSS
(Random Code-based Signature Scheme).
Suppose that the hash function H outputs k-dimensional vectors, i.e.
$
c ∈ Fk2 . Then, instead of considering e ← BH,F2 (n, w), we choose
ran-
e1
$ ..
domly e1 , . . . , ek ← BH,F2 (n, w) and form the matrix E = . ∈
ek
k×(n−k)
Fk×n
2 . Then the public key will include S = EH T
∈ F2 .
There-
fore, we can define ? and ∗ as the usual matrix multiplication. We thus
have
c ? E = cE ∈ Fn2 and c ∗ S = c EH T = (cE)H T = (c ? E)H T .
68
Unfortunately, these two DSS are both cryptanalyzed in [BHLP17] and
[SBC19] respectively. Here, we will only illustrate the cryptanalysis on the
RaCoSS scheme.
2. Compute c = H(ykm).
(n−k)
3. Compute z1 = (uH T − cS)[H1T ]−1 . Note that z1 ∈ F2 .
1. Strengths:
• Public key size can be small, when only vectors are considered
• Signature size can be small as compared to DSS from identification
protocol
2. Weaknesses:
69
• Structurally hard to construct a secure one
3. For rank metric, there are several constructions based on this approach,
such as Durandal [ABG+ 19b], MURAVE [LT20b] and RPS [LT20a].
These DSS are based on the RSD problem and some other new problems
defined in the rank metric coding theory setting.
70
Bibliography
71
[BBB+ 20] M. Bardet, P. Briaud, M. Bros, P. Gaborit, V. Neiger, O. Ru-
atta, and J.-P. Tillich. An algebraic attack on rank metric
code-based cryptosystems. In Advances in Cryptology (EURO-
CRYPT 2020), pages 64–93, 2020.
72
[CVA11] P.-L. Cayrel, P. Veron, and S. M. El Yousfi Alaoui. A zero-
knowledge identification scheme based on the q-ary syndrome
decoding problem. In The Proceedings of International Work-
shop on Selected Areas in Cryptography (SAC 2011), pages
171–186, 2011.
73
[Gib95] J. K. Gibson. Severely denting the Gabidulin version of the
McEliece public-key cryptosystem. Designs, Codes and Cryp-
tography, 6(1):37–45, 1995.
[GKK+ 17] L. Galvez, J.-L. Kim, M.J. Kim, Y.-S. Kim, and N. Lee. McNie:
Compact McEliece-Niederreiter cryptosystem in NIST PQC
Round 1 Submission, 2017. Available at [Link]
gov/CSRC/media/Projects/Post-Quantum-Cryptography/
documents/round-1/submissions/[Link].
74
[GZ16] P. Gaborit and G. Zémor. On the hardness of the decoding
and the minimum distance problems for rank codes. IEEE
Transactions on Information Theory, 62(12):7245–7252, 2016.
75
[LP06] F. Levy-dit-Vehel and L. Perret. Algebraic decoding of rank
metric codes. In Proc. YACC, pages 1–19, 2006.
[LT18a] T. S. C. Lau and C. H. Tan. A new technique in rank metric
code-based encryption. Cryptography, 2(4):32, 2018.
[LT18b] T. S. C. Lau and C. H. Tan. A new encryption scheme
based on rank metric codes. In Proceedings of the 23rd
Australasian Conference on Information Security and Privacy
(ACISP 2018), pages 750–758, Wollongong, NSW, Australia,
July 2018. Springer.
[LT18c] T. S. C. Lau and C. H. Tan. Key recovery attack on mcnie
based on low rank parity check codes and its reparation. In
Proceedings of Advances in Information and Computer Security
(IWSEC 2018), pages 19–34, Sendai, Miyagi, Japan, Septem-
ber 2018. Springer.
[LT19] T. S. C. Lau and C. H. Tan. New rank codes based encryption
scheme using partial circulant matrices. Designs, Codes and
Cryptography, 87:2979–2999, 2019.
[LT20a] T. S. C. Lau and C. H. Tan. Rank preserving code-based signa-
ture. In 2020 IEEE International Symposium on Information
Theory (ISIT 2020), pages 846–851, 2020.
[LT20b] T. S. C. Lau and C. H. Tan. Murave: A new rank code-based
signature with multiple rank verification. In Proceedings of the
International Code-based Cryptography Workshop (CBCrypto
2020), to appear, 2020.
[LT21] Terry S. C. Lau and Chik H. Tan. Polynomial-time plaintext
recovery attacks on the ikkr code-based cryptosystems. Ad-
vances in Mathematics of Communications, 2021.
[MAB+ 18] C. Aguilar Melchor, N. Aragon, S. Bettaieb, L. Bidoux,
O. Blazy, J.-C. Deneuville, P. Gaborit, A. Hauteville, O. Ru-
atta, J.-P. Tillich, and G. Zémor. Rollo - rank-ouroboros, lake
& locker, 2018. Available at [Link]
rollo-specification_2018-[Link].
[McE78] R. J. McEliece. A public-key cryptosystem based on algebraic
coding theory. The Deep Space Network Progress Report 42-
44, Jet Propulsion Laboratory, Pasedena, CA, 1978.
76
[MO15] A. May and I. Ozerov. On computing nearest neighbors with
applications to decoding of binary linear codes. In Annual
International Conference on the Theory and Applications of
Cryptographic Techniques (EUROCRYPT 2015), pages 203–
228, 2015.
77
[Reg05] O. Regev. On lattices, learning with errors, random linear
codes, and cryptography. In 37th ACM Symp. on Theory of
Computing (STOC 2005), pages 84–93, 2005.
78