Method and apparatus for high bandwidth encryption/decryption using a low bandwidth cryptographic module

Abstract: A cryptographic system (20,30,42) enables a secure, but low-bandwidth, cryptographic module, such as a smartcard (20) or PCMCIA device, to serve as a high-bandwidth secret-key encryption decryption engine which uses the processing power of an untrusted, but fast, host processor (42) without revealing the secret key to that host processor.

Description: This invention relates to methods of encrypting data, methods of decrypting data, cryptographic systems, hosts for encrypting data, hosts for decrypting data, and cryptographic modules. Cryptographic modules, such as smartcards, are an important building block in many modern security applications. In particular, smartcards' tamper-resistant packaging, low cost, inherent portability, and loose coupling to a host make them especially attractive for use as secret key storage tokens when the host cannot be trusted to itself store a secret key. Unfortunately, these same attractive properties may also limit the utility of smartcards for certain applications. For example, the loose coupling and low cost properties of a smartcard typically imply that the card cannot process data at nearly the speed of the host to which it is coupled. Because bandwidth requirements are minimal in some applications (such as digital signatures), the low bandwidth of smartcards is not an impediment to their implementation in those applications. Other applications, however, (such as, file encryption, encrypted real-time traffic, and encrypted multimedia and video) by their very bandwidth-intensive nature, require the encryption and decryption of large amounts of data under the smartcard's secret key. For those applications, the bandwidth of existing smartcards is a serious bottleneck because the speed of the entire system is limited by the latency and bandwidth of the card interface as well as the computational capability of the microprocessor embedded in those smartcards. In response to this problem, consideration has been given to engineer a smartcard (and its interface to the host or the card reader) so that its processing performance rivals the processing capability of the attached host. This is not always technologically feasible when one considers the stringent dimension requirements of smartcards. More importantly, increasing the processing performance of a smartcard to match the processing capability of an attached host would significantly increase the total cost of the system, perhaps prohibitively for most applications. Other solutions propose limiting smartcards operations to key storage functions only, thereby shifting as much of the processing load as possible from the slow, computationally limited smartcard to the much faster and powerful processing capabilities of the host. Those solutions defeat the purpose of using a smartcard for security purposes since implementation of those solutions requires making the key available to the host, prior to the performance of any cryptographic task. Hence, implementation of those solutions implies that the host processor is trusted with the key, which opens the door for a wide variety of security breaches. Thus, a problem of the prior art is the lack of a secure cryptographic system for encryption and decryption of large amounts of data using a smartcard's secret key. FR-A-2 670 036 is directed to a data communication/transfer system using a session key and a common key between two electronic apparatuses. Specifically, each electronic apparatus stores a predetermined common key used for encryption/decryption. The first apparatus encrypts the common key with a generated session key and transmits the encrypted session key to the second apparatus. The second apparatus decrypts the encrypted session key with the stored common key and uses the decrypted session key to encrypt data to be transferred to the first apparatus. DE-A-4 107 266 is directed to a method of encoding or decoding large data files using a server and a chip card, which contains two keys. The server and card first determine a random vector, related to the length of a block of data, which is stored in the server. Thereafter, a first key is sent to a server, which encodes the block of data according to an exclusive OR operation. Once all the blocks are encrypted using the first key, every k th block is sent to the chip card in which the block is encoded a second time with the second key. The twice encoded blocks are sent back to the server to replace the corresponding once encoded blocks. Decoding is performed in a similar manner. Proceedings of the Summer 1994 Usenix Conference, pages 27-35, "Key Management in an Encrypting File System" is directed to a system based on cryptographic smartcards, for the temporary escrow of file encryption keys for critical files in a cryptographic file system. The smartcard acts as a self-contained decryption engine without assistance or cooperation of the file system, by trading speed for bandwidth. Similarly, encryption under such a scheme cannot utilize the processing power of the file system and relies on the ability to trade off space for time in the smartcard resources only. Ist ACM conference on Computer and Communications Security, pages 9-15, "A Cryptographic File System for Unix" is directed to the design and implementation of a Cryptographic File System (CFS) under the Unix operating system. Such a CFS system pushes file encryption entirely into the client file system interface. Each directory, in such a system, is protected by set of cryptographic keys, that may be stored on "smartcards". As such, the smartcard stores the key for the host computer to copy for user access. According to a first aspect of this invention there is provided a method as claimed in claim 1. According to a second aspect of this invention there is provided a method as claimed in claim 6. According to a third aspect of this invention there is provided a cryptographic system as claimed in claim 8. According to a fourth aspect of this invention there is provided a cryptographic system as claimed in claim 11. According to a fifth aspect of this invention there is provided a host for encrypting data as claimed in claim 13. According to a sixth aspect of this invention there is provided a host for decrypting data as claimed in claim 14. According to a seventh aspect of this invention there is provided a cryptographic module as claimed in claim 15. According to an eighth aspect of this invention there is provided a cryptographic module as claimed in claim 16. The invention may enable a trusted, but low-bandwidth, cryptographic module to serve as a high-bandwidth secret-key encryption/decryption engine that uses the processing power of an untrusted, but fast, host processor for performing a substantial amount of the encrypting/decrypting tasks without revealing the secret key to the host. The cryptographic module may be, for example, a smartcard or a standard-conforming Personal Computer Memory Card International Association (PCMCIA) device. In an embodiment of the invention, a host processor derives a compact representation of a block of data that is received by the host. The compact data representation is then transmitted to the cryptographic module which encrypts the compact data representation under a cryptographic key stored therein, to form a block key that is returned to the host. The host then encrypts the block of data under the block key. This process is repeated for every block of plain text data received by the host such that there is no useful correlation between the key for one block and the key for another. The compact representation of the block of plain text data may be included in the encrypted block of plain text data. Furthermore, the size of the resulting ciphertext may be equal to the size of the plain text data in order to make the encryption process transparent to other applications that may be running on the host. Decryption of the encrypted data is accomplished by reversing the encryption process described above. Specifically, when the host receives a block of ciphertext in the form of encrypted data and a compact representation of that block of encrypted data, the host transmits the compact representation of that block of ciphertext to the cryptographic module. The cryptographic module uses its cryptographic key and the received compact representation of the block of ciphertext to recover the block key. The cryptographic module then returns the block key to the host which uses that key to decrypt the block of ciphertext. Brief Description of the Drawings In the drawings: FIG. 1 is a block diagram of a system designed to use an encryption/decryption arrangement embodying the invention; and FIGs. 2, and 3, are flow diagrams of programmed instructions executed by some of the components of FIG. 1 to encrypt and decrypt data. Detailed Description FIG. 1 is block diagram of a system designed to use an encryption/decryption arrangement embodying the invention. The block diagram of FIG. 1 shows a portable encrypting module or smartcard 20, a card reader/writer 30 and a host 42. Although card reader/writer 30 is shown in FIG. 1 as a separate, stand-alone component, it is to be understood that card reader/writer 30 may be included in host 42. Major components of smartcard 20 include a microprocessor 22, an analog interface chip 21, the inductive coil 24 of a transformer 29, and capacitive plates 25 through 28. All smartcard components are preferably laminated beneath the smartcard surface such that no external contacts are accessible to intruders. The microprocessor 22 has a central processing unit and internal memory units that store some of the programmed instructions shown in FIGs. 2 and 3. The internal memory units of microprocessor 22 also store protocols and associated software programs that are executed by microprocessor 22 to transmit and receive data to and from host 42, respectively, via the card reader/writer 30. Those software programs also include a block cipher algorithm, such as the well-known Data Encryption Standard (DES) algorithm that is used in conjunction with the programmed instructions shown in FIGs. 2 and 3 to encrypt and decrypt data under a cryptographic key also stored in the internal memory units of microprocessor 22. Of particular significance among the attributes of smartcard 20 is a) the limited computational power of microprocessor 22 which allows smartcard 20 to encrypt and decrypt limited amount of data within a particular time period, and b) the limited bandwidth of the link between smartcard 20 and the host. All input to, and output from, smartcard 20 is channeled to analog interface chip 21 which transfers information to and from microprocessor 22 and distributes electrical power from the card reader/writer 30 to the smartcard 20. Specifically, when analog interface chip 21 receives power through the mating of inductive coils 24 and 32 of transformer 29, analog interface chip 21 conditions the electrical power before distributing it to microprocessor 22. Likewise, clock recovery and signal conditioning is performed by analog interface chip 21 for data transferred thereto via the mating of capacitive plates 25, 26, 27 and 28 of smartcard 20 to capacitive plates 35, 36, 37 and 38 of card reader/writer 30. Because of the limited dimensions of smartcard 20, capacitive plates 25, 26, 27 and 28 can only carry limited amount information from card reader/writer 30 to smartcard 20. Hence, smartcard 20 is bandwidth-limited in addition to being CPU-limited. In addition to the components of card reader/writer 30 already described above with respect to electrical power and data transfer features of smartcard 20, card reader/writer 30 also includes a power supply 31, a Universal Asynchronous Receiver Transmitter (UART) 41, a microprocessor 39 and analog interface circuit 40. Some of the components included in the smartcard 20 may also be used in the card reader/writer 30. For example, the same physical microprocessor can be used for both microprocessor 22 and 39. Similarly, the data transfer features of analog interface chip 21 and 42 can be almost identical. Power supply 31 provides electrical power to card reader/writer 30 and smartcard 20 when the latter is coupled to the former. Power supply 31 also synchronizes a clock signal from the card reader/writer 30 to the smartcard 20 through the transformer 29. The UART 41 is primarily a physical interface that is arranged to receive and transmit asynchronous data according to a specific standard. UART 41 communicates clock synchronization signals to power supply 31 and transfers data received from host 42 to microprocessor 39 and likewise, transmits data received from microprocessor 39 to host 42. Host 42 is a general purpose computer that receives plain text data and/or ciphertext from a data source 50 which is shown in FIG. 1 as a data storage area. Alternatively data source 50 may be a communications network arranged to transmit to, and receive from host 42 data associated with diverse applications ranging from database management systems to multimedia applications. Host 42 stores in its memories software programs and some of the programmed instructions shown in FIGs. 2 and 3. Chief among the software programs executed by host 42 is an encryption/decryption algorithm, such as the DES algorithm, that allows plain text (or ciphertext) data to be encrypted (decrypted) under one or more cryptographic keys. Instructions included in this algorithm allow host 42 to operate on large blocks of plain text data B and ciphertext C, each consisting of a series of n individual b bit blocks, denoted B 1 ... B n and C 1 ... C n , respectively. Also stored in the internal memories of host 42 are programmed instructions for a public function that returns a cryptographic hash of an arbitrary length bitstring. In this example, host 42 is trusted to process the plain text data received from source 50. However, host 42 is not allowed to know the cryptographic key stored in the internal memories of microprocessor 22 embedded in smartcard 20. Hence, host 42 is arranged to perform a single, low-bandwidth interaction with smartcard 20 to obtain enough information to encrypt or decrypt a single arbitrary length block. Without smartcard 20 assistance and cooperation, however, host 42 cannot use the information received from smartcard 20 to encrypt or decrypt other blocks. FIG. 2 is flow diagram of programmed instructions executed by host 42 and smartcard 20 to implement the principles of the invention. When host 42 receives a block of plain text data from source 50, it divides the block of data into N sub-blocks B 1 to B n , as indicated in step 201. While the size of a received block of data is application-dependent, the size of each sub-block, however, is determined by the cipher function. The division of the block of plain text data is performed to derive a compact representation of the block, a so-called message digest of the block. In this example, the compact representation of the block of plain text data is achieved by diffusing all the bits in the block. Specifically, the compact representation function is initiated when host 42, in step 202, selects one of the sub-blocks, such as sub-block B 1 , for example, to calculate the hash of the bits in that sub-block to produce the resulting hash H(B 1 ). Thereafter, host 42, in step 203, performs an "exclusive or" operation on the remaining sub-blocks B 2 to B n with the value of the hash H(B 1 ) to produce intermediate sub-blocks I 2 .....I n .. Then, host 42, in step 204, calculates the hash value h of the intermediate sub-blocks I 2 .....I n.. . Intermediate sub-block I 1 is then derived by host 42, in step 205, through an "exclusive or" operation of sub-block B 1 with the hash value h. Host 42, in step 206, transmits to smartcard 20 intermediate sub-block I 1 . It will be appreciated that sub-block I 1 contains indicia of all the bits in the block of plain text data as a result of the hash and "exclusive or" operations described above. In other words, all the bits in the block of plain text data have been diffused to produce I 1 . Upon receiving intermediate sub-block I 1 , smartcard 20, in step 207 encrypts intermediate sub-block I 1 under its cryptographic key K to produce encrypted sub-block C 1 . Smartcard 20 proceeds, in step 208 to encrypt C 1 under the cryptographic key K to produce block key K s . Thereafter, smartcard 20, in step 209, sends encrypted sub-block C 1 to host 42 which encrypts the intermediate blocks I 2 to I n under the block key K s to produce ciphertext C 2 to C n for sub-blocks B 2 to B n . Optionally, this encryption may be performed with a chaining cipher, such as the cipher block chaining process defined in the Federal Information Processing Standards Publication 81, Government Printing Office, Washington, D.C., 1980. FIG. 3 presents, in flow diagram format, programmed instructions executed by host 42 and smartcard 20 to decrypt a block of ciphertext data. When host 42 receives a block of ciphertext data, it divides that block of data into n sub-blocks C 1 to C n , as indicated in step 301. Host 42, sends the first ciphertext sub-block C 1 to smartcard 20 which encrypts the data in the first ciphertext sub-block C 1 , in step 302 to derive the block key K s . Thereafter, smartcard 20, in step 302, decrypts the first ciphertext sub-block C 1 to derive the intermediate sub-block I 1 which is sent to host 42 along with the block key K s . Host 42, in step 303 uses the block key K s to decrypt C 2 to C n to recover intermediate sub-blocks I 2 to In. Host 42 proceeds in step 304 to calculate the hash value h for intermediate sub-blocks I 2 to I n . Thereafter, host 42 recovers B 1 by performing an "exclusive or" operation on the intermediate sub-block I 1 received from smartcard 20 with the hash value h. Host 42, in step 305, calculates the hash of the bits in that sub-block B to produce the resulting hash H(B 1 ). Host 42 then, in step 406, recovers sub-blocks B 2 to B n . Host 42 in step 407 assembles sub-blocks B to B n to reconstruct the block of plain text data. Table I and Table II show illustrative programming code for the encryption and decryption process, respectively, for this example. It is worth noting that the decrypting process described above implicitly assumes that the compact representation of the encrypted block is included in the data contained in that block. However, the principles of the invention can be implemented without this requirement. Optionally, an authentication process can be added to the encryption and decryption tasks to detect any tampering with the ciphertext. This authentication process may simply consist of setting the first bits of each block to some fixed value (say, all zeros). By checking those bits on decryption, any tampering with the ciphertext becomes easily detectable. Advantageously, any size block can be encrypted or decrypted with one card interaction, with the card performing only two cipherblock operations for either encrypting or decrypting a block of data. Furthermore, host 42 can neither encrypt nor decrypt data without on-line access to smartcard 20. In other words, encryption and decryption without the card is no easier than breaking the underlying cipher even for hosts that have had prior interaction(s) with the card.

Claims: A method of encrypting data, including the steps of receiving, by a cryptographic module (20), a characteristic of data from a host (42), encrypting the characteristic of data in the cryptographic module (20) with a cryptographic key stored 5 therein, and transmitting the encrypted characteristic of data back to the host (42); CHARACTERIZED IN THAT the characteristic of data is a hash value representing a block of data; the encrypted characteristic of data forms a block key; and the method includes encrypting the block of data at the host (42) using the block key received from the cryptographic module (20). A method as claimed in claim 1 wherein the step of encrypting the block of data includes the step of encrypting the block of data such that a resulting encrypted block of data has an equal number of bits as its non-encrypted counterpart. A method as claimed in claim 1 wherein said hash value is derivable from the encrypted block of data. A method as claimed in claim 1 wherein said hash value is a block of data that is divided therein into sub-blocks from which at least one sub-block is selected, wherein each sub-block contains a plurality of bits of data, such that each bit in the at least one selected sub-block is dependent on every bit in the block of data. A method as claimed in claim 4 wherein the block key is formed by a) a first encryption of said value to produce a ciphertext for the at least one selected sub-block, and b) a second encryption of said ciphertext to derive the block key. A method of decrypting data, the method including the steps of receiving encrypted data and a characteristic of the data at a host (42), transmitting the characteristic of the data to a cryptographic module (20) with a cryptographic key, decrypting the characteristic of the data at the cryptographic module (20), and transmitting the decrypted characteristic of the data back to said host (42); CHARACTERIZED IN THAT the encrypted data is a block of ciphertext; the characteristic of the data is a message digest of the block of ciphertext; the decrypting step includes recovering a block key previously used to produce the block of ciphertext; said recovering being performed using the cryptographic key; and the method includes the step of decrypting the block of ciphertext at the host (42) using the block key. A method as claimed in claim 6 wherein the message digest of the block of ciphertext is included in the block of ciphertext received by the host (42). A cryptographic system, including a cryptographic module (20) with a cryptographic key stored therein and having means for receiving (21, 25, 26, 27, 28) a characteristic of data from a host (42), means for encrypting (22, 20) the characteristic of data with the cryptographic key, and means for transmitting (21, 25, 26, 27, 28) the encrypted characteristic of data back to the host (42), the host (42) having means for receiving (40, 35, 36, 37, 38, 39, 41) the encrypted characteristic of data from the cryptographic module (20); CHARACTERIZED IN THAT the characteristic of data is a hash value representing a block of data; the encrypted characteristic of data forms a block key; and the system includes means for encrypting (42) the block of data using the received block key. A system as claimed in claim 8 wherein said value is derivable from the encrypted block of data. A system as claimed in claim 8 wherein said means for encrypting (42) said block of data includes means for ensuring (42) that an encrypted data block has an equal number of bits as its non-encrypted counterpart. A cryptographic system, including a host (42) having means for receiving (42) encrypted data and a characteristic of the data, means for transmitting (42) the characteristic of the data to a cryptographic module (20) with a cryptographic key stored therein, the cryptographic module (20) having means for decrypting (22) the characteristic of the data with the cryptographic key, and means for transmitting (21, 25, 26, 27, 28) the decrypted characteristic of the data to the host (42); CHARACTERIZED IN THAT the encrypted data is a block of ciphertext; the characteristic of the data is a message digest of the block of ciphertext; the means for decrypting includes means for recovering (22) a block key previously used to produce the block of ciphertext; said recovering being performed using the cryptographic key; and the system includes means for decrypting (42) at the host (42) the block of ciphertext using the block key. A system as claimed in claim 11 wherein said message digest is included in the block of ciphertext received by the host. A host (42) for encrypting data, including means for transmitting (41, 39, 40, 35, 36, 37, 38) a characteristic of data to a cryptographic module (20) that stores a first cryptographic key; CHARACTERIZED IN THAT the characteristic of data is a hash value representing a block of data; the cryptographic module (20) serves to transmit a second cryptographic key to the host (42) that includes information transformed at least once under said first cryptographic key without being indicative of said first cryptographic key; and the host includes means for encrypting (42) at least a portion of the data in said block of data under the second cryptographic key. A host 42) for decrypting data, including means for receiving (42) encrypted data and a characteristic of the data, and means for transmitting (41, 39, 40, 35, 36, 37, 38) the characteristic of the data to a cryptographic module; CHARACTERIZED IN THAT the encrypted data is a block of data previously transformed under a first cryptographic key, said block of data including a plurality of segments transformed under a second cryptographic key which is a function of said first cryptographic key and data in said segments; the characteristic of the data is a message digest associated with data stored in a predetermined one of said segments in order to identify thereto said second cryptographic key; and the host includes means for decrypting (42) at least a subset of said segments using said second cryptographic key. A cryptographic module (20) including means for storing (22) a cryptographic key; means for receiving (21, 25, 26, 27, 28) a characteristic of data from a host (42); means for encrypting (22) the characteristic of data; and means for transmitting the encrypted characteristic of data to the host (42); CHARACTERIZED IN THAT the characteristic of data is a hash value of a block of data as part of a block of plain text data; and the means for encrypting includes means for performing at least one transformation operation under said cryptographic key to derive a different cryptographic key that is transmitted to said host (42) in order for said host (42) to encrypt the bits in said block under said different cryptographic key. A cryptographic module including means for storing (22) a first cryptographic key, means for receiving (21, 25, 26, 27, 28) encrypted data from a host, means for decrypting (22) data, and means for transmitting (21, 25, 26, 27, 28) data to a host (42); CHARACTERIZED IN THAT the encrypted data contains at least one message digest of a sub-block of ciphertext data from a group of such sub-blocks which were a) previously encrypted under a second cryptographic key that is a function of said first cryptographic key and data in said sub-blocks, and b) received by said host (42) as part of a block of ciphertext data; and the means for decrypting includes means for deriving from said message digest of encrypted data said second cryptographic key that is transmitted to said host (42) in order for said host (42) to decrypt the remaining sub-blocks of encrypted data without knowing said first cryptographic key.

Inventors: BLAZE MATTHEW A, BLAZE, MATTHEW A.
Applicants: AT & T CORP, AT&T IPM CORP.
Application year: 1996
Main classification: H04L9
IPC codes: H04L9, G07F7, G09C1