Embodiments set forth herein relate to data encryption and decryption technology.
If data is encrypted using a conventional block encryption algorithm, when an cryptographic key is exposed to an attacker, the encrypted data may be decrypted, and thus, the data may be exposed. Accordingly, protecting/managing the cryptographic key is a very important issue.
Generally, in data encryption using a block cipher, the length of an cryptographic key, the size of an encrypted block, and a number of rounds are factors influencing security. Among such factors, a mode of operation in which a message is divided and encrypted in units of blocks plays an important role. In a block encryption algorithm employing the mode of operation, encryption is performed in units of blocks and the same cryptographic key is used for all the blocks.
However, in the data encryption using the conventional block encryption algorithm, the number of encrypted data blocks increases as the length of data to be encrypted increases. Thus, the data is encrypted using the encryption algorithm a number of times corresponding to the number of the encrypted data blocks. Accordingly, since a data encryption speed decreases as the amount of data increases, it is difficult to use the data encryption using the conventional block encryption algorithm when a large amount of data is encrypted, i.e., when encryption speed is important.
Embodiments set forth herein are directed to a new technique for encrypting data and decrypting the ciphertext data using a block cipher scheme and an encoding scheme.
According to one aspect of the present embodiments, a data encryption apparatus includes a divider configured to divide data into a plurality of plaintext blocks; an encryptor configured to encrypt at least one among some blocks of the plurality of plaintext blocks and an initial value for encrypting the data using an cryptographic key-based block encryption scheme; and an encoder configured to encode remaining plaintext blocks, which are not encrypted by the block encryption scheme, using a non-cryptographic key-based encoding scheme.
The block encryption scheme may include an encryption scheme using a symmetric key or an asymmetric key.
The block encryption scheme may include a white box-based encryption scheme.
The non-cryptographic key-based encoding scheme may include an encoding scheme using at least one among a logical operation, a one-way function, a one-way permutation, and a logical function.
The initial value may include an initialization vector or a counter value.
The encryptor may encrypt the some blocks using the initialization vector or the counter value.
The encoder may encode the remaining plaintext blocks using the initialization vector or the counter value.
The encoder may sequentially encode each of the remaining plaintext blocks using a previously generated ciphertext block.
The encoder may sequentially encode each of the remaining plaintext blocks using a previously generated ciphertext block and a plaintext block used to generate the previously generated ciphertext block.
According to another aspect of the present embodiments, a data decryption apparatus includes a decryptor configured to decrypt some blocks of encrypted data using an cryptographic key-based block decryption scheme, and a decoder configured to decode remaining blocks of the encrypted data using a non-cryptographic key-based decoding scheme.
The block decryption scheme may include a decryption scheme using a symmetric key or an asymmetric key.
The block decryption scheme may include a white box-based decryption scheme.
The non-cryptographic key-based decoding scheme may include a decoding scheme using at least one among a logical operation, a one-way function, a one-way permutation, and a logical function.
The decoder may decode the remaining blocks using an initialization vector or a counter value used to generate the encrypted data.
The decoder may sequentially decode each of the remaining blocks using a ciphertext block used to generate a previously generated plaintext block.
The decoder may sequentially decode each of the remaining blocks using a previously generated plaintext block and a ciphertext block used to generate the previously generated plaintext block.
According to another aspect of the present embodiments, a data encryption method includes dividing data into a plurality of plaintext blocks; encrypting at least one among some blocks of the plurality of plaintext blocks and an initial value for encrypting the data using an cryptographic key-based block encryption scheme; and encoding remaining plaintext blocks using a non-cryptographic key-based encoding scheme.
The block encryption scheme may include an encryption scheme using a symmetric key or an asymmetric key.
The block encryption scheme may include a white box-based encryption scheme.
The non-cryptographic key-based encoding scheme may include an encoding scheme using at least one among a logical operation, a one-way function, a one-way permutation, and a logical function.
The initial value may include an initialization vector or a counter value.
The encrypting of at least one among some blocks of the plurality of plaintext blocks and the initial value for encrypting the data may include encrypting the some blocks using the initialization vector or the counter value.
The encoding of the remaining plaintext blocks may include encoding the remaining blocks using the initialization vector or the counter value.
The encoding of the remaining plaintext blocks may include sequentially encoding each of the remaining blocks using a previously generated ciphertext block.
The encoding of the remaining plaintext blocks may include sequentially encoding each of the remaining blocks using a previously generated ciphertext block and a plaintext block used to generate the previously generated ciphertext block.
According to another aspect of the present embodiments, a data decryption method includes decrypting some blocks of encrypted data using an cryptographic key-based block decryption scheme, and decoding remaining blocks of the encrypted data using a non-cryptographic key-based decoding scheme.
The block decryption scheme may include a decryption scheme using a symmetric key or an asymmetric key.
The block decryption scheme may include a white box-based decryption scheme.
The non-cryptographic key-based decoding scheme may include a decoding scheme using at least one among a logical operation, a one-way function, a one-way permutation, and a logical function.
The decoding of the remaining blocks may include generating plaintext blocks of the remaining blocks using an initialization vector or a counter value used to generate the encrypted data.
The decoding of the remaining blocks may include sequentially decoding each of the remaining blocks using a ciphertext block used to generate a previously generated plaintext block.
The decoding of the remaining blocks may include sequentially decoding each of the remaining blocks using a previously generated plaintext block and a ciphertext block used to generate the previously generated plaintext block.
According to another aspect of the present embodiments, there is provided a computer program stored in a recording medium in association with hardware, the computer program causing a computer to execute: dividing data into a plurality of plaintext blocks; encrypting at least one among some blocks of the plurality of plaintext blocks and an initial value for encrypting the data using an cryptographic key-based block encryption scheme; and encoding remaining plaintext blocks using a non-cryptographic key-based encoding scheme.
According to another aspect of the present embodiments, there is provided a computer program stored in a recording medium in association with hardware, the computer program causing a computer to execute: decrypting some blocks of encrypted data using an cryptographic key-based block decryption scheme; and decoding remaining blocks of the encrypted data using a non-cryptographic key-based decoding scheme.
According to embodiments of the present embodiments, some ciphertext blocks are generated using a block encryption scheme and remaining ciphertext blocks are processed using an encoding scheme to generate encrypted data, thereby reducing the amount of calculation for data encryption. Accordingly, a large amount of data can be quickly encrypted.
Hereinafter, exemplary embodiments of the present embodiments will be described with reference to the accompanying drawings. The following descriptions are provided to assist comprehensive understanding of methods, apparatuses, and/or systems described herein. However, the following descriptions are merely examples, and the present embodiments is not limited thereto.
In describing embodiments of the present embodiments, well-known techniques related to the present embodiments are not described in detail if it is determined that they would obscure the embodiments due to unnecessary detail. Terms used herein have been defined in consideration of functions of the present embodiments, and may vary according to an intention of a user or an operator, a precedent, or the like. Accordingly, it will be understood that the terms should be interpreted as having a meaning that is consistent with their meaning in the context of the specification. The terms used in the detailed description are for the purpose of describing embodiments of the present embodiments only and is not intended to be limiting of the present embodiments. As used herein, the singular forms are intended to include the plural forms as well, unless the context clearly indicates otherwise. It will be further understood that the terms “comprise,” “comprising,” “include” and/or “including,” when used herein, specify the presence of stated features, integers, steps, operations, elements, and/or groups thereof, but do not preclude the presence or addition of one or more other features, integers, steps, operations, elements, and/or groups thereof.
Referring to
The data encryption apparatus 100 is configured to generate encrypted data (for example, digital ciphertext) by encrypting plaintext data (for example, digital plaintext).
The divider 110 divides plaintext data to be encrypted into a plurality of plaintext blocks. For example, the divider 110 may generate a plurality of plaintext blocks by dividing the plaintext data in units of blocks having a certain size. In this case, for example, a padding process of padding a predefined value in the last block may be performed to equalize the sizes of the plurality of plaintext blocks.
The encryptor 130 encrypts at least one among some of the plurality of plaintext blocks and an initial value for encryption using an cryptographic key-based block encryption scheme.
The cryptographic key-based block encryption scheme may include various types of encryption schemes for encrypting data in units of blocks using a symmetric key or an asymmetric key. For example, the encryptor 130 may generate a ciphertext block using a well-known block encryption algorithm using a symmetric key or an asymmetric key, such as an advanced encryption standard (AES), a data encryption standard (DES), 3DES, Blowfish, an international data encryption algorithm (IDEA), RC2, RC5, RC6, SEED, ARIA, Rivest Shamir Adleman (RSA), a digital signature algorithm (DSA), an elliptic curve cryptosystem (ECC), Elgamal, a white box-based encryption algorithm, etc.
The initial value may include, for example, an initialization vector (IV) that is an arbitrary bit string or a counter value that increases by 1 each time a plaintext block is encrypted. In this case, the encryptor 130 may generate ciphertext blocks by encrypting the initial value (for example, an initialization vector or an initial counter value) using the cryptographic key-based block encryption scheme according to a mode of operation which is to be described below, or by encrypting some of the plurality of plaintext blocks using the initial value (for example, an initialization vector or an initial counter value) according to the cryptographic key-based block encryption scheme.
The encoder 150 encodes the other plaintext blocks, which have not been encrypted by the encryptor 130, using a non-cryptographic key-based encoding scheme.
In one embodiment, the non-cryptographic key-based encoding scheme may include various types of encoding schemes that may hide data without using an cryptographic key. For example, the non-cryptographic key-based encoding scheme may include an encoding scheme using at least one among a logical operation, a one-way function, a one-way permutation, and a logical function consisting of a plurality of logical operations.
According to an embodiment of the present embodiments, the encoder 150 may generate ciphertext blocks by encoding plaintext blocks, which have not been encrypted by the encryptor 130, using the initial value (for example, an initialization value or a counter value) according to a mode of operation which is to be described below.
According to an embodiment of the present embodiments, the encoder 150 may generate ciphertext blocks by sequentially encoding the plaintext blocks, which have not been encrypted by the encryptor 130, according to an operation mode that is to be described below, using either a ciphertext block generated in a previous operation or the ciphertext block generated in the previous operation and a plaintext block used to generate the ciphertext block.
According to an embodiment of the present embodiments, the encryptor 130 and the encoder 150 may encrypt plaintext data using a method similar to a conventional mode of operation for block encryption. For example, the encryptor 130 and the encoder 150 may encrypt plaintext data using one mode of operation among an electronic code book (ECB) mode, a cipher block chaining (CBC) mode, a propagating cipher block chaining (PCBC) mode, a cipher feedback (CFB) mode, an output feedback (OFB), and a counter (CTR) mode. However, one encryption algorithm is applied to encrypting plaintext data in the conventional mode of operation used for a block encryption algorithm, whereas a block encryption scheme and an encoding scheme are applied to encrypting plaintext data in the mode of operation according to an embodiment of the present embodiments. That is, data encrypted according to an embodiment of the present embodiments includes ciphertext blocks generated using the cryptographic key-based block encryption scheme and ciphertext blocks generated using the non-cryptographic key-based encoding scheme. A specific operation according to a mode of operation will be described in detail below.
According to an embodiment of the present embodiments, the data encryption apparatus 100 may further include an initial value generator 170 configured to generate the initial value when encrypted data is generated according to a mode of operation using an initial value (for example, an initialization vector or a counter value).
The divider 110, the encryptor 130, the encoder 150, and the initial value generator 170 are classified according to functions performed in the data encryption apparatus 100. In the embodiment of
In the above-described example, the encryptor 130 performs encryption using a well-known specific encryption algorithm but embodiments are not limited thereto. For example, on the basis of a predetermined operation mode, the encryptor 130 and the encoder 150 may encrypt plaintext data using an encryption algorithm designed to encrypt some of plaintext data using a symmetric key or an asymmetric key according to a block encryption scheme and encode the remaining plaintext data according to a certain encoding scheme that does not use an cryptographic key.
In one embodiment, the divider 110, the encryptor 130, the encoder 150, and the initial value generator 170 may be implemented in a computing apparatus including one or more processors and a computer-readable recording medium connected to the processor. The computer-readable recording medium may be located inside or outside the processor, and connected to the processor using various well-known means. The processor located in the computing apparatus may control the computing apparatus to operate according to an exemplary embodiment described herein. For example, the processor may execute a command stored in the computer-readable recording medium, and the command stored in the computer-readable recording medium may be configured, when executed by the processor, to cause the computing apparatus to perform operations according to an exemplary embodiment described herein.
The data decryption apparatus 200 of
Referring to
The decryptor 210 may decrypt some blocks of encrypted data using an cryptographic key-based block decryption scheme. For example, as described above with reference to
The encryption-based block decryption scheme may include various types of decryption methods of decrypting data in units of blocks using a symmetric key or an asymmetric key. For example, the decryptor 210 may decrypt some of the ciphertext blocks using a well-known block decryption algorithm using a symmetric key or an asymmetric key, such as the AES, the DES, the 3DES, Blowfish, the IDEA, RC2, RC5, RC6, SEED, ARIA, RSA, the DSA, the ECC, ELGmal, the white box-based decryption algorithm, etc.
The decoder 230 may decode ciphertext blocks of encrypted data that have not been decrypted by the decryptor 210 using a non-cryptographic key-based decoding scheme. The non-cryptographic key-based decoding scheme may include a decoding scheme employing at least one among a logical operation, a one-way function, a one-way permutation, and a logical function.
According to an embodiment of the present embodiments, the decoder 230 may generate plaintext blocks by decoding ciphertext blocks, which have not been decrypted by the decryptor 210, using an initial value or a counter value according to a mode of operation mode for decrypting encrypted data.
According to an embodiment of the present embodiments, the decoder 230 may generate plaintext blocks by sequentially decoding ciphertext blocks, which have not been decrypted by the decryptor 210, according to the mode of operation for decrypting encrypted data using either a ciphertext block used to generate a plaintext block generated in a previous operation or the plaintext generated in the previous operation and the ciphertext block used to generate the previous plaintext block.
According to an embodiment of the present embodiments, the decryptor 210 and the decoder 230 may decrypt encrypted data using the same mode of operation as that used by the data encryption apparatus 100 to generate encrypted data. For example, the decryptor 210 and the decoder 230 may decrypt data encrypted using one operation mode among an ECB mode, a CBC mode, a PCBC mode, a CFB mode, an OFB mode, and a CTR mode, as will be described in detail below.
According to an embodiment of the present embodiments, the data decryption apparatus 200 may further include an initial value generator 250 configured to generate an initial value when plaintext data is generated according to a mode of operation using an initial value (for example, an initialization vector or a counter value).
The decryptor 210, the decoder 230, and the initial value generator 250 are classified according to functions performed in the data decryption apparatus 200. In the embodiment of
In the above-described example, the decryptor 210 performs decryption using a well-known specific decryption algorithm but embodiments are not limited thereto. For example, on the basis of a predetermined operation mode, the decryptor 210 and the decoder 230 may generate plaintext data from encrypted data using a decryption algorithm designed to decrypt some of encrypted data using a symmetric key or an asymmetric key according to a block decryption scheme and decode the remaining encrypted data according to a certain decoding scheme that does not use an cryptographic key
In one embodiment, the decryptor 210, the decoder 230, and the initial value generator 250 may be implemented in a computing apparatus including one or more processors and a computer-readable recording medium connected to the processor. The computer-readable recording medium may be located inside or outside the processor, and connected to the processor using various well-known means. The processor located in the computing apparatus may control the computing apparatus to operate according to an exemplary embodiment described herein. For example, the processor may execute a command stored in the computer-readable recording medium, and the command stored in the computer-readable recording medium may be configured, when executed by the processor, to cause the computing apparatus to perform operations according to an exemplary embodiment described herein.
Examples of operations of the data encryption apparatus 100 and the data decryption apparatus 200 according to each mode of operation will be described in more detail below. In the following embodiments, it will be described for convenience of explanation that an AES algorithm is used as a block encryption scheme and an exclusive-or (XOR) operation or an XOR operation and a logical function are used as an encoding scheme. However, embodiments are not limited thereto.
Furthermore, in the following embodiments, it will be described that a block encryption scheme is used to generate first ciphertext. However, embodiments are not limited thereto, and two or more plaintext blocks may be encrypted using the block encryption scheme in consideration of encryption speed, etc.
1. Example using ECB Mode
According to an embodiment of the present embodiments, as illustrated in
As illustrated in
As illustrated in
Referring to
2. Example using CBC Mode
According to an embodiment of the present embodiments, as illustrated in
Referring to
Then, the encoder 150 may generate ciphertext blocks 2 to 4 by performing the XOR operation on each of plaintext blocks 2 to 4 and a ciphertext block generated right before each of the ciphertext blocks 2 to 4 is generated.
In detail, the encryption operation illustrated in
C
1
=E
BLOCK(P1 XOR IV) [Equation 1]
C
i
=P
i XOR Ci−1(i≥2),
where Ci represents an ith ciphertext block, Pi represents an ith plaintext block, IV represents an initialization vector, EBLOCK represents a block encryption algorithm, and XOR represents the XOR operation performed on each of the blocks (for example, a bitwise XOR operation when each of the blocks is a bit sequence).
As illustrated in
Referring to
Then, the decoder 230 may generate the plaintext blocks 2 to 4 by performing the XOR operation on each of the ciphertext blocks 2 to 4 and the ciphertext block generated right before each of the ciphertext blocks 2 to 4 is generated.
In detail, the decryption operation illustrated in
P
1
=D
BLOCK(C1)XOR IV [Equation 2]
P
i
=C
i XOR Ci−1(i≥2),
where Ci represents an ith ciphertext block, Pi represents an ith plaintext block, IV represents an initialization vector, DBLOCK represents a block decryption algorithm, XOR represents an XOR operation performed between blocks (for example, a bitwise XOR operation when each of the blocks is a bit sequence).
According to another embodiment of the present embodiments, the data encryption apparatus 100 may encrypt data using the CBC mode as illustrated in
Referring to
Then, the encoder 150 may generate ciphertext blocks 2 to 4 by performing the XOR operation on each of plaintext blocks 2 to 4 and a ciphertext block generated right before each of the ciphertext blocks 2 to 4 is generated, and applying a logical function to a result of performing the XOR operation.
In detail, the encryption operation illustrated in
C
1
=E
BLOCK(P1 XOR IV) [Equation 3]
C
i
=F(Pi XOR Ci−1)(i≥2),
where Ci represents an ith ciphertext block, Pi represents an ith plaintext block, IV represents an initialization vector, EBLOCK represents a block encryption algorithm, F represents a logical function and XOR represents an XOR operation performed between blocks (for example, a bitwise XOR operation when each of the blocks is a bit sequence).
As illustrated in
Referring to
Then, the decoder 230 may generate the plaintext blocks 2 to 4 by applying a logical function to each of the ciphertext blocks 2 to 4, and performing the XOR operation on a result of applying the logical function to each of the ciphertext blocks 2 to 4 and the ciphertext block generated right before each of the ciphertext blocks 2 to 4 is generated.
In detail, the decryption operation illustrated in
P
1
=D
BLOCK(C1)XOR IV [Equation 4]
P
i
=F(Ci)XOR Ci−1(i≥2),
where Ci represents an ith ciphertext block, Pi represents an ith plaintext block, IV represents an initialization vector, DBLOCK represents a block decryption algorithm, F represents a logical function, and XOR represents an XOR operation performed between blocks (for example, a bitwise XOR operation when each of the blocks is a bit sequence).
According to another embodiment of the present embodiments, the data encryption apparatus 100 may encrypt data using the CBC mode as illustrated in FIG.
6
a.
Referring to
Then, the encoder 150 may generate a ciphertext block 1 by performing the XOR operation on a plaintext block 1 and the initialization vector IV, and applying a logical function to a result of performing the XOR operation.
Then, the encoder 150 may generate ciphertext blocks 2 to 4 by performing the XOR operation on each of plaintext blocks 2 to 4 and a ciphertext block generated right before each of the ciphertext blocks 2 to 4 is generated, and applying a logical function to a result of performing the XOR operation.
In detail, the encryption operation illustrated in
C
0
=E
BLOCK(IV) [Equation 5]
C
1
=F(P1 XOR IV)
C
i
=F(Pi XOR Ci−1)(i≥2),
where Ci represents an ith ciphertext block, Pi represents an ith plaintext block, IV represents an initialization vector, EBLOCK represents a block encryption algorithm, F represents a logical function, and XOR represents an XOR operation performed between blocks (for example, a bitwise XOR operation when each of the blocks is a bit sequence).
As illustrated in
Referring to
Then, the decoder 230 may generate the first plaintext block by applying a logical function to the ciphertext block 1, and then, performing the XOR operation on a result of applying the logical function to the ciphertext block 1 and the initialization vector IV.
Then, the decoder 230 may generate the plaintext blocks 2 to 4 by applying a logical function to each of the ciphertext blocks 2 to 4, and then, performing the XOR operation on a result of applying the logical function to each of the ciphertext blocks 2 to 4 and the ciphertext block generated right before each of the ciphertext blocks 2 to 4 is generated.
In detail, the decryption operation illustrated in
IV=D
BLOCK(C0) [Equation 6]
P
1
=F(C1)XOR IV
P
i
=F(Ci)XOR Ci−1(i≥2),
where Ci represents an ith ciphertext block, Pi represents an ith plaintext block, IV represents an initialization vector, DBLOCK represents a block decryption algorithm, F represents a logical function, and XOR represents an XOR operation performed between blocks (for example, a bitwise XOR operation when each of the blocks is a bit sequence).
3. Example using PCBC Mode
According to an embodiment of the present embodiments, as illustrated in
Referring to
Then, the encoder 150 may generate ciphertext blocks 2 to 4 by performing the XOR operation on each of plaintext blocks 2 to 4 together with a ciphertext block generated and a plaintext block used right before each of the ciphertext blocks 2 to 4 is generated.
In detail, the encryption operation illustrated in
C
1
=E
BLOCK(P1 XOR IV) [Equation 7]
C
i
=P
i XOR Pi−1 XOR Ci−1(i≥2),
where Ci represents an ith ciphertext block, Pi represents an ith plaintext block, IV represents an initialization vector, EBLOCK represents a block encryption algorithm, and XOR represents an XOR operation performed between blocks (for example, a bitwise XOR operation when each of the blocks is a bit sequence).
As shown as an example in
Referring to
Then, the decoder 230 may generate the plaintext blocks 2 to 4 by performing the XOR operation on each of the ciphertext blocks 2 to 4 together with the plaintext block generated and the ciphertext block used right before each of the plaintext blocks 2 to 4 is generated.
In detail, the decryption operation illustrated in
P
1
=D
BLOCK(C1)XOR IV [Equation 8]
P
i
=C
i XOR Ci−1 XOR Pi−1(i≥2),
where Ci represents an ith ciphertext block, Pi represents an ith plaintext block, IV represents an initialization vector, DBLOCK represents a block decryption algorithm, and XOR represents an XOR operation performed between blocks (for example, a bitwise XOR operation when each of the blocks is a bit sequence).
According to another embodiment of the present embodiments, the data encryption apparatus 100 may encrypt data using the PCBC mode as illustrated in
Referring to
Then, the encoder 150 may generate ciphertext blocks 2 to 4 by performing the XOR operation on each of plaintext blocks 2 to 4 together with the ciphertext block generated and the plaintext block used right before each of the ciphertext blocks 2 to 4 is generated, and then, applying a logical function to a result of performing the XOR operation.
In detail, the encryption operation illustrated in
C
1
=E
BLOCK(P1 XOR IV) [Equation 9]
C
i
=F(Pi XOR Pi−1 XOR Ci−1)(i≥2),
where Ci represents an ith ciphertext block, Pi represents an ith plaintext block, IV represents an initialization vector, EBLOCK represents a block encryption algorithm, F represents a logical function, and XOR represents an XOR operation performed between blocks (for example, a bitwise XOR operation when each of the blocks is a bit sequence).
As illustrated in
Referring to
Then, the decoder 230 may generate the plaintext blocks 2 to 4 by applying a logical function to each of the ciphertext blocks 2 to 4, and then, performing the XOR operation on a result of applying the logical function to each of the ciphertext blocks 2 to 4, together with the plaintext block generated and the ciphertext block used right before each of the plaintext blocks 2 to 4 is generated.
In detail, the decryption operation illustrated in
P
1
=D
BLOCK(C1)XOR IV [Equation 10]
P
i
=F(Ci)XOR Ci−1 XOR Pi−1(i≥2),
where Ci represents an ith ciphertext block, Pi represents an ith plaintext block, IV represents an initialization vector, DBLOCK represents a block decryption algorithm, F represents a logical function, and XOR represents an XOR operation performed between blocks (for example, a bitwise XOR operation when each of the blocks is a bit sequence).
According to another embodiment of the present embodiments, the data encryption apparatus 100 may encrypt data using the PCBC mode as shown as an example in
Referring to
Then, the encoder 150 may generate a ciphertext block 1 by performing the XOR operation on the plaintext block 1 and the initialization vector IV, and then, applying a logical function to a result of performing the XOR operation.
Thereafter, the encoder 150 may generate ciphertext blocks 2 to 4 by performing the XOR operation on each of plaintext blocks 2 to 4 together with the ciphertext block generated and the plaintext block used right before each of the ciphertext blocks 2 to 4 is generated, and then, applying a logical function to a result of performing the XOR operation.
In detail, the encryption operation illustrated in
C
0
=E
BLOCK(IV) [Equation 11]
C
1
=F(P1 XOR IV)
C
i
=F(Pi XOR Pi−1 XOR Ci−1)(i≥2),
where Ci represents an ith ciphertext block, Pi represents an ith plaintext block, IV represents an initialization vector, EBLOCK represents a block encryption algorithm, F represents a logical function, and XOR represents an XOR operation performed between blocks (for example, a bitwise XOR operation when each of the blocks is a bit sequence).
As illustrated in
Referring to
Then, the decoder 230 may generate the first plaintext block (the plaintext block 1) by applying a logical function to the ciphertext block 1, and then, performing the XOR operation on a result of performing the logical function and the initialization vector IV.
Thereafter, the decoder 230 may generate the plaintext blocks 2 to 4 by applying a logical function to each of the ciphertext blocks 2 to 4, and then, performing the XOR operation on a result of applying the logical function to each of the ciphertext blocks 2 to 4, with the plaintext block generated and the ciphertext block used right before each of the plaintext blocks 2 to 4 is generated.
In detail, the decryption operation illustrated in
IV=D
BLOCK(C0) [Equation 12]
P
1
=F(C1)XOR IV
P
i
=F(Ci)XOR Ci−1 XOR Pi−1(i≥2),
where Ci represents an ith ciphertext block, Pi represents an ith plaintext block, IV represents an initialization vector, DBLOCK represents a block decryption algorithm, F represents a logical function, and XOR represents an XOR operation performed between blocks (for example, a bitwise XOR operation when each of the blocks is a bit sequence).
4. Example using CFB Mode
According to an embodiment of the present embodiments, as illustrated in
Referring to
Then, the encoder 150 may generate ciphertext blocks 2 to 4 by performing the XOR operation on each of plaintext blocks 2 to 4 and the ciphertext block generated right before each of the ciphertext blocks 2 to 4 is generated.
In detail, the encryption operation illustrated in
C
1
=E
BLOCK(IV)XOR P1 [Equation 13]
C
i
=P
i XOR Ci−1(i≥2),
where Ci represents an ith ciphertext block, Pi represents an ith plaintext block, IV represents an initialization vector, EBLOCK represents a block encryption algorithm, and XOR represents an XOR operation performed between blocks (for example, a bitwise XOR operation when each of the blocks is a bit sequence).
As illustrated in
Referring to
Then, the decoder 230 may generate the plaintext blocks 2 to 4 by performing the XOR operation on each of the ciphertext blocks 2 to 4 and the ciphertext block generated right before each of the ciphertext blocks 2 to 4 is generated.
In detail, the decryption operation illustrated in
P
1
=D
BLOCK(IV)XOR C1 [Equation 14]
P
i
=C
i XOR Ci−1(i≥2),
where Ci represents an ith ciphertext block, Pi represents an ith plaintext block, IV represents an initialization vector, DBLOCK represents a block decryption algorithm, and XOR represents an XOR operation performed between blocks (for example, a bitwise XOR operation when each of the blocks is a bit sequence).
According to another embodiment of the present embodiments, the data encryption apparatus 100 may encrypt data using the CFB mode as illustrated in
Referring to
Then, the encoder 150 may generate ciphertext blocks 2 to 4 by applying a logical function to the ciphertext block generated right before each of the ciphertext blocks 2 to 4 is generated, and then, performing the XOR operation on a result of applying the logical function to the ciphertext block and each of plaintext blocks 2 to 4.
In detail, the encryption operation illustrated in
C
1
=E
BLOCK(IV)XOR P1 [Equation 15]
C
i
=F(Ci−1)XOR Pi(i≥2),
where Ci represents an ith ciphertext block, Pi represents an ith plaintext block, IV represents an initialization vector, EBLOCK represents a block encryption algorithm, and XOR represents an XOR operation performed between blocks (for example, a bitwise XOR operation when each of the blocks is a bit sequence).
As illustrated in
Referring to
Then, the decoder 230 may generate the plaintext blocks 2 to 4 by applying a logical function to the ciphertext block preceding each of the ciphertext blocks 2 to 4, and then, performing the XOR operation on a result of applying the logical function and each of the ciphertext blocks 2 to 4.
In detail, the decryption operation illustrated in
P
1
=D
BLOCK(IV)XOR C1 [Equation 16]
P
i
=F(Ci−1)XOR Ci(i≥2),
where Ci represents an ith ciphertext block, Pi represents an ith plaintext block, IV represents an initialization vector, DBLOCK represents a block decryption algorithm, and XOR represents an XOR operation performed between blocks (for example, a bitwise XOR operation when each of the blocks is a bit sequence).
According to another embodiment of the present embodiments, the data encryption apparatus 100 may encrypt data using the CFB mode as illustrated in
Referring to
Then, the encoder 150 may generate a first ciphertext block (a ciphertext block 1) by performing the XOR operation on the initialization vector IV and a first plaintext block (a plaintext block 1)
Thereafter, the encoder 150 may generate ciphertext blocks 2 to 4 by applying a logical function to the ciphertext block generated right before each of the ciphertext blocks 2 to 4 is generated, and then, performing the XOR operation on a result of applying the logical function and each of the plaintext blocks 2 to 4.
In detail, the encryption operation illustrated in
C
0
=E
BLOCK(IV) [Equation 17]
C
1
=IV XOR P1
C
i
=F(Ci−1)XOR Pi(i≥2),
where Ci represents an ith ciphertext block, Pi represents an ith plaintext block, IV represents an initialization vector, EBLOCK represents a block encryption algorithm, F represents a logical function, and XOR represents an XOR operation performed between blocks (for example, a bitwise XOR operation when each of the blocks is a bit sequence).
As illustrated in
Referring to
Then, the decoder 230 may generate the first plaintext block (the plaintext block 1) by performing the XOR operation on the initialization vector IV and the ciphertext block 1.
Thereafter, the decoder 230 may generate the plaintext blocks 2 to 4 by applying a logical function to the ciphertext block preceding each of the ciphertext blocks 2 to 4, and then, performing the XOR operation on a result of the applying the logical function and each of the ciphertext blocks 2 to 4.
In detail, the decryption operation illustrated in
IV=D
BLOCK(C0) [Equation 18]
P
1
=IV XOR C1
P
i
=F(Ci−1)XOR Ci(i≥2),
where Ci represents an ith ciphertext block, Pi represents an ith plaintext block, IV represents an initialization vector, DBLOCK represents a block decryption algorithm, F is a logical function, and XOR represents an XOR operation performed between blocks (for example, a bitwise XOR operation when each of the blocks is a bit sequence).
5. Example using OFB Mode
According to an embodiment of the present embodiments, as illustrated in
Referring to
Then, the encoder 150 may generate ciphertext blocks 2 to 4 by repeatedly applying a logical function to a block generated by applying the AES algorithm to the initialization vector IV, and then, performing an XOR operation on a result of repeatedly applying the logical function and each of plaintext blocks 2 to 4.
In detail, the encryption operation illustrated in
O
1
=E
BLOCK(IV) [Equation 19]
C
1
=O
1 XOR P1
O
i
=F(Oi−1)(i≥2)
C
i
=P
i XOR Oi(i≥2),
where EBLOCK represents a block encryption algorithm, IV represents an initialization vector, O1 represents a block generated by applying the block encryption algorithm to the initialization vector IV, Ci represents an ith ciphertext block, Oi represents a block generated by applying a logical function to the O1 i−1 times, Pi represents an ith plaintext block, F represents a logical function, and XOR represents an XOR operation performed between blocks (for example, a bitwise XOR operation when each of the blocks is a bit sequence).
As illustrated in
Referring to
Then, the decoder 230 may generate the plaintext blocks 2 to 4 by repeatedly applying a logical function to the block generated by applying the AES algorithm to the initialization vector IV, and then, performing the XOR operation on a result of repeatedly applying the logical function and each of the ciphertext blocks 2 to 4.
In detail, the decryption operation illustrated in
O
1
=E
BLOCK(IV) [Equation 20]
P
1
=O
1 XOR C1
O
i
=F(Oi−1)(i≥2)
P
i
=C
i XOR Oi(i≥2),
where EBLOCK represents a block encryption algorithm, IV represents an initialization vector, O1 represents a block generated by applying the block encryption algorithm to the initialization vector IV, Ci represents an ith ciphertext block, Oi represents a block generated by applying a logical function to the initialization vector IV i times, Pi represents an ith plaintext block, F represents a logical function, and XOR represents an XOR operation performed between blocks (for example, a bitwise XOR operation when each of the blocks is a bit sequence).
According to another embodiment of the present embodiments, the data encryption apparatus 100 may encrypt data using the OFB mode as illustrated in
Referring to
Then, the encoder 150 may generate ciphertext blocks 1 to 4 by repeatedly applying a logical function to the initialization vector IV, and then, performing the XOR operation on a result generated by repeatedly applying the logical function to the initialization vector IV and each of plain blocks 1 to 4.
In detail, the encryption operation illustrated in
C
0
=E
BLOCK(IV) [Equation 21]
O
1
=F(IV)
O
i
=F(Oi−1)(i≥2)
C
i
=P
i XOR Oi(i≥1),
where Ci represents an ith ciphertext block, Oi represents a block generated by applying a logical function to the initialization vector IV i times, Pi represents an ith plaintext block, IV represents an initialization vector, EBLOCK represents a block encryption algorithm, F represents a logical function, and XOR represents an XOR operation performed between blocks (for example, a bitwise XOR operation when each of the blocks is a bit sequence).
As illustrated in
Referring to
Then, the decoder 230 may generate the plaintext blocks 1 to 4 by repeatedly applying a logical function to the initialization vector IV, and then, performing the XOR operation on a block generated by repeatedly applying the logical function to the initialization vector IV and each of the ciphertext blocks 1 to 4.
In detail, a decryption operation illustrated in
IV=E
BLOCK(C0) [Equation 22]
O
1
=F(IV)
O
i
=F(Oi−1)(i≥2)
P
i
=C
i XOR Oi(i≥1),
where Ci represents an ith ciphertext block, Oi represents a block generated by applying a logical function to the initialization vector IV i times, Pi represents an ith plaintext block, IV represents an initialization vector, EBLOCK represents a block encryption algorithm, F represents a logical function, and XOR represents an XOR operation performed between blocks (for example, a bitwise XOR operation when each of the blocks is a bit sequence).
6. Example using CTR Mode
According to an embodiment of the present embodiments, as illustrated in
Referring to
Then, the encoder 150 may generate a ciphertext block 1 by performing the XOR operation on the initial counter value CTR and a plaintext block 1.
Similarly, the encoder 150 may generate an ith ciphertext block by performing the XOR operation on an ith plaintext block and an ith counter value (for example, CTR+i−1 as illustrated in
In detail, the encryption operation illustrated in
C
0
=E
BLOCK(CTR) [Equation 23]
C
i=(CTR+i−1)XOR Pi(i≥1),
where EBLOCK represents the block encryption algorithm, CTR represents an initial counter value, Ci represents an ith ciphertext block, Pi represents an ith plaintext block, and XOR represents an XOR operation performed between blocks (for example, a bitwise XOR operation when each of the blocks is a bit sequence).
As illustrated in
Referring to
Then, the decoder 230 may generate the plaintext block 1 by performing the XOR operation on the initial counter value CTR and the ciphertext block 1.
Similarly, the decoder 230 may generate the ith plaintext block by performing the XOR operation on the ith ciphertext block and the ith counter value (for example, CTR+i−1 as illustrated in
In detail, the decryption operation illustrated in
CTR=EBLOCK(C0) [Equation 24]
P
i=(CTR+i−1)XOR Ci(i≥1),
where EBLOCK represents a block encryption algorithm, CTR represents an initial counter value, Ci represents an ith ciphertext block, Pi represents an ith plaintext block, and XOR represents an XOR operation performed between blocks (for example, a bitwise XOR operation when each of the blocks is a bit sequence).
According to another embodiment of the present embodiments, the data encryption apparatus 100 may encrypt data using the CTR mode as illustrated in
Referring to
Then, the encoder 150 may generate a ciphertext block 1 by applying a logical function to the initial counter value CTR, and then, performing the XOR operation on a result of applying the function to the initial counter value CTR and a plaintext block 1.
Similarly, the encoder 150 may generate an ith ciphertext block by applying a logical function to an ith counter value (for example, CTR+i−1 as illustrated in
In detail, the encryption operation illustrated in
C
0
=E
BLOCK(CTR) [Equation 25]
C
i
=F(CTR+i−1)XOR Pi(i≥1),
where EBLOCK represents the block encryption algorithm, CTR represents an initial counter value, Ci represents an ith ciphertext block, Pi represents an ith plaintext block, F represents a logical function, and XOR represents an XOR operation performed between blocks (for example, a bitwise XOR operation when each of the blocks is a bit sequence).
As illustrated in
Referring to
Then, the decoder 230 may generate the plaintext block 1 by applying a logical function to the initial counter value CTR, and then, performing the XOR operation on a result of applying the logical function to the initial counter value CTR and the ciphertext block 1.
Similarly, the decoder 230 may generate the ith plaintext block by applying a logical function to the ith counter value (for example, CTR+i−1 as illustrated in
In detail, the decryption operation illustrated in
CTR=EBLOCK(C0) [Equation 26]
P
i
=F(CTR+i−1)XOR Ci(i≥1),
where EBLOCK represents a block encryption algorithm, CTR represents an initial counter value, Ci represents an ith ciphertext block, Pi represents an ith plaintext block, F represents a logical function, and XOR represents an XOR operation performed between blocks (for example, a bitwise XOR operation when each of the blocks is a bit sequence).
According to another embodiment of the present embodiments, the data encryption apparatus 100 may encrypt data using the CTR mode as illustrated in
Referring to
Then, the encoder 150 may generate an ith ciphertext block by applying a logical function to an ith counter value (for example, CTR+i−1 as illustrated in
In detail, the encryption operation illustrated in
C
1
=E
BLOCK(CTR)XOR P1 [Equation 27]
C
i
=F(CTR+i−1)XOR Pi(i≥2),
where EBLOCK represents the block encryption algorithm, CTR represents an initial counter value, Ci represents an ith ciphertext block, Pi represents an ith plaintext block, F represents a logical function, and XOR represents an XOR operation performed between blocks (for example, a bitwise XOR operation when each of the blocks is a bit sequence).
As illustrated in
Referring to
Then, the decoder 230 may generate the ith plaintext block by applying a logical function to the ith counter value (for example, CTR+i−1 as illustrated in FIG. 17b), and then, performing the XOR operation on a result of applying the logical function to the ith counter value and the ith ciphertext block. The decoder 230 may generate plaintext blocks in parallel.
In detail, the decryption operation illustrated in
P
1
=E
BLOCK(CTR)XOR C1 [Equation 28]
P
i
=F(CTR+i−1)XOR Ci(i≥2),
where EBLOCK represents the block encryption algorithm, CTR represents an initial counter value, Ci represents an ith ciphertext block, Pi represents an ith plaintext block, F represents a logical function, and XOR represents an XOR operation performed between blocks (for example, a bitwise XOR operation when each of the blocks is a bit sequence).
The data encryption method of
Referring to
Next, the data encryption apparatus 100 encrypts at least one among some of the plurality of plaintext blocks and an initial value using the cryptographic key-based block encryption scheme (S1820).
Thereafter, the data encryption apparatus 100 encodes the remaining plaintext blocks, which have not been encrypted, using a non-cryptographic key-based encoding scheme (S1830).
The data decryption method of
Referring to
Next, the data encryption apparatus 200 decodes the remaining blocks of the encrypted data, which have not been decrypted, using the non-cryptographic key-based decoding scheme (S1920).
Embodiments may include a computer-readable storage medium having stored therein a program for executing the methods described herein on a computer. The computer-readable storage medium may include program commands, local data files, local data structures, or a combination thereof. The computer-readable storage medium may be specially designed and configured for the present embodiments. Examples of the computer-readable storage medium include magnetic media such as a hard disk, a floppy disk, and a magnetic tape, optical media such as CD-ROM and a DVD, magneto-optical media such as a floptical disk and hardware devices, such as a ROM, a RAM and a flash memory, specially designed to store and carry out programs. Examples of the program commands may include not only a machine language code made by a complier but also high-level language code executable in a computer using by an interpreter or the like.
While exemplary embodiments of the present embodiments have been described above in detail, it may be understood by one of ordinary skill in the art that various changes may be made without departing from the spirit and scope of the present embodiments. Therefore, the scope of the present embodiments should be defined not by the detailed description, but by the appended claims and equivalents thereof.
Number | Date | Country | Kind |
---|---|---|---|
10-2015-0069666 | May 2015 | KR | national |
Filing Document | Filing Date | Country | Kind |
---|---|---|---|
PCT/KR2015/006730 | 6/30/2015 | WO | 00 |