A Modified Feistel Cipher Involving XOR Operation and Modular Arithmetic Inverse of a Key Matrix

In this paper, we have developed a block cipher by modifying the Feistel cipher. In this, the plaintext is taken in the form of a pair of matrices. In one of the relations of encryption the plaintext is multiplied with the key matrix on both the sides. Consequently, we use the modular arithmetic inverse of the key matrix in the process of decryption. The cryptanalysis carried out in this investigation, clearly indicates that the cipher is a strong one, and it cannot be broken by any attack.


INTRODUCTION
In a recent development, we have offered several modifications [1][2][3][4] to the classical Feistel cipher, in which the plaintext is a string containing 64 binary bits.
In all the afore mentioned investigations, we have modified the Feistel cipher by taking the plaintext in the form of a matrix of size mx(2m),where each element can be represented in the form of 8 binary bits.This matrix is divided into two halves, wherein each portion is a square matrix of size m.In the first modification [1], we have made use of the operations mod and XOR, and introduced the concepts mixing and permutation.In the second one [2], we have used modular arithmetic addition and mod operation, along with mixing and permutation.In the third one [3], we have introduced the operations mod and XOR together with a process called blending.In the fourth one [4], we have used mod operation, modular arithmetic addition and the process of shuffling.In each one of the ciphers, on carrying out cryptanalysis, we have concluded that the strength of the cipher, obtained with the help of the modification, is quite significant.The strength is increased, on account of the length of the plaintext and the operations carried out in these investigations.
In the present investigation, our interest is to develop a modification of the Feistel cipher, wherein we include the modular arithmetic inverse of a key matrix.This is expected to offer high strength to the cipher, as the encryption key induces a significant amount of confusion into the cipher, on account of the relationship between the plaintext and the cipher text offered by the key, as it does in the case of the Hill cipher.
In what follows we present the plan of the paper.In section 2, we discuss the development of the cipher and mention the flowcharts and the algorithms required in the development of the cipher.In section 3, we illustrate the cipher with an example.Here we discuss the avalanche effect which throws light on the strength of the cipher.We examine the cryptanalysis in section 4. Finally, we present computations and conclusions in section 5.

II. DEVELOPMENT OF THE CIPHER
Consider a plaintext P having 2m 2 characters.On using EBCIDIC code, this can be written in the form of a matrix containing m rows and 2m columns, where m is a positive integer.This matrix is divided into a pair of square matrices P 0 and Q 0 , where each square matrix is of size m.Let us consider a key matrix K whose size is m x m.
The basic relations governing the encryption and the decryption of the cipher, under consideration, can be written in the form and where, P i and Q i are the plaintext matrices in the i th iteration, K the key matrix, N is a positive integer, chosen appropriately, and K -1 is the modular arithmetic inverse of K. Here, n denotes the number of iterations that will be carried out in the development of the cipher.
The flow charts governing the encryption and the decryption are depicted in Figures 1 and 2 respectively.www.ijacsa.thesai.org The algorithms corresponding to the flow charts can be written as ALGORITHM FOR ENCRYPTION 1. Read P, K, n, N 2. P 0 = Left half of P.
4. for i = 1 to n begin The modular arithmetic inverse of the key matrix K is obtained by adopting Gauss Jordan Elimination method [5] and the concept of the modular arithmetic.

III. ILLUSTRATION OF THE CIPPHER Consider the plaintext given below:
Dear Ramachandra!When you were leaving this country for higher education I thought that you would come back to India in a span of 5 or 6 years.At that time, that is, when you were departing I was doing B.Tech 1 st year.There in America, you joined in Ph.D program of course after doing M.S.I have completed my B.Tech and M.Tech, and I have been waiting for your arrival.I do not know when you are going to complete your Ph.D. Thank God, shall I come over there?I do wait for your reply.Yours, Janaki.(3.1)Let us focus our attention on the first 128 characters of the above plain text.This is given by Dear Ramachandra!When you were leaving this country for higher education I thought that you would come back to India in a span (3.2) On using EBCIDIC code, (3.2) can be written in the form of a matrix having 8 rows and 16 columns.This is given by Read K, P, n On adopting the decryption algorithm, we get back the original plaintext matrix given by (3.3)Now we examine the avalanche effect.In order to achieve this one, firstly, let us have a change of one bit in the plaintext.
To this end, we change the first row, first column element of the plaintext from 68 to 69.On using the modified plaintext and the encryption algorithm, we get the cipher text in the form On comparing (3.7) and (3.8) in their binary form, we notice that they differ by 516 bits (out of 1024 bits).Now let us consider a change of one bit in the key.In order to have this one, we change the first row, first column element of the key form 53 to 52.
On using this key and the encryption algorithm, given in section 2, we get the cipher text in the form On converting (3.7) and (3.9) into their binary form, we notice that they differ by 508 bits ( out of 1024 bits ).From the above analysis we conclude that the cipher is expected to be a strong one.

IV. CRYPTANALYSIS
In the study of cryptology, cryptanalysis plays a prominent role in deciding the strength of a cipher.The well-known methods available for cryptanalysis are

a) Cipher text only attack ( Brute Force Attack ) b) Known plaintext attack c) Chosen plaintext attack d) Chosen cipher text attack
Generally, an encryption algorithm is designed to withstand the brute force attack and the known plaintext attack [6].Now let us focus our attention on the cipher text only attack.In this analysis, the key matrix is of size m x m.Thus, it has m 2 decimal numbers wherein each number can be represented in the form of 8 binary bits.Thus the size of the key space is 8m 2 0.8m 2 2.4m 2 (2) = (2 10 ) ≈ ( 10) .
If we assume that the time required for the computation of the encryption algorithm with one value of the key, in the key space is 10 -7 seconds, then the time required for the computation with all the keys in the key space In this analysis, as we have taken m=8, the time required for the entire computation is 138.6

x 10
This is enormously large.Thus, this cipher cannot be broken by the cipher text only attack ( Brute Force Attack ).Now let us study the known plaintext attack.In this case, we know, as many plaintext cipher text pairs as we require.In the light of this fact, we have as many P 0 and Q 0 , and the corresponding P n and Q n available at our disposal.Now our objective is to determine the key matrix K, if possible, to break the cipher.
From the equations (2.1) and (2.2) we get From the above equations we notice that, P n and Q n can be written in terms of P 0 , Q 0 , K and mod N.These equations are structurally of the form P n = F ( P0, Q0, K, mod N ), (4.1) Q n = G ( P0, Q0, K, mod N ), (4.2) where F and G are two functions which depend upon, P 0 , Q 0 , K and mod N. on inspecting above equations in the analysis, we find that the equations (4.1) and (4.2) are nonlinear in K.
Though the matrices P 0 and Q 0 , corresponding to the plaintext P, and the matrices P n and Q n corresponding to the ciphertext C are known to us, as the equations (4.1) and (4.2) are nonlinear in K, and including mod N at various instances, it is simply impossible to solve these equations and determine K. Thus, this cipher cannot be broken by the known plaintext attack.
As the relations (4.1) and (4.2) connecting P 0 , Q 0 and P n and Q n are formidable (being nonlinear and involving mod N), it is not possible to choose a plaintext or a cipher text and then determine the key K. Thus we cannot break the cipher in case 3 and case 4.
In the light of the above facts, the cryptanalysis clearly indicates that the cipher is a strong one.

V. COMPUTATIONS AND CONCLUSIONS
In this analysis the programs for encryption and decryption are written in C language.
The entire plaintext given by (3.1) is divided into 4 blocks.In the last block we have appended 5 blank characters to make it a complete block, for carrying our encryption.
The cipher text corresponding to the entire plaintext is obtained as given below .ijacsa.thesai.org