Block cipher using key data merged with an intermediate block generated from a previous block6459792Abstract A cryptographic processing apparatus for performing cryptographic processing using input data to generate output data is provided. The cryptographic processing apparatus includes a storage unit for storing chain data which is used for reflecting present cryptographic processing on next cryptographic processing, and for renewing the chain data each time cryptographic processing is performed, a merging unit for merging the chain data stored in the storage unit with the input data to generate merged data, and a main cryptographic processing unit for performing main cryptographic processing using the merged data to generate output data and for outputting intermediate data generated during a generation of the output data, wherein the storage unit renews the chain data by storing the intermediate data outputted by the main cryptographic processing unit as the new chain data, which is used for the next cryptographic processing. Claims What is claimed is: Description BACKGROUND OF THE INVENTION
TABLE 1
32 1 2 3 4 5
4 5 6 7 8 9
8 9 10 11 12 13
12 13 14 15 16 17
16 17 18 19 20 21
20 21 22 23 24 25
24 25 26 27 28 29
28 29 30 31 32 1
The table shows new bit positions to which input bits are transposed. For example, the 32th bit of the input bits is transposed to the first bit and the 47th bit of the output bits, while the first bit of the input bits is transposed to the second bit and the 48th bit of the output bits. Then an exclusive-OR operation is performed on the obtained 48 bits and 48 bits of the subkey Kn for each corresponding bit, and the result is divided into eight 6-bit groups which are then inputted into eight choice functions S1-S8. The choice functions S1-S8 (also referred to as S boxes) are functions which input 6 bits and output 4 bits. The processing of the choice functions is described with corresponding substitution tables. FIG. 6 shows the substitution tables of the choice functions S1-S8. Each choice function is provided with 64 numbers each in a range of 0-15, which are arranged in 4 lines and 16 columns. The first bit and the last bit out of input six bits specify a line in the substitution table, and the other 4 bits specify a column in the table. For instance, when "011011" is inputted in the choice function 31, the first bit "0" and the last bit "1" specify the second line, and the other 4 bits "1101" specify the 14th column. As "5" is given in an intersection box of the second line and the 14th column in the substitution table of the choice function S1, "0101" is outputted. The total of 32 bits (4 bits.times.8-32 bits) outputted from the eight choice functions S1-S8 is arranged according to permutation P shown in the following table (Table 2), and as a result outputted as "f{L(n-1), kn}".
TABLE 2
16 7 20 21
29 12 28 17
1 15 23 26
5 18 31 10
2 8 24 14
32 27 3 9
19 13 30 6
22 11 4 25
The table shows new bit positions to which input bits are transposed. For example, the 16th bit of the input bits is transposed to the first bit of the output bits, while the seventh bit of the input bits is transposed to the second bit of the output bits. The block storage unit 102 is equipped with a block renewal function. Each time the fourth encryption unit 105d generates a fourth intermediate block, the block storage unit 102 renews the chain block by storing the fourth intermediate block as the new chain block, which is used for processing a next block. In the present example, the block storage unit 102 stores the 64-bit initial value IV in advance, which is used for processing the first plaintext block. The block storage unit 102 renews the chain block by storing a fourth intermediate block which was generated during the processing of the first plaintext block. The renewed chain block is then used for processing the second plaintext block, and the block storage unit 102 renews the chain block by storing a fourth intermediated block generated during the processing of the second plaintext block. Next, the renewed chain block is used for processing the third plaintext block, and the block storage unit 102 renews the chain block by storing a fourth intermediate block generated during the processing of the third plaintext block. The renewed chain block is then used for processing the fraction plaintext data. The fraction data processing unit 106 receives the fraction plaintext data from the block dividing unit 101, and generates fraction ciphertext data whose number of bits is the same as the fraction plaintext data using the chain block stored in the block storage unit 102. The fraction data processing unit 106 includes a data matching unit 106a and a fraction data merging unit 106b. FIG. 7 shows the detailed construction of the fraction data processing unit 106, which is shown in FIG. 3, of First Embodiment of the present invention. The data matching unit 106a generates fraction chain data whose number of bits is the same as the fraction plaintext data from the chain block stored in the block storage unit 102. In the present example, the fraction plaintext data is 8 bits, so that the data matching unit 106a generates fraction chain data which is composed of, for instance, highest 8 bits of the chain block stored in the block storage unit 102. The fraction data merging unit 106b merges the generated fraction chain data with the fraction plaintext data. In the present example, an exclusive-OR operation is performed on 8 bits of the fraction chain data and 8 bits of the fraction plaintext data for each corresponding bit to generate 8 bits of fraction ciphertext data. The block integration unit 107 integrates each ciphertext block generated by the eighth encryption unit 105h and the fraction ciphertext data generated by the fraction data processing unit 106 to generate ciphertext data. In the present example, the 64-bit first to third ciphertext blocks and the 8-bit fraction ciphertext data are integrated to form ciphertext data of 200 bits. It should be noted here that, although the block storage unit 102 renews the chain block using each fourth intermediate block generated by the fourth encryption unit 105d in the present example, any intermediate blocks generated during the processing can also be used. Accordingly, the block storage unit 102 may use one of the first to seventh intermediate blocks generated by the respective first to seventh encryption units 105a-105g as the new chain block. Construction of Data Decryption Apparatus 20 FIG. 8 shows the detailed construction of the data decryption apparatus 20, which is shown in FIG. 2, of First Embodiment of the present invention. The data decryption apparatus 20 includes a block dividing unit 201, a block storage unit 202, a key data merging unit 203, a subkey generation unit 204, first to eighth decryption units 205a 205h, a fraction data processing unit 206, and a block integration unit 207. When comparing the conventional encryption apparatus 30 shown in FIG. 1 and the data decryption apparatus 20 shown in FIG. 8, the exclusive-OR unit 301 corresponds to the key data merging unit 203, the data encryption unit 302 corresponds to the block dividing unit 201, the subkey generation unit 204, the first to eighth decryption units 205a-205h, the fraction data processing unit 206, and the block integration unit 207, and the register 303 corresponds to the block storage unit 202. The block dividing unit 201 divides input ciphertext data into 64-bit ciphertext blocks, which are then sent in turn to the first decryption unit 205a. When fraction ciphertext data which is smaller than 64 bits is left behind after the ciphertext data is divided into ciphertext blocks, the fraction ciphertext data is sent to the fraction data processing unit 206. In the present example, ciphertext data of 200 bits is inputted and divided into a first ciphertext block composed of the first to 64th bits, a second ciphertext block composed of the 65th to 128th bits, a third ciphertext block composed of the 129th to 192th bits, and fraction ciphertext data composed of the 193th to 200th bits. The block dividing unit 201 then sends in turn the first to third ciphertext blocks to the first decryption unit 205a, and the fraction ciphertext data to the fraction data processing unit 206. When each block which has been divided by the block dividing unit 201 is processed, the block storage unit 202 stores a chain block which is used for reflecting a present block on a next block. It should be noted that an initial value IV of the chain block is stored in the block storage unit 202 in advance for processing the first ciphertext block. This initial value IV is the same as the initial value IV used in the data encryption apparatus 10. That is to say, an initial value IV which is used for encrypting plaintext data is the same as an initial value IV which is used for decrypting ciphertext data corresponding to the plaintext data. The key data merging unit 203 merges the chain block stored in the block storage unit 202 with key data to generate merged key data. It should be noted here that this merging is the same as the merging performed by the key data merging unit 103 of the data encryption apparatus 10. Also, the key data used in the data decryption apparatus 20 is the same as the key data used in the data encryption apparatus 10. That is to say, key data used for encrypting plaintext data is the same as key data used for decrypting ciphertext data corresponding to the plaintext data. In the present example, for processing the first ciphertext block, an exclusive-OR operation is performed on the initial value IV of the 64-bit chain block and 64-bit input key data which has been determined in advance for each corresponding bit. For processing the second and third ciphertext blocks, an exclusive-OR operation is performed, for each corresponding bit, on the 64-bit key data and a 64-bit chain block generated during the processing of the immediately preceding ciphertext block. The subkey generation unit 204 generates a number of subkeys corresponding to a number of decryption units from the merged key data which has been generated by the key data merging unit 203. In the present example, eight 48-bit subkeys are generated from the 64-bit merged key data. It should be noted here that the function of generating the subkeys by the subkey generation unit 204 of the data decryption apparatus 20 is the same as the function of generating the subkeys by the subkey generation unit 104 of the data encryption apparatus 10. The first decryption unit 205a generates a seventh intermediate block from a ciphertext block using an eighth subkey. The second to seventh decryption units 205b-205g generate sixth to first intermediate blocks from the seventh to second intermediate blocks using seventh to second subkeys, respectively. The eighth decryption unit 205h generates a plaintext block from the first intermediate block using a first subkey. The first to eighth decryption units 205a-205h have the same construction, in which conversion processing is performed in eight stages, the conversion processing being composed of a process or converting higher 32 bits of a 64-bit input block using lower 32 bits of the 64-bit input block based on a conversion specified by a 48-bit subkey and a process of replacing the converted higher 32 bits with the lower 32 bits in series. In the present example, seventh to first intermediate blocks are progressively generated for each of the first to third ciphertext blocks, with first to third plaintext blocks being generated from the resulting intermediate blocks. It should be noted that the conversions performed by the first to eighth decryption units 205a-205h are inverse conversions of the conversions performed by the eighth to first encryption units 105h-105a of the data encryption apparatus 10, respectively. The block storage unit 202 is equipped with a block renewal function. Each time the fourth decryption unit 205d generates a fourth intermediate block, the block storage unit 202 renews the chain block by storing the fourth intermediate block as the new chain block, which will be used for processing a next ciphertext block. In the present example, the block storage unit 202 stores the initial value IV of 64 bits in advance, which is used for processing the first ciphertext block. The block storage unit 202 renews the chain block by storing a fourth intermediate block generated during the processing of the first ciphertext block as the new chain block. The renewed chain block is then used for processing the second ciphertext block, and the block storage unit 202 renews the chain block by storing a fourth intermediate block generated during the processing of the second ciphertext block. Next, the renewed chain block is used for processing the third ciphertext block, and the block storage unit 202 renews the chain block by storing a fourth intermediate block generated during the processing of the third ciphertext block. The renewed chain block is then used for processing the fraction ciphertext data. The fraction data processing unit 206 receives the fraction ciphertext data from the block dividing unit 201, and generates fraction plaintext data whose number is the same as the fraction ciphertext data using the chain block stored in the block storage unit 202. The fraction data processing unit 206 includes a data matching unit 206a and a fraction data merging unit 206b. FIG. 9 shows the detailed construction of the fraction data processing unit 206, which is shown in FIG. 8, of First Embodiment of the present invention. The data matching unit 206a generates fraction chain data whose number of bits is the same as the fraction ciphertext data from the chain block stored in the block storage unit 202. In the present example, the fraction ciphertext data is 8 bits, so that the data matching unit 206a generates fraction chain data which is composed of, for instance, highest 8 bits of the chain block stored in the block storage unit 202. The fraction data merging unit 206b merges the generated fraction chain data with the fraction ciphertext data. In the present example, an exclusive-OR operation is performed on 8 bits of the fraction chain data and 8 bits of the fraction ciphertext data for each corresponding bit to generate 8 bits of fraction plaintext data. The block integration unit 207 integrates each plaintext block generated by the eighth decryption unit 205h and the fraction plaintext data generated by the fraction data processing unit 206 to generate plaintext data. In the present example, the 64-bit first to third plaintext blocks and the 8-bit fraction plaintext data are integrated to form plaintext data of 200 bits. It should be noted here that, although the block storage unit 202 renews the chain block using each fourth intermediate block generated by the fourth decryption unit 205d in the present example, any intermediate blocks generated during the processing can also be used. Accordingly, the block storage unit 202 may use one of the seventh to first intermediate blocks generated by the respective first to seventh decryption units 205a-205g as the new chain block. Here, the intermediate block used by the block storage unit 202 of the data decryption apparatus 20 should be the same as the intermediate block used by the block storage unit 102 of the data encryption apparatus 10. Operation Operation of Data Encryption Apparatus 10 FIG. 10 is a flowchart showing the cryptographic processing of the data encryption apparatus 10 of First Embodiment of the present invention. As one example, a case is explained when the cryptographic processing is performed according to the DES algorithm in the data encryption apparatus 10 where 200-bit plaintext data is inputted and the initial value IV of the chain block is stored in the block storage unit 102 in advance. (1) The block dividing unit 101 judges whether unprocessed data of input plaintext data is equal to or larger than 64 bits (Step S101). In the present example, unprocessed data of the input plaintext data is originally 200 bits, so that the block dividing unit 101 judges that the unprocessed data is equal to or larger than 64 bits (Step S101: first time). (2) When the unprocessed data of the input plaintext data is equal to or larger than 64 bits, the first 64 bits are separated from the unprocessed data (Step S102). In the present example, the first to 64th bits of the 200-bit plaintext data are separated as a first plaintext block (Step S102: first time). (3) The key data merging unit 103 merges the chain block stored in the block storage unit 102 with key data to generate merged key data (Step S103). In the present example, an exclusive-OR operation is performed on the initial value IV of the 64 bit chain block and 64-bit key data for each corresponding bit to generate merged key data, which is then sent to the subkey generation unit 104 (Step S103: first time). (4) From the merged key data, the subkey generation unit 104 generates subkeys whose number is the same as the number of encryption units (Step S104). In the present example, eight 48-bit subkeys are generated from the 64-bit merged key data (Step S104: first time). The following is an example of the process of generating first to eighth 48-bit subkeys (48 bits.times.8) from the 64 bit key data which includes 8 parity bits. The 8 parity bits are removed from the 64-bit key data, and the remaining 56 bits are transposed according to transposition shown in the following table (Table 3).
TABLE 3
57 49 41 33 25 17 9
1 58 50 42 34 26 18
10 2 59 51 43 35 27
19 11 3 60 52 44 36
63 55 47 39 31 23 15
7 62 54 47 38 30 22
14 6 61 53 45 37 29
21 13 5 28 20 12 4
The table shows new bit positions to which input bits are transposed. For example, the 57th bit of the input bits is transposed to the first bit of the output bits, while the 49th bit of the input bits is transposed to the second bit of the output bits. The 56-bit key data is divided into the first half 28 bits represented as "C0" and the second half 28 bits as "D0", each of "C0" and "D0" being shifted to the left for a number of shifting times shown in the following table (Table 4) so as to generate C1-C8 and D1-D8.
TABLE 4
subkey number 1 2 3 4 5 6 7 8
number of shifting times 2 4 8 12 16 20 24 26
For instance, when C0=(c1 c2 c3 . . . c26 c27 c28), C1=(c3 c4 c5 . . . c28 c1 c2). Next, the 56-bit key data is transposed to be 48 bits in accordance with transposition shown in the following table (Table 5).
TABLE 5
14 17 11 24 1 5
3 28 15 6 21 10
23 19 12 4 26 8
16 7 27 20 13 2
41 52 31 37 47 55
30 40 51 45 33 48
44 49 39 56 34 53
46 42 50 36 29 32
The table shows new bit positions to which input bits are transposed. For example, the 14th bit of the input bits is transposed to the first bit of the output bits, while the 17th bit of the input bits is transposed to the second bit of the output bits. (5) The first encryption unit 105a generates a first intermediate block from a plaintext block using the first subkey (Step S105). In the present example, a first intermediate block is generated from the first plaintext block (step S105: first time). (6) The second to fourth encryption units 105b-105d generate second to fourth intermediate blocks from the first to third intermediate blocks using the second to fourth subkeys, respectively (Step S106). In the present example, second to fourth intermediate blocks are generated from the first to third intermediate blocks corresponding to the first plaintext block (Step S106: first time). (7) The block storage unit 102 renews the chain block by storing the fourth intermediate block generated by the fourth encryption unit 105d as the new chain block (Step S107). In the present example, the block storage unit 102 renews the chain block by storing the fourth intermediate block corresponding to the first plaintext block (Step S107: first time). (8) The fifth to seventh encryption units 105e-105g generate fifth to seventh intermediate blocks from the fourth to sixth intermediate blocks using the fifth to seventh subkeys (Step S108). In the present example, fifth to seventh intermediate blocks are generated from the fourth to sixth intermediate blocks corresponding to the first plaintext block (Step S108: first time). (9) The eighth encryption unit 105h generates a ciphertext block from the seventh intermediate block using the eighth subkey (Step S109). In the present example, a first ciphertext block is generated from the seventh intermediate block corresponding to the first plaintext block (Step S109: first time). (10) It is judged whether unprocessed data of the plaintext data exists. When the unprocessed data exists, the processing returns to Step S101 in order to process a next plaintext block or fraction plaintext data (Step S110). In the present example, unprocessed data exists, so that the processing returns to Step S101 (Step S110: first time). (11) In Step S101, the block dividing unit 101 judges that the unprocessed data in equal to or larger than 64 bits, since the remaining data after 64 bits were separated from the 200-bit plaintext data is 136 bits in the present example (Step S101: second time). (12) In Step S102, the 65th to 128th bits are separated from the 200-bit plaintext data as a second plaintext block in the present example (Step S102: second time). (13) In Step S103, an exclusive-OR operation is performed on the 64-bit chain block generated when processing the first plaintext block and the 64-bit key data for each corresponding bit to generate merged key data, which is then sent to the subkey generation unit 104 in the present example (Step S103: second time). (14) In Step S104, eight 48-bit subkeys are generated from the 64-bit merged key data in the present example (Step S104: second time). (15) (19) In Steps S105-S109, the second plaintext block is processed in the same way as the first plaintext block, so that first to seventh intermediate blocks and subsequently a second ciphertext block which correspond to the second plaintext block are generated, and the block storage unit 102 renews the chain block by storing the fourth intermediate block corresponding to the second plaintext block as the new chain block in the present example (Steps S105-S109: second time). (20) In Step S110, the processing returns to Step S101, as unprocessed data of the plaintext data still exists in the present example (Step S110: second time). (21) In Step S101, the block dividing unit 101 judges that the unprocessed data is equal to or larger than 64 bits, since the remaining data after b64 bits were separated from the 136-bit plaintext data is 72 bits in the present example (Step S101: third time). (22) In Step S102, the 129th to 192th bits of the 200-bit plaintext data are separated as a third plaintext block in the present example (Step S102: third time). (23) In Step S103, an exclusive-OR operation is performed on the 64-bit chain block generated when processing the second plaintext block and the 64-bit key data for each corresponding bit to generate merged key data, which is then sent to the subkey generation unit 104 in the present example (Step S103: third time). (24) In Step S104, eight 48-bit subkeys are generated from the 64 bit merged key data in the present example (Step S104: third time). (25)-(29) In Steps S105-S109, the third plaintext block is processed in the same way as the first plaintext block, so that first to seventh intermediate blocks and subsequently a third ciphertext block which correspond to the third plaintext block are generated, and the block storage unit 102 renews the chain block by storing the fourth intermediate block corresponding to the third plaintext block as the new chain block in the present example (Steps S105-S109: third time). (30) In Step S110, the processing returns to Step S101, as unprocessed data of the plaintext data still exists in the present example (Step S110: third time). (31) In Step S101, the block dividing unit 101 judges that the unprocessed data is not equal to or large than 64 bits, as the remaining data after 64 bits were separated from the 72-bit plaintext data is 8 bits in the present example (Step S101: fourth time). (32) When the unprocessed data of the plaintext data is smaller than 64 bits, the unprocessed data is sent to the fraction data processing unit 106 (step S111). In the present example, the 193th to 200th bits of the 200-bit plaintext data are sent to the fraction data processing unit 106 as fraction plaintext data. (33) On receiving the fraction plaintext data from the block dividing unit 101, the fraction data processing unit 106 generates fraction ciphertext data whose number of bits is the same as the fraction plaintext data using the chain block stored in the block storage unit 102 (Step S112). In the present example, an exclusive-OR operation is performed, for each corresponding bit, on the 8-bit fraction plaintext data and highest 8 bits of the 64-bit chain block which was generated when processing the third plaintext block and has been stored in the block storage unit 102, and as a result 8-bit fraction ciphertext data is generated. (34) When it is judged that unprocessed data of the plaintext data does not exist in Step S110, or after the fraction ciphertext data is generated in step S112, the block integration unit 107 integrates each ciphertext block generated by the eighth encryption unit 105h and the fraction ciphertext data generated by the fraction data processing unit 106 to generate ciphertext data (Step S113). In the present example, the first to third ciphertext blocks and the fraction ciphertext data are integrated to form 200-bit ciphertext data. Operation of Data Decryption Apparatus 20 FIG. 11 is a flowchart showing the cryptographic processing of the data decryption apparatus 20 of First Embodiment of the present invention. The operation of the data decryption apparatus 20 is inverse conversion of the operation of the data encryption apparatus 10. As one example, a case is explained when the cryptographic processing is performed according to the DES algorithm in the data decryption apparatus 20 where 200-bit ciphertext data is inputted and the initial value IV of the chain block is stored in the block storage unit 202 in advance as in the block storage unit 102 of the data encryption apparatus 10. (1) The block dividing unit 201 judges whether unprocessed data of the input ciphertext data is equal to or larger than 64 bits (Step S201). In the present example, unprocessed data of the input ciphertext data originally is 200 bits, so that the block dividing unit 201 judges that the unprocessed data is equal to or larger than 64 bits (Step S201: first time). (2) When the unprocessed data of the input ciphertext data is equal to or larger than 64 bits, the first 64 bits are separated from the unprocessed data (Step S202). In the present example, the first to 64th bits of the 200-bit ciphertext data are separated as a first ciphertext block (Step S202: first time). (3) The key data merging unit 203 merges the chain block stored in the block storage unit 202 with key data to generate merged key data (Step S203). In the present example, an exclusive-OR operation is performed on the initial value IV of the 64-bit chain block and 64-bit key data for each corresponding bit to generate merged key data, which is then sent to the subkey generation unit 204 (Step S203: first time). (4) From the merged key data, the subkey generation unit 204 generates subkeys whose number is the same as the number of decryption units (Step S204). In the present example, eight 48-bit subkeys are generated from the 64-bit merged key data (Step S204: first time). The process of generating first to eighth 48-bit subkeys (48 bits.times.8) from the 64-bit key data which includes 8 parity bits is the same as the subkey generation process performed by the subkey generation unit 104 of the data encryption apparatus 10. (5) The first decryption unit generates a seventh intermediate block from a ciphertext block using the eighth subkey (Step S205). In the present example, a seventh intermediate block is generated from the first ciphertext block (Step S205; first time). (6) The second to fourth decryption units 205b-205d generate sixth to fourth intermediate blocks from the seventh to fifth intermediate blocks using the seventh to fifth subkeys, respectively (Step S206). In the present example, sixth to fourth intermediate blocks are generated from the seventh to fifth intermediate blocks corresponding to the first ciphertext block (Step S206: first time). (7) The block storage unit 202 renews the chain block by storing the fourth intermediate block generated by the fourth decryption unit 205d as the new chain block (Step S207). In the present example, the block storage unit 202 renews the chain block by storing the fourth intermediate block corresponding to the first ciphertext block (step S207: first time). (8) The fifth to seventh decryption units 205e-205g generate third to first intermediate blocks from the fourth to second intermediate blocks using the fourth to second subkeys (Step S208). In the present example, third to first intermediate blocks are generated from the fourth to second intermediate blocks corresponding to the first ciphertext block (Step S208: first time). (9) The eighth decryption unit 205h generates a plaintext block from the first intermediate block using the first subkey (Step S209). In the present example, a first plaintext block is generated from the first intermediate block corresponding to the first ciphertext block (Step S209: first time). (10) It is judged whether unprocessed data of the ciphertext data exists. When the unprocessed data exists, the processing returns to Step S201 in order to process a next ciphertext block or fraction ciphertext data (Step S210). In the present example, unprocessed data exists, so that the processing returns to Step S201 (Step S210: first time). (11) In Step S201, the block dividing unit 201 judges that the unprocessed data is equal to or larger than 64 bits, since the remaining data after 64 bits were separated from the 200-bit ciphertext data is 136 bits in the present example (Step S201: second time). (12) In Step S202, the 65th to 128th bits are separated from the 200-bit ciphertext data as a second ciphertext block in the present example (Step S202: second time). (13) In Step S203, an exclusive-OR operation is performed on the 64-bit chain block generated when processing the first ciphertext block and the 64-bit key data for each corresponding bit to generate merged key data, which is then sent to the subkey generation unit 204 in the present example (Step S203: second time). (14) In Step S204, eight 48-bit subkeys are generated from the 64-bit merged key data in the present example (Step S204: second time). (15)-(19) In Steps S205-S209, the second ciphertext block is processed in the same way as the first ciphertext block, so that seventh to first intermediate blocks and subsequently a second plaintext block which correspond to the second ciphertext block are generated, and the block storage unit 202 renews the chain block by storing the fourth intermediate block corresponding to the second ciphertext block as the new chain block in the present example (steps S205-S209: second time). (20) In step S210, the processing returns to Step S201, as unprocessed data of the ciphertext data still exists in the present example (Step S210: second time). (21) In Step S201, the block dividing unit 201 judges that the unprocessed data is equal to or larger than 64 bits, since the remaining data after 64 bits were separated from the 136-bit ciphertext data 72 bits in the present example (Step S201: third time). (22) In Step S202, the 129th to 192th bits are separated from the 200-bit ciphertext data as a third ciphertext block in the present example (Step S202: third time). (23) In Step S203, an exclusive-OR operation is performed on the 64-bit chain block generated when processing the second ciphertext block and the 64-bit key data for each corresponding bit to generate merged key data, which is then sent to the subkey generation unit 204 in the present example (Step S203: third time). (24) In Step S204, eight 48-bit subkeys are generated from the 64-bit merged key data in the present example (Step S204: third time). (25)-(29) In Steps S205-S209, the third ciphertext block is processed in the same way as the first ciphertext block, so that seventh to first intermediate blocks and subsequently a third plaintext block which correspond to the third ciphertext block are generated, and the block storage unit 202 renews the chain block by storing the fourth intermediate block corresponding to the third ciphertext block as the new chain block in the present example (Steps S205-S209: third time). (30) In Step S210, the processing returns to Step S201, as unprocessed data of the ciphertext data still exists in the present example (Step S210: third time). (31) In Step S201, the block dividing unit 201 judges that the unprocessed data is not equal to or larger than 64 bits, as the remaining data after 64 bits were separated from the 72-bit ciphertext data is 8 bits in the present example (Step S201: fourth time). (32) When the unprocessed data of the ciphertext data is smaller than 64 bits, the unprocessed data is sent to the fraction data processing unit 206 (Step S211). In the present example, the 193th to 200th bits of the 200-bit ciphertext data are sent to the fraction data processing unit 206 as fraction ciphertext data. (33) On receiving the fraction ciphertext data from the block dividing unit 201, the fraction data processing unit 206 generates fraction plaintext data whose number of bits is the same as the fraction ciphertext data using the chain block stored in the block storage unit 202 (Step S212). In the present example, an exclusive-OR operation is performed, for each corresponding bit, on the 8-bit fraction ciphertext data and highest 8 bits of the 64-bit chain block which was generated when processing the third ciphertext block and has been stored in the block storage unit 202, and as a result 8-bit fraction ciphertext data is generated. (34) When it is judged that unprocessed data of the ciphertext data does not exist in Step S210, or after the fraction plaintext data is generated in Step S212, the block integration unit 207 integrates each plaintext block generated by the eighth decryption unit 205h and the fraction plaintext data generated by the fraction data processing unit 206 to generate plaintext data (Step S211). In the present example, the first to third plaintext blocks and the fraction plaintext data are integrated to form 200-bit plaintext data. In the cryptographic processing apparatus of First Embodiment, an intermediate block generated when performing the cryptographic processing on a present block is stored as a chain block, which is then merged with key data when performing the cryptographic processing on a next block, renewing the chain block each time the cryptographic processing is performed. Second Embodiment Second Embodiment of the present invention is different from First Embodiment in that a chain block is not merged with key data but merged with either cryptographic-processing object data or data which has been generated by the cryptographic processing. Construction The construction of an encrypted communication system of Second Embodiment is the same as that of First Embodiment, and is thereby not explained hero. Construction of Data Encryption Apparatus 10 FIG. 12 shows the detailed construction of a data encryption apparatus 10, which is shown in FIG. 2, of Second Embodiment of the present invention. Components which are the same as those in the data encryption apparatus 10 of First Embodiment shown in FIG. 3 are given the same numbers. Components whose functions are the same as those in the data encryption apparatus 10 of the First Embodiment are not explained here. The data encryption apparatus 10 of the Second Embodiment includes a block dividing unit 101, a block storage unit 102, a subkey generation unit 104, first to eighth encryption units 105a-105h, a fraction data processing unit 106, a block integration unit 107, and a block merging unit 108. When comparing the conventional encryption apparatus 30 shown in FIG. 1 and the data encryption apparatus 10 of the Second Embodiment of the present invention shown in FIG. 12, the exclusive-OR unit 301 corresponds to the block merging unit 108, the data encryption unit 302 corresponds to the block dividing unit 101, the subkey generation unit 104, the first to eighth encryption units 105a-105h, the fraction data processing unit 106, and the block integration unit 107, and the register 303 corresponds to the block storage unit 102. Here, the same example is used as in the First Embodiment where plaintext data of 200 bits is inputted in the data encryption apparatus 10. The block dividing unit 101 of the Second Embodiment is different from that of First the Embodiment only in that it sends divided blocks not to the first encryption unit 105a but to the block merging unit 108. The block merging unit 108 merges a chain block stored in the block storage unit 102 with a plaintext block to generate a merged plaintext block. In the present example, for processing a first plaintext block, an exclusive-OR operation is performed on the 64-bit first plaintext block and an initial value IV of d 64-bit chain block for each corresponding bit to generate a 64-bit first merged plaintext block. For processing second and third plaintext blocks, an exclusive-OR operation is performed, for each corresponding bit, on each of the 64-bit second and third plaintext blocks and a 64-bit chain block generated during the processing of the immediately preceding plaintext block, so as to generate 64-bit second and third merged plaintext blocks, respectively. The subkey generation unit 104 generates subkeys whose number is the same as the number of encryption units from key data. In the present example, the subkey generation unit 104 generates eight 48-bit subkeys from 64-bit input key data which has been determined in advance. The first encryption unit 105a generates a first intermediate block not from the plaintext block but from the merged plaintext block generated by the block merging unit 108. The first to eighth encryption units 105a-105h of the data encryption apparatus 10 of the Second Embodiment have the same functions as those of the First Embodiment. In the present example, First to seventh intermediate blocks are progressively generated for each of the first to third merged plaintext blocks, with first to third ciphertext blocks being generated from the resulting intermediate blocks. Construction of Data Decryption Apparatus 20 FIG. 13 shows the detailed construction of a data decryption apparatus 20, which is shown in FIG. 2, of Second Embodiment of the present invention. Components which are the same as those in the data decryption apparatus 20 of the First Embodiment shown in FIG. 8 are given the same numbers. Components whose functions are the same as those in the data decryption apparatus 20 of the First Embodiment are not explained here. The data decryption apparatus 20 of the Second Embodiment includes a block dividing unit 201, a block storage unit 202, a subkey generation unit 204, first to eighth decryption units 205a-205h, a fraction data processing unit 206, a block integration unit 207, and a block merging unit 208. Here, the same example is used as in the First Embodiment where ciphertext data of 200 bits is inputted in the data decryption apparatus 20. The subkey generation unit 204 generates subkeys whose number is the same as the number of decryption units from key data. In the present example, the subkey generation unit 204 generates eight 48-bit subkeys from 64-bit input key data which has been determined in advance. It should be noted here that the function of generating the subkeys by the subkey generation unit 204 of the data decryption apparatus 20 is the same as the function of generating the subkeys by the subkey generation unit 104 of the data encryption apparatus 10. The eighth decryption unit 205h generates a cryptographic-processed block from a first intermediate block using a first subkey. The first to eighth decryption units 205a-205h of the data decryption apparatus 20 of the Second Embodiment have the same functions as those of the First Embodiment. In the present example, seventh to first intermediate blocks are progressively generated for each of the first to third ciphertext blocks, with first to third cryptographic-processed blocks being generated from the resulting intermediate blocks. The block merging unit 208 merges a chain block stored in the block storage unit 202 with a cryptographic-processed block to generate a plaintext block. In the present example, for processing the first ciphertext block, an exclusive-OK operation is performed on the 64-bit first cryptographic-processed block and an initial value IV of the 64-bit chain block for each corresponding bit to generate a 64-bit first plaintext block. For processing the second and third ciphertext blocks, an exclusive-OR operation is performed, for each corresponding bit, on each of the 64-bit second and third cryptographic-processed blocks and a 64-bit chain block generated during the processing of the immediately preceding ciphertext block, so as to generate 64-bit second and third plaintext blocks, respectively. The block integration unit 207 integrates each plaintext block generated by the block merging unit 208 and fraction plaintext data generated by the fraction data processing unit 206 to generate plaintext data. In the present example, the 64-bit first to third plaintext blocks and the 8-bit fraction plaintext data are integrated to form 200-bit plaintext data. Operation Operation of Data Encryption Apparatus 10 FIG. 14 is a flowchart showing the cryptographic processing of the data encryption apparatus 10 of Second Embodiment of the present invention. Here, the same example as in the First Embodiment is used, wherein the cryptographic processing is performed according to the DES algorithm in the data encryption apparatus 10 where 200-bit plaintext data is inputted and the initial value IV of the chain block is stored in the block storage unit 102 in advance. Steps which are the same as those in the operation of the data encryption apparatus 10 of the First Embodiment shown in FIG. 10 are given the same numbers, and are not explained here. (1)-(2) The same as the First Embodiment (Steps S101 and S102: first time). (3) The subkey generation unit 104 generates subkeys whose number is the same as the number of encryption units from key data (Step S301). In the present example, eight 48-bit subkeys are generated from 64-bit input key data which has been determined in advance (Step S301: first time). (4) The block merging unit 108 merges a plaintext block with the chain block stored in the block storage unit 102 to generate a merged plaintext block (Step S302). In the present example, an exclusive-OR operation is performed on the 64-bit first plaintext block and the initial value IV of the 64-bit chain block for each corresponding bit to generate a 64-bit first merged plaintext block (Step S302: first time). (5) The first encryption unit 105a generates a first intermediate block from the merged plaintext block using a first subkey (step S303). In the present example, a first intermediate block is generated from the first merged plaintext block (Step S303: first time). (6)-(12) The same as the First Embodiment (Steps S106-S110: first time, Steps S101 and S102: second time). (13) In Step S301, eight 48-bit subkeys are generated from the 64-bit key data in the present example. It the key data has not been changed since the first time, the eight 48-bit subkeys generated in the first time may be stored, as the subkeys generated in the second time is the same as the subkeys generated in the first time (Step S301: second time). (14) In Step S302, an exclusive-OR operation is performed, for each corresponding bit, on the 64-bit second plaintext block and the 64-bit chain block generated when processing the first plaintext block, so as to generate a 64-bit second merged plaintext block in the present example (Step S302: second time). (15) In Step S303, a first intermediate block is generated from the second merged plaintext block in the present example (Step S303: second time). (16)-(22) the same as the First Embodiment (Steps S106-S110: second time, Steps S101 and S102: third time). (23) In Step S301, eight 48-bit subkeys are generated from the 64-bit key data in the present example. If the key data has not been changed since the first time, the eight 48-bit subkeys generated in the first time may be stored, since the subkeys generated in the third time is the same as the subkeys generated in the first time (Step S301: third time). (24) In Step S302, an exclusive-OR operation is performed, for each corresponding bit, on the 64-bit third plaintext block and the 64-bit chain block generated when processing the second plaintext block, so as to generate a 64-bit third merged plaintext block in the present example (Step S302: third time). (25) In Step S303, a first intermediate block is generated from the third merged plaintext block in the present example (Step S303 third time). (26)-(34) The same as the First Embodiment (Steps S106-S110: third time, Step S101: fourth time, Steps S111-S113). Operation of Data Decryption Apparatus 20 FIG. 15 is a flowchart showing the cryptographic processing of the data decryption apparatus 20 of Second Embodiment of the present invention. The operation of the data decryption apparatus 20 is inverse conversion of the operation of the data encryption apparatus 10. Here, the same example as in the First Embodiment is used, wherein the cryptographic processing is performed according to the DES algorithm in the data decryption apparatus 20 where 200-bit ciphertext data is inputted and the initial value IV of the chain block is stored in the block storage unit 202 in advance. Steps which are the same as those in the operation of the data decryption apparatus 20 of the First Embodiment shown in FIG. 11 are given the same numbers, and are not explained here. (1)-(2) The same as the First Embodiment (Steps S201-S202: first time). (3) The subkey generation unit 204 generates subkeys whose number is the same as the number of decryption units from key data (Step S401). In the present example, eight 48-bit subkeys are generated from the 64-bit input key data which has been determined in advance (step S401: first time). (4)-(6) The same as (5), (6), and (8) of the First Embodiment (Steps S205, S206, and S208: first time). (7) The eighth decryption unit 205h generates a cryptographic-processed block from the first intermediate block using a first subkey (Step S402). In the present example, a first cryptographic-processed block is generated from the first intermediate block corresponding to the first ciphertext block (Step S402: first time). (8) The block merging unit 208 merges the cryptographic processed block with the chain block stored in the block storage unit 202 (Step S403). In the present example, an exclusive OR operation is performed on the 64-bit first cryptographic-processed block and the initial value IV of the 64-bit chain block for each corresponding bit to generate a 64-bit first plaintext block (Step S403: first time). (9) The same as (7) of the First Embodiment (Step S207: first time). (10)-(12) The same as the First Embodiment (Step S210: first time, Steps S201 and S202: second time). (13) In Step S401, eight 48-bit subkeys are generated from the 64-bit key data in the present example. If the key data has not been changed, the eight 48-bit subkeys generated in the first time may be stored, since the subkeys generated in the second time is the same as the subkeys generated in the first time (Step S401: second time). (14)-(16) The same as (15), (16), and (18) of the First Embodiment (Steps S205, S206, and S208: second time). (17) In Step S402, a second cryptographic-processed block is generated from the first intermediate block corresponding to the second ciphertext block in the present example (Step S402: second time). (18) In Step S403, an exclusive-OR operation is performed, for each corresponding bit, on the 64-bit second cryptographic-processed block and the 64-bit chain block generated when processing the first ciphertext block, 30 as to generate a 64 bit second plaintext block (Step S403: second time). (19) The same as (17) of the First Embodiment (Step S207: second time). (20)-(22) The same as the First Embodiment (Step S210: second time, Steps S201-S202: third time). (23) In Step S401, eight 48-bit subkeys are generated from the 64-bit key data in the present example. If the key data has not been changed, the eight 48-bit subkeys generated in the first time may be stored, since the subkeys generated in the third time is the same as the subkeys generated in the first time (Step S401: third time). (24)-(26) The same as (25), (26), and (28) of First Embodiment (Steps S205, S206, and S208: third time). (27) In Step S402, a third cryptographic-processed block is generated from the first intermediate block corresponding to the third ciphertext block in the present example (Step S402: third time). (28) In Step S403, an exclusive-OR operation is performed, for each corresponding bit, on the 64-bit third cryptographic-processed block and the 64-bit chain block generated when processing the second ciphertext block, so as to generate a 64-bit third plaintext block (Step S403: third time). (29) The same as (27) of the First Embodiment (Step S207: third time). (30)-(34) The same as the First Embodiment (Step S210: third time, Step S201: fourth time, Steps S211-S213). In the cryptographic processing apparatus of Second Embodiment, an intermediate block generated when the cryptographic processing is performed on a present block is stored as a chain block, which is then merged with a plaintext block or a cryptographic-processed block when the cryptographic processing is performed on a next block, renewing the chain block each time the cryptographic processing is performed. Third Embodiment A data encryption apparatus 10 of Third Embodiment of the present invention is different from that of First Embodiment only in the input of a fifth encryption unit 105e. While the input of the encryption unit 105e of First Embodiment is the output of the fourth encryption unit 105d, the input of the fifth encryption unit 105e of the Third Embodiment is a plaintext block. Accordingly, a chain block and the plaintext block are processed by different encryption units. Also, a data decryption apparatus 20 of Third Embodiment of the present invention operates in inverse conversion of the data encryption apparatus 10. The data decryption apparatus 20 of the Third Embodiment is different from that of the First Embodiment in that the output of a fourth decryption unit 205d is a plaintext block, which is encrypted in the same way as the data encryption apparatus 10 to generate a fourth intermediate block, the fourth intermediate block then being stored as the new chain block. Construction The construction of an encrypted communication system of the Third Embodiment is the same as that of the First Embodiment, and is thereby not explained here. Construction of Data Encryption Apparatus 10 FIG. 16 shows the detailed construction of a data encryption apparatus 10, which is shown in FIG. 2, of Third Embodiment of the present invention. Components which are the same as those in the data encryption apparatus 10 of the First Embodiment shown in FIG. 3 are given the same numbers. Components whose functions are the same as those in the data encryption apparatus 10 of the First Embodiment are not explained here. The construction of the data encryption apparatus 10 of Third Embodiment is the same as that of the First Embodiment, the only difference lying in that the fifth encryption unit 105e of the Third Embodiment generates a fifth intermediate block not from a fourth intermediate block but from the plaintext block. Construction of Data Decryption Apparatus 20 FIG. 17 shows the detailed construction of a data decryption apparatus 20, which is shown in FIG. 2, of Third Embodiment of the present invention. Components which are the same as those in the data decryption apparatus 20 of the First Embodiment shown in FIG. 8 are given the same numbers. Components whose functions are the same as those in the data decryption apparatus 20 of the First Embodiment are not explained here. The data decryption apparatus 20 of the Third Embodiment includes a block dividing unit 201, a block storage unit 202, a key data merging unit 203, a subkey generation unit 204, first to fourth decryption units 205a-205d, first to fourth encryption units 205i-205l, a fraction data processing unit 206, and a block integration unit 207. Here, the same example is used as in the First Embodiment where ciphertext data of 200 bits is inputted in the data decryption apparatus 20. The fourth decryption unit 205d generates a plaintext block from a fifth intermediate block using a fifth subkey. In the present example, first to third plaintext blocks are generated from each fifth intermediate block corresponding to first to third ciphertext blocks. It should be noted that the first to fourth decryption units 205a-205d perform inverse conversions of the eighth to fifth encryption units 105h-105e of the data encryption apparatus 10, respectively. The first encryption unit 205i generates a first intermediate block from the plaintext block generated by the fourth decryption unit 205d using a first subkey. The second to fourth encryption units 205j-205l generate second to fourth intermediate blocks, from the first to third intermediate blocks using second to fourth subkeys, respectively. The first to fourth encryption units 205i-205l have the same functions and operations as the first to fourth encryption units 105a-105d of the data encryption apparatus 10. In the present example, from the first to third plaintext blocks, the first to fourth intermediate blocks which correspond to each of the first to third plaintext blocks are generated. Each time the fourth encryption unit 205l generates a fourth intermediate block, the block storage unit 202, which is provided with a block renewal function, renews the chain block by storing the fourth intermediate block as the new chain block, which is used for processing a next block. This operation is the same as in the First Embodiment. The block integration unit 207 integrates each plaintext block generated by the fourth decryption unit 205d and fraction plaintext data generated by the fraction data processing unit 206 to generate plaintext data. In the present example, the 64-bit first to third plaintext blocks and 8-bit fraction plaintext data are integrated to form 200-bit plaintext data. Operation Operation of Data Encryption Apparatus 10 FIG. 18 is a flowchart showing the cryptographic processing of the data encryption apparatus 10 of Third Embodiment of the present invention. Here, the same example as in the First Embodiment is used, wherein the cryptographic processing is performed according to the DES algorithm in the data encryption apparatus 10 where 200-bit plaintext data is inputted and the initial value of the chain block is stored in the block storage unit 102 in advance. Steps which are the same as those in the operation of the data encryption apparatus 10 of the First Embodiment shown in FIG. 10 are given the same numbers, and are not explained here. (1)-(7) The same as the First Embodiment (Steps S101-S107: first time). (8) The fifth to seventh encryption units 105e-105g generate fifth to seventh intermediate blocks from the plaintext block and the fifth and sixth intermediate blocks using the fifth to seventh subkeys, respectively (Step S501). In the present example, fifth to seventh intermediate blocks are generated from the first plaintext block and the fifth and sixth intermediate blocks corresponding to the first plaintext block, respectively (Step S501: first time). (9)-(17) The same as the First Embodiment (Steps S109 and S110: first time, Steps S101-S107: second time). (18) In Step S501, fifth to seventh intermediate blocks are generated from the second plaintext block and the fifth and sixth intermediate blocks corresponding to the second plaintext block respectively, in the present example (Step S501: second time). (19)-(27) The same as the First Embodiment (Steps S109 and S110: second time, Steps S101-S107: third time). (28) In Step S501, fifth to seventh intermediate blocks are generated from the third plaintext block and the fifth and sixth intermediate blocks corresponding to the third plaintext block respectively, in the present example (Step S501: third time). (29)-(34) The same as the First Embodiment (Steps S109 and S110: third time, Step S101; fourth Lime, Steps S111-S113). Operation of Data Decryption Apparatus 20 FIG. 19 is a flowchart showing the cryptographic processing of the data decryption apparatus 20 of Third Embodiment of the present invention. The operation of the data decryption apparatus 20 is inverse conversion of the operation of the data encryption apparatus 10. Here, the same example as in the First Embodiment is used, wherein the cryptographic processing is performed according to the DES algorithm in the data decryption apparatus 20 where 200-bit ciphertext data is inputted and the initial value IV of the chain block is stored in the block storage unit 202 in advance. (1)-(5) The same as the First Embodiment (Steps S201-S205: first time). (6) The second to fourth decryption units 205b-205d generate sixth and fifth intermediate blocks and a plaintext block from the seventh to fifth intermediate blocks using the seventh to fifth subkeys, respectively (Step S601). In the present example, sixth and fifth intermediate blocks and a first plaintext block is generated from the seventh to fifth intermediate blocks corresponding to the first ciphertext block, respectively (Step S601: first time). (7) The first encryption unit 205i generates a first intermediate block from the plaintext block generated by the fourth decryption unit 205d using the first subkey (Step S602). In the present example, a first intermediate block is generated from the first plaintext block (Step S602: first time). (8) The second to fourth encryption units 205j-205l generate second to fourth intermediate blocks from the first to third intermediate blocks using the second to fourth subkeys, respectively (Step S603). In the present example, second to fourth intermediate blocks are generated from the first to third intermediate blocks corresponding to the first plaintext block, respectively (Step S603: first time). (9) The block storage unit 202 renews the chain block by storing the fourth intermediate block generated by the fourth encryption unit 205l as the new chain block (Step S604). In the present example, the block storage 202 renews the chain block by storing the fourth intermediate block corresponding to the first plaintext block (Step S604: first time). (10) (15) The same as the First Embodiment (Step S210: first time, Steps S201 S205: second time). (16) In Step S601, sixth and fifth intermediate blocks and a second plaintext block are generated from the seventh to fifth intermediate blocks corresponding to the second ciphertext block respectively, in the present example (Step S601: second time). (17) In Step S602, a first intermediate block is generated from the second plaintext block in the present example (Step S602: second time). (18) in Step S603, second to fourth intermediate blocks are generated from the first to third intermediate blocks corresponding to the second plaintext block respectively, in the present example (Step S603: second time). (19) In Step S604, the block storage unit 202 renews the chain block by storing the fourth intermediate block corresponding to the second plaintext block in the present example (Step S604: second time). (20)-(25) The same as the First Embodiment (Step S210: second time, Steps S201-S205: third time). (26) In Step S601, sixth and fifth intermediate blocks and a third plaintext block are generated from the seventh to fifth intermediate blocks corresponding to the third ciphertext block respectively, in the present example (Step S601: third time). (27) In Step S602, a first intermediate block is generated from the third plaintext block in the present example (Step S602: third time). (28) In Step S603, second to fourth intermediate blocks are generated from the first to third intermediate blocks corresponding to the third plaintext block respectively, in the present example (Step S603: third time). (29) In Step S604, the block storage unit 202 renews the chain block by storing the fourth intermediate block corresponding to the third plaintext block as the new chain block in the present example (Step S604: third time). (30)-(34) The same as the First Embodiment (Step S210: third time, Step S201: fourth time, Steps S211-S213). In the cryptographic processing apparatuses of the Third Embodiment, an intermediate block generated when the cryptographic processing is performed on a present block is stored as a chain block, which is then merged with key data when performing the cryptographic processing on a next block, renewing the chain block each time the cryptographic processing is performed. It should be noted that in the Third Embodiment the change described above is applied to the First Embodiment in which the chain block is merged with the key data, while the change may be applied to the Second Embodiment in which the chain block is merged with a plaintext block or a cryptographic-processed block. In such a cryptographic processing apparatus, an intermediate block generated when the cryptographic processing is performed on a present block is stored as a chain block, which is then merged with the plaintext block or the cryptographic-processed block when the cryptographic processing is performed on a next block, renewing the chain block each time the cryptographic processing is performed. Fourth Embodiment Fourth Embodiment of the present invention is a cryptographic processing apparatus in that, when the change of the Third Embodiment is applied to Second Embodiment, the operation of the first to fourth encryption units to encrypt data which is to be merged and the operation of a block storage unit to store a chain block are carried out in inverse order, so that a merged block or a block which is not yet merged is stored as the new chain block. Construction The construction of an encrypted communication system of the Fourth Embodiment is the same as that of the First Embodiment and is thereby not explained here. Construction of Data Encryption Apparatus 10 FIG. 20 shows the detailed construction of a data encryption apparatus 10, which is shown in FIG. 2, of Fourth Embodiment of the present invention. Components which are the same as those in the data encryption apparatus 10 of the Second Embodiment shown in FIG. 12 are given the same numbers. Components whose functions are the same as those in the data encryption apparatus 10 of the Second Embodiment are not explained here. The data encryption apparatus 10 of the Fourth Embodiment includes a block dividing unit 101, a block storage unit 102, a subkey generation unit 104, first to eighth encryption units 105a-105h, a fraction data processing unit 106, a block integration unit 107, and a block merging unit 108. Here, the same example is used as in the First Embodiment where plaintext data of 200 bits is inputted in the data encryption apparatus 10. The first encryption unit 105a generates a first intermediate block not from a merged plaintext block but from a chain block stored in the block storage unit 102. The first to fourth encryption units 105a-105d have the same function as those of the Second Embodiment. Here, first to third intermediate blocks and a cryptographic-processed block which correspond to each chain block are generated from the chain block. The block merging unit 108 merge the cryptographic-processed block generated by the fourth encryption unit 105d with a plaintext block to generate a fourth intermediate block. In the present example, for processing a first plaintext block, an exclusive-OR operation is performed, for each corresponding bit, on the 64-bit first plaintext block and a 64-bit first cryptographic-processed block generated from an initial value IV of the chain block. For processing second and third plaintext blocks, an exclusive-OR operation is performed, for each corresponding bit, on the 64-bit second and third plaintext blocks and 64-bit second and third cryptographic-processed blocks generated during the processing of the immediately preceding block, respectively. Each time the block merging unit 108 generates a fourth intermediate block corresponding to a present plaintext block, the block storage unit 102, which is provided with a block renewal function, renews the chain block by storing the fourth intermediate block as the new chain block, which is used for processing a next plaintext block. In the present example, the block storage unit 102 stores the 64 bit initial value IV in advance, which is used for processing the first plaintext block, and renews the chain block by storing a fourth intermediate block generated when processing the first plaintext block as the new chain block. Next, this new chain block is used for processing the second plaintext block, and a fourth intermediate block generated during the processing is stored in the block storage unit 102 as the new chain block. Next, this new chain block is used for processing the third plaintext block, and a fourth intermediate block generated during the processing is stored in the block storage units 102 as the new chain block. Then, this new chain block is used for processing fraction plaintext data. The fifth to eighth encryption units 105e-105h have the same functions as those of the Second Embodiment. In the present example, fifth to seventh intermediate blocks are progressively generated for each of the fourth intermediate blocks, with first to third ciphertext blocks being generated from the resulting intermediate blocks. The fraction data processing unit 106 receives the fraction plaintext data from the block dividing unit 101, and generates fraction ciphertext data whose number of bits is the same as the fraction plaintext data using the cryptographic-processing block generated by the fourth encryption unit 105d. The fraction data processing unit 106 includes a data matching unit 106a and a fraction data merging unit 106b. The data matching unit 106a generates fraction cryptographic-processed data whose number of bits is the same as the fraction plaintext data from the cryptographic-processed block generated by the fourth encryption unit 105d. In the present example, the fraction plaintext data is 8 bits, so that the data matching unit 106a generates fraction cryptographic-processed data which is composed of, for example, highest 8 bits of the cryptographic-processed block generate by the fourth encryption unit 105d. The fraction data merging unit 106b merges the fraction cryptographic-processed data with the fraction plaintext data to generate the fraction ciphertext data. In the present example, an exclusive-OR operation is performed on the 8-bit fraction cryptographic-processed data and the 8-bit fraction plaintext data for each corresponding bit to generate 8-bit fraction ciphertext data. It should be noted here that the fraction data processing unit 106 may have the same function as that of Second Embodiment. Construction of Data Decryption Apparatus 20 FIG. 21 shows the detailed construction of a data decryption apparatus 20, which is shown in FIG. 2, of Fourth Embodiment of the present invention. Here, the same example is used as in First Embodiment where ciphertext data of 200 bits is inputted in the data decryption apparatus 20. Components which are the same as those in the data decryption apparatus 20 of Second Embodiment shown in FIG. 13 are given the same numbers. Components whose functions are the same as those in the data decryption apparatus 20 of Second Embodiment are not explained here. The data decryption apparatus 20 of Fourth Embodiment includes a block dividing unit 201, a block storage unit 202, a subkey generation unit 204, first to fourth decryption units 205a-205d, first to fourth encryption units 201i-205l, a fraction data processing unit 206, a block integration unit 207, and a block merging unit 208. The first encryption unit 205i generates a first intermediate block from a chain block stored in the block storage unit 202 using a first subkey. The second to fourth encryption units 205j-205l generate second and third intermediate blocks and a cryptographic-processed block from the first to third intermediate blocks using the second to fourth subkeys, respectively. The block merging unit 208 merges the cryptographic-processed block generated by the fourth encryption unit 205l with a fourth intermediate block generated by the fourth decryption unit 205d to generate a plaintext block. In the present example, for processing a first ciphertext block, an exclusive-OR operation is performed, for each corresponding bit, on a 64-bit first cryptographic-processed block generated from an initial value IV of the chain block and a 64-bit fourth intermediate block generated from the first ciphertext block, and as a result a 64-bit first plaintext block is generated. For processing second and third ciphertext blocks, an exclusive-OR operation is performed, for each corresponding bit, on 64-bit second and third cryptographic-processed blocks which have been generated from each chain block generated during the processing of the first and second ciphertext blocks and each 64-bit fourth intermediate block generated from the second and third ciphertext blocks, and as a result 64-bit second and third plaintext blocks are generated, respectively. The fraction data processing unit 206 receives fraction ciphertext data from the block dividing unit 201, and generates fraction plaintext data whose number of bits is the same as the fraction ciphertext data using the cryptographic-processed block generated by the fourth encryption unit 205l. The fraction data processing unit 206 includes a data matching unit 206a and a fraction data merging unit 206b. The data matching unit 206a generates fraction cryptographic-processed data whose number of bits is the same as the fraction ciphertext data from the cryptographic-processed block generated by the fourth encryption unit 205l. In the present example, the fraction ciphertext data is 8 bits, so that the data matching unit 206a generates fraction cryptographic-processed data which is composed of, for example, highest 8 bits of the cryptographic-processed block generated by the Fourth encryption unit 205l. The fraction data merging unit 206b merges the fraction cryptographic-processed data with the fraction ciphertext data to generate the fraction plaintext data. In the present example, an exclusive-OR operation is performed on the 8-bit fraction cryptographic-processed data and the 8-bit fraction ciphertext is data for each corresponding bit to generate 8-bit fraction plaintext data. It should be noted here that the fraction data processing unit 206 may have the same function as that of Second Embodiment. Operation Operation of Data Encryption Apparatus 10 FIG. 22 is a flowchart showing the cryptographic processing of the data encryption apparatus 10 of Fourth Embodiment of the present invention. Here, the same example as in the First Embodiment is used, wherein the cryptographic processing is performed according to the DES algorithm in the data encryption apparatus 10 where 200-bit plaintext data is inputted and the initial value IV of the chain block is stored in the block storage unit 102 in advance. Steps which are the same as those in the operation of the data encryption apparatus 10 of the Second Embodiment shown in FIG. 14 are given the same numbers, and are not explained here. (1)-(3) The same as the Second Embodiment (Steps 101, S102, and S301; first time). (4) The first encryption unit 105a generates first intermediate block from the chain block stored in the block storage unit 102 using the first subkey (Step S701). In the present example, a first intermediate block is generated from the initial value IV of the chain block (Step S701: first time). (5) The second to fourth encryption units 105b-105d generate second and third intermediate blocks and a cryptographic-processed block from the first to third intermediate blocks using the second to fourth subkeys (Step S702). In the present example, second and third intermediate blocks and a first cryptographic-processed block are generated from the first to third intermediate blocks corresponding to the initial value IV of the chain block, respectively (Step S702: first time). (6) The block merging unit 108 merges the cryptographic-processed block with a plaintext block to generate a fourth intermediate block (Step S703). In the present example, an exclusive-OR operation is performed on the 64 bit first cryptographic-processed block and the 64-bit first plaintext block for each corresponding bit to generate a 64-bit fourth intermediate block (Step S703: first time). (7)-(13) The same as the Second Embodiment (Steps S107-S110: first time, Steps S101, S102, and S301: second time). (14) In Step S701, a first intermediate block is generated from the 64-bit chain block generated during the processing of the first plaintext block in the present example (Step S701: second time). (15) In Step S702, second and third intermediate blocks and a second cryptographic-processed block are generated from the first to third intermediate blocks corresponding to the chain block generated during the processing of the first plaintext block respectively, in the present example (Step S702: second time). (16) In Step S703, an exclusive-OR operation is performed on the 64-bit second cryptographic-processed block and the 64-bit second plaintext block for each corresponding bit to generate a 64-bit fourth intermediate block in the present example (Step S703: second time). (17)-(23) The same as the Second Embodiment (Steps S107-S110: second time, Steps S101, S102, and S301: third time). (24) In Step S701, a first intermediate block is generated from the 64-bit chain block generated during the processing of the second plaintext block in the present example (Step S701: third time). (25) In Step S702, second and third intermediate blocks and a third cryptographic-processed block are generated from the first to third intermediate blocks corresponding to the chain block generated during the processing of the second plaintext block respectively, in the present example (Step S702: third time). (26) In Step S703, an exclusive-OR operation is performed on the 64-bit third cryptographic-processed block and the 64-bit third plaintext block for each corresponding bit to generate a 64-bit fourth intermediate block in the present example (Step S703: third time). (27)-(34) The same as the Second Embodiment (Steps S107-S110:. third time, Step S101: fourth time, Steps S111-S113). Operation of Data Decryption Apparatus 20 FIG. 23 is a flowchart showing the cryptographic processing of the data decryption apparatus 20 of Fourth Embodiment of the present invention. The operation of the data decryption apparatus 20 is inverse conversion of the operation of the data encryption apparatus 10. Here, the same example as in the First Embodiment is used, wherein the cryptographic processing is performed according to the DES algorithm in the data decryption apparatus 20 where 200-bit ciphertext data is inputted and the initial value IV of the chain block is stored in the block storage unit 202 in advance. Steps which are the same as those in the operation of the data decryption apparatus 20 of the Second Embodiment shown in FIG. 15 are given the same numbers, and are not explained here. (1)-(5) The same as the Second Embodiment (Steps S201, S202, S401, S205, and S206: first time). (6) The first encryption unit 205i generates a first intermediate block from the chain block stored in the block storage unit 202 using the first subkey (Step S801). In the present example, a first intermediate block is generated from the initial value IV of the chain block (Step S801: first time). (7) The second to fourth encryption units 205j-205l generate second and third intermediate blocks and a cryptographic-processed block from the first to third intermediate blocks using the second to fourth subkeys, respectively (Step S802). In the present example, second and third intermediate blocks and a first cryptographic-processed block are generated from the first to third intermediate blocks corresponding to the initial value IV of the chain block (Step S802: first time). (8) The block merging unit 208 merges the cryptographic-processing block with the fourth intermediate block to generate a plaintext block (Step S803). In the present example, an exclusive-OR operation is performed, for each corresponding bit, on the 64-bit first cryptographic-processed block and the 64-bit fourth intermediate block corresponding to the first ciphertext block to generate a 64-bit first plaintext block (Step S803: first time). (9)-(15) The same as the Second Embodiment (Step S207 and S210: first time, Steps S201, S202, S401, S205, and S206: second time). (16) In Step S801, a first intermediate block is generated from the 64-bit chain block generated during the processing of the first ciphertext block in the present example (Step S801: second time). (17) In Step S802, second and third intermediate blocks and a second cryptographic-processed block are generated from the first to third intermediate blocks corresponding to the chain block generated during the processing of the first ciphertext block respectively, in the present example (Step S802: second time). (18) In Step S803, an exclusive-OR operation is performed on the 64-bit second cryptographic-processed block and the 64-bit fourth intermediate block corresponding to the second ciphertext block for each corresponding bit to generate a 64-bit second plaintext block in the present example (Step 803: second time). (19)-(25) The same as the Second Embodiment (Steps S207 and S210: second time, Steps S201, S202, S401, S205, and S206: third time). (26) In Step S801, a first intermediate block is generated from the 64-bit chain block generated during the processing of the second ciphertext block in the present example (Step S801: third time). (27) In Step S802, second and third intermediate blocks and a third cryptographic-processed block are generated from the first to third intermediate blocks corresponding to the chain block generated during the processing of the second ciphertext block respectively, in the present example (Step S802: third time). (28) In Step S803, an exclusive-OR operation is performed on the 64-bit third cryptographic-processed block and the 64-bit fourth intermediate block corresponding to the third ciphertext block for each corresponding bit to generate a 64-bit third plaintext block, in the present example (Step S803: third time). (29)-(34) The same as the Second Embodiment (Steps S207 and S210: third time, Step S201: fourth time, Steps S211-S213). In the cryptographic processing apparatus of Fourth Embodiment, an intermediate block generated when the cryptographic processing is performed on a present block is stored as a chain block. When the cryptographic processing is performed on a next block, the chain block on which the cryptographic processing is performed is merged with a plaintext block or a cryptographic-processed block. Thus, the chain block is renewed each time the cryptographic processing is performed. Fifth Embodiment Fifth Embodiment of the present invention is different from the Fourth Embodiment only in that a block which is obtained by performing cryptographic processing on a chain block is stored as the new chain block, while in Fourth Embodiment a merged block or a block which is not yet merged is stored as the new chain block. Construction The construction of an encrypted communication system of the Fifth Embodiment is the same as that of First Embodiment, and is thereby not explained here. Construction of Data Encryption Apparatus 10 FIG. 24 shows the detailed construction of a data encryption apparatus 10, which is shown in FIG. 2, of Fifth Embodiment of the present invention. Components which are the same as those in the data encryption apparatus 10 of the Second Embodiment shown in FIG. 12 are given the same numbers. Components whose functions are the same as those in the data encryption apparatus 10 of the Second Embodiment are not explained here. The data encryption apparatus 10 of the Fifth Embodiment includes a block dividing unit 101, a block storage unit 102, a subkey generation unit 104, first to eighth encryption units 105a-105h, a fraction data processing unit 106, a block integration unit 107, and a block merging unit 108. Here the same example is used as in the First Embodiment where plaintext data of 200 bits is inputted in the data encryption apparatus 10. The first encryption unit 105a generates a first intermediate block not from a merged plaintext block but from a chain block stored in the block storage unit 102. The first to fourth encryption units 105a-105d have the same functions as those of the Second Embodiment. Here, first to fourth intermediate blocks which correspond to each chain block are generated from the chain block. The block merging unit 108 merges the fourth intermediate block generated by the fourth encryption unit 105d with a plaintext block to generate a merged plaintext block. In the present example, for processing a first plaintext block, an exclusive-OR operation is performed, for each corresponding bit, on the 64-bit first plaintext block and a 64-bit fourth intermediate block generated from an initial value IV of the chain block. For processing second and third plaintext blocks, an exclusive-OR operation is performed, for each corresponding bit, on each of the 64-bit second and third plaintext blocks and a 64-bit fourth intermediate block generated during the processing of the immediately preceding plaintext block, respectively. The fifth encryption unit 105e generates a fifth intermediate block not from the fourth intermediate block but from the merged plaintext block generated by the block merging unit 108. The fifth to eighth encryption units 105e-105h have the same functions as those of the Second Embodiment. In the pre | ||||||
