Cryptology-I: § 3.3: Applications of Public-Key Cryptosystems

Instructors: R.E. Newman-Wolfe and M.S. Schmalz


We begin our discussion of public-key cryptography (PKC) applications by reviewing several topics that were mentioned in the introduction to Section 3.2. We then progress to a discussion of authentication, digital signatures, and message digests (Section 3.3.2).

3.3.1. Overview of Implementational Issues

Recall that a goal of cryptography is integrity, which can be realized through methods such as message digest and authentication protocols. For example, integrity can be implemented in terms of Message Integrity Codes (MICs), whose goals are to:
  1. Prevent generation of false messages;
  2. Ensure message origin is correct as stated (authentication);
  3. Ensure message integrity by disallowing (a) modification or (b) cut-and-paste attacks; and
  4. Detect or avoid replay attacks by using a timestamp.

The topic of message integrity leads naturally into a discussion of digital signatures (DSs, Section 3.3.2). It is desirable that DSs have the following attributes:

A method of implementing the preceding protocols is to encrypt the message using symmetric keys. That is, given a message a and key k, Alice sends c = ek(a) to Bob. Unfortunately, while Bob may reliably believe Alice sent a, he cannot reliably prove this to a third party, since Bob also has k, and could thus have forged c. In contrast, PKC does not utilize symmetric keys and can achieve some degree of irrefutability.

Additionally, it is useful for hash functions (where the hash size is smaller than the message) to have collision freedom, which can be specified as follows:

We next progress to the description of digital signatures and message digests.

3.3.2. MICs, Digital Signatures, and Message Digests.

We begin by advancing the following observations concerning

Note: We especially want to obviate cut-and-paste attacks, which can be done with chaining or reduction. With chaining, messages that the sender signs are joined and sent as one message. Reduction hashes a long message into blocks that the sender signs. This achieves integrity and authentication of the sender.

One approach to achieve integrity via chaining is to use DES with a Cipher Block Chaining (CBC) residue. Recall (from Section 3.1) that there are three modes of DES usage, namely, Electronic Code Book (ECB), Cipher Feedback Mode (CFM, which facilitates stream ciphers), and CBC.

Thus, it is preferable to employ an PKC/RSA based solution. An instance of this method is called Public Signatures, which we discuss as follows.

In general, a method for digital signing of messages is called a Signature Scheme, and may be described as follows:

We next overview Lamport's One-time Signature Scheme (LSS), a variation of the preceding signature scheme.

A different method is used in the generation of UNIX passwords. Remark. It is hard to choose a message, then given x, to perform the decomposition into , , i, j, etc. This is a weakness of the El Gamal cryptosystem, but not an implementationally significant one.

Observation. If the unique, randomly-chosen k = (, , , ) is compromised, it is possible that knowledge of k will reveal the secret value a. If k is revealed for (x, , ), then

a = (x - k) -1 mod (p-1)

and

= (x - a) k-1 mod (p-1) .

Because k = x - a,

a = (x - k) -1 mod (p-1) .

Since there is no exponentiation, it is easy to decode a from k.

Remark. Implementationally, every reuse of k reinforces an adversary's trial of previous attacks. When Oscar finds two messages that yield to the same attack, he can compute k and then obtain the desired signature.

The Digital Signature System (DSS) is another method of digitally signing messages that features small signatures and a large modulus (to make the discrete key hard to guess). DSS has reduction in the exponent that allows (for example) a 160-bit message, which implies a 320-bit signature by a 512-bit modulus.

The following changes to the El Gamal cryptosystem are encountered in DSS:

  1. = (x + a) k-1 mod (p-1).
  2. x = mod p .

    Note: If gcd(x + a, p-1) = 1, then -1 mod p-1 exists and the preceding equation becomes

    x-1 -1 = mod p .

3.3.3. Computation of Message Digests, with Applications.

With message digests (MDs), one hashes a long message to yield a short "digest". In practice, a one-way function is employed to significantly reduce violation of collisions and security concerns.

A key implementational issue is the probability of successful attack. We begin by discussing the Birthday Attack, which provides information about a lower bound on digest size.

An early message digest implementation called MD2 employed (a) 8-bit arithmetic; (b) few intermediate values, thereby yielding low space complexity; and (c) one-pass computation.

As time progressed, the development of integrated-circuit CPUs soon rendered MD2's byte-oriented algorithm obsolete. Thus, MD4 was introduced, which implemented the following advances:

Note that the message digest is a one-way mapping in the sense that it is difficult to obtain a message a from MD(a). Furthermore, the hash is small and has fixed size.

3.3.3.1. Application: Conversion of MDs to MICs.

A given message digest is not, of itself, a Message Integrity Code, since anyone can generate a valid MD. Thus, we need to convert the MD into a MIC. The following alternative procedures are employed: However, neither of these methods help in third-party authentication. Thus, we present an additional MD-to-MIC conversion technique that uses an initialization vector (IV) to set the digest to an initial value. Since the IV can vary with time, it is possible to use a timestamp as the IV, thereby avoiding replay attacks.

In practice, one partitions a message as a = (a1, a2, ..., an) and employs keys k1, k2, ..., kn. The encryption function e is then applied as:

If the key is made public (private), then a MD (MIC) is produced.

3.3.3.2. Application: Encryption with MDs.

One can use the MD as a pseudo-random number generator, with implementation as a one-time pad. For example, if plaintext is partitioned as a = (a1, a2, ..., an) and n = 3, then one can chain message digest computations (MDCs) as follows:

Here, xi, i = 1..3, denote the stream keys. The preceding method has several features of interest: Alternatively, one can assume the existence of an initial vector v and partition a message a as before. A secret key KAB is concatenated with v and the stream keys are produced as in the preceding method. The following diagram illustrates this method:

Here, the initial vector ensures a different stream each time that v is changed. Additional features are:

3.3.3.3. Application: Authentication using Message Digest.

Given an encryption function e that accepts a key and a message, as well as two parties (Alice and Bob), we have the following challenge scenario:

By replacing the encryption with a message digest computation, we obtain the following symmetric scenario:

Unfortunately, replay attacks are still possible, but could be obviated by appending timestamps to the challenge texts (e.g., KAB · rA). Additional prevention against replay attacks can be obtained by naming of principals, i.e., appending Alice's or Bob's name or signature to the messages they respectively send.


This concludes our overview of public-key cryptosystem applications. We next dicuss implementational aspects of PKC.


References