 Open Access
 Total Downloads : 384
 Authors : Nehal Kandele, Shrikant Tiwari
 Paper ID : IJERTV2IS100463
 Volume & Issue : Volume 02, Issue 10 (October 2013)
 Published (First Online): 18102013
 ISSN (Online) : 22780181
 Publisher Name : IJERT
 License: This work is licensed under a Creative Commons Attribution 4.0 International License
New Cryptography Method Using Relative Displacement: RDC Symmetric Key Algorithm
Nehal Kandele, Shrikant Tiwari
Department of Computer Science & Engineering (CSE)
Shri Shankaracharya Technical Campus (SSTC), Shri Shankaracharya Group of Institutions (SSGI) Faculty of Engineering and Technology, Junwani, Bhilai, DistrictDurg, C.G., 490020
Abstract
The author proposes a new symmetric key encryption algorithm which is based on the following steps: 1) In the first step, converting each character of the string into its corresponding ASCII value and dividing the string into square matrices of maximum possible even order. 2) In the second step, calculating the key1 and key2 and thereby deducing key on the basis of these keys. 3) In the third step, performing a sequence of row interchange operation, followed by a sequence of rotation operation on each derived square matrix. 4) In the fourth step, adding magic square matrix of same size as that of the matrix under consideration. 5) In the fifth and final step, the remaining elements are modified by adding to them, the product of sum of the magic square of size same as that of the derived key and the successor of the corresponding position of each element in the series of remaining elements.

Introduction
All the cryptographic algorithm aim to convert the plain text; that is input string, into a cipher text, the encrypted message, which is as difficult as possible to decode and understand. The decoding becomes further complicated if the key is abstracted or not used. A good cryptographic algorithm is a technique that cannot be easily traced and the only method to trace it is the hit and trial method for all possible and available techniques. Encryption algorithms may be symmetric or asymmetric.
In symmetric encryption, the process of encryption and decryption is performed with the help of a common key, which should be either known or should be
transmitted to both, the sender and the receiver, before the encryption and decryption takes place.
In asymmetric key, the problem of key transmission is resolved. It employs the use of two types of keys, private key and public key. Private Key or secret key is called so, since it is unknown to others. Public key is used for the encryption of data whereas private key is used for decryption. In the present work, the string is fragmented into square matrix of even order and then rotation pattern is designed in such a way that, every element is not only displaced from its original position but also the adjacent neighbours of the elements are changed. A magic square matrix of size, same as that of resultant matrix is then added to it, to change the number of occurrence of the characters. The elements which could not be accommodated in the matrix are also modified in the similar way.

Basic terminology
Magic square matrix
Magic square matrix is a square matrix in which the sum of all elements in each column and in each row is same. The sum can be calculated from the formula (n*(nÂ²+1))/2, where n is the size of square matrix.
Pattern rotation
Pattern rotation involves a series of steps to shift the position of elements in a particular predefined pattern.
A square matrix of even order
A square matrix of even order refers to a matrix with equal number of rows and columns and this number is even, that is divisible by 2. Example, matrix of order 2×2, 4×4, 6×6, etc.

Proposed encryption algorithm
Step1
We calculate the length of the given input string and assign it to variable N. Each element of the input string is then converted into its corresponding ASCII value.
Consider that the entered input string is SUN RISES IN THE EAST!
Here, length of string N = 22, so the ASCII equivalent of the string is:
[83 85 78 32 82 73 83 69 83 32 73 78 32 84 72 69 3269 65 83 84 33]
Step2
We break the input string into square matrices of maximum possible size of even order and place the remaining elements into a variable REM. This step is repeated, using remainder REM of this step as input string, until there are 4 or more elements in REM.
So, in this example matrices are:
REM= [84 33]
Step3
Calculating the KEY by KEY1 KEY2, where, KEY1 can be calculated as sum of numbers of columns of all matrices and number of elements in REM. KEY2 can be calculated as the sum of magic square matrix of size same as that of last generated square matrix. Here, refers to addition. If the KEY is greater than 9, then sum all the digits until a single digit KEY is obtained.
Here, KEY1 = 4 + 2 + 2 = 8, Size of last generated square matrix = 2 and sum of magic square matrix of size 2 = 5
So, KEY2 = 5, and KEY = 8 5 = 13 = 1 + 3 = 4
Step4
In this step, we apply a rotation pattern on the square matrices obtained. The sequence of the steps in rotation pattern can be listed as follows, assume that the matrix is:

In the first rotation interchanging the even columns in the following manner:

In second rotation interchanging the even rows in the following manner:

In third rotation performing singlediagonalleft up shift as shown below:

In fourth rotation performing singlediagonal rightup shift as shown below:

In fifth rotation applying singleup shift to the every even column as follows:

In the sixth and last rotation rotating once the outer most cycle in clock wise direction, its inner circle in anticlock wise direction, and so on as shown below:
So, the resultant matrices of above example after these rotation operations are:
Step5
A magic square matrix of same size as that of the square matrix, under the consideration, is then added to it.
convert these ASCII values into characters to form the cipher text.
[152 135]String = [48 71 76 91 88 89 83 92 94 89 75 44 36 97 87
84 70 86 69 34 152 135]
So, cipher text is:
0GL[XYS\^YK,$aWTFVEÃ–Ã§


Proposed decryption algorithm
Step1
We calculate the length of the given input string and assign it to variable N. Each element of the input string is then converted into its corresponding ASCII value.
Consider that the entered input string is:
0GL[XYS\^YK,$aWTFVEÃ–Ã§
Here, length of string N = 22
So, the ASCII equivalent of the string is [48 71 76 91
88 89 83 92 94 89 75 44 36 97 87 84 70 86 69 34 152
135]
Step2
We break the input string into square matrices of maximum possible size of even order and place the remaining elements into a variable REM. This step is repeated, using remainder REM of this step as input string, until there are 4 or more elements in REM.
So, in this example matrices are:
Step6
Step3
REM= [152 135]
Now we calculate the variable F as the sum of magic square matrix of order KEY. Adding F * (n + 1) to each n term in the REM, to generate final REM.
Here, REM= [84 33], KEY = 4, sum of magic square matrix of order 4 = 34, therefore F = 34,
Final REM = [84 + (34 * (1 + 1)) 33 + (34 * (2 + 1))]
= [152 135]
Step7
In the last step, we merge all the square matrices and the remainder, in the order they were derived, and then
Calculating the KEY by KEY1 KEY2, where, KEY1 can be calculated as sum of numbers of columns of all matrices and number of elements in REM. KEY2 can be calculated as the sum of magic square matrix of size same as that of lastgenerated square matrix. Here, refers to addition. If the KEY is greater than 9, then sum all the digits until a single digit KEY is obtained.
Here KEY1 = 4 + 2 + 2 = 8,
Size of last generated square matrix=2 and sum of magic square matrix of size 2=5
So, KEY2 = 5 and KEY = 8 5 = 13 = 1 + 3 = 4
Step4
A magic square matrix of same size as that of the square matrix, under the consideration, is then subtracted to it.
Step5
In this step, we apply a rotation pattern on the square matrices obtained. The sequence of the steps in rotation pattern can be listed as follows, assume that the matrix is:

In the first rotation rotating once the outer most cycle in anti clock wise direction, its inner circle in clock wise direction, and so on as shown below:

In second rotation applying singledown shift to the every even column as follows:

In third rotation performing singlediagonalleft down shift as shown below:

In fourth rotation performing singlediagonal rightdown shift as shown below:

In fifth rotation interchanging the even rows in the following manner:

In the sixth and last rotation interchanging the even columns in the following manner:
So, resultant matrices of above example after these rotation operations are:
Step6
Now we calculate the variable F as the sum of magic square matrix of order KEY. Subtracting F * (n + 1) from each n term in the REM, to generate final REM.
Here, KEY = 4, REM= [152 135], sum of magic square matrix of order 4 = 34, therefore, F = 34
Final REM = [152 – (34 * (1 + 1)) 135 – (34 * (2 + 1))]
= [84 33]
Step7
In the last step, we merge all the square matrices and the remainder, in the order they were derived, and then convert these ASCII values into characters to form the plain text.
Here, matrices are:
[84 33]String = [83 85 78 32 82 73 83 69 83 32 73 78 32 84 72
69 32 69 65 83 84 33]
So, plain text is:
SUN RISES IN THE EAST!


Result
Following StringTime graph displays the time taken for the encryption of varying string length. The corresponding CharacterTime graph showing the average time taken to encrypt each character for the varying length of string is given below.
Figure 1. StingTime graph
Figure 2. CharacterTime graph

Conclusion
In the present work, we use keyless keying, that is keying or encrypting the data without using a predefined or a fixed key. Also, the requirement of key transmission is removed. The key changes with increase in length of string without increasing the complexity. So, in this algorithm, it is nearly impossible to decrypt the encrypted text without knowing the criteria to generate key. The rotation pattern is designed to conceal the recognition of pattern in the string.

Acknowledgement
I am highly indebted to Dr. R. N. Patel sir for his invaluable guidance and suggestions. I owe much of thanks to my brother, Suyash Kandele for his support.

References

YaPing Zhang, Jizhou Sun, and Xu Zhang, A Stream Cipher Algorithm Based on Conventional Encryption Techniques, IEEE, 0780382536/04, 2004.

A. Chandra Sekhar, K.R. Sudha, and Prasad Reddy P V G D, "Data Encryption technique using Random number generator", IEEE Computer Society, 07695 3032X/07, DOI 10.1109/GrC.2007.73, 2007.

Albert H. Carlson, Robert E. Hiromoto, and Richard
B. Wells, "Breaking Block and Product Ciphers Applied Across Byte Boundaries", IEEE, 9781457714252/11, 2011

Dripto Chatterjee, Suvadeep Dasgupta, Joyshree Nath, and Asoke Nath, "A new Symmetric key Cryptography Algorithm using extended MSA method: DJSA symmetric key algorithm", IEEE, 97807695 44373/11, DOI 10.1109/CSNT.2011.25, 2011.

Zhang Yunpeng, Zhu Yu, Wang Zhong, and Richard O.Sinnott, "IndexBased Symmetric DNA Encryption Algorithm", IEEE, 9781424493067/11, 2011.

Neeraj Khanna, Joyshree Nath, Joel James, Amlan Chakrabarti, Sayantan Chakraborty, and Asoke Nath, New Symmetric Key Cryptographic algorithm using combined bit manipulation and MSA encryption algorithm: NJJSAA symmetric key algorithm, IEEE Computer Society, 9780769544373/11, DOI 10.1109/ CSNT.2011.33, 2011.

D. Rajavel, and S. P. Shantharajah, Cubical Key Generation and Encryption Algorithm Based on Hybrid Cubes Rotation, IEEE, 9781467310390/12, March 2123, 2012.

Marcin Niemiec, and Lukasz Machowski, A new symmetric block cipher based on keydependent S boxes, IEEE, 9781467320153/12, 2012.

Hai Cheng, and Qun Ding Overview of the Block Cipher, IEEE Computer Society, 9780769549354/12, DOI 10.1109/IMCCC.2012.379, 2012.

Gaurav Bhadra, Tanya Bala, Samik Banik, Asoke Nath, and Joyshree Nath,"Bit Level Encryption Standard (BLES): VersionII", IEEE, 9781467348058/12, 2012.

Rishav Ray, Jeeyan Sanyal, Debanjan Das, and Asoke Nath, A new Challenge of hiding any encrypted secret message inside any Text/ASCII file or in MS word file: RJDA Algorithm, IEEE, 9780769546926/12, DOI 10.1109/CSNT.2012.191, 2012.

Somdip Dey, "SDC1BBR: SDCount1ByteBit Randomization: A New Advanced Cryptographic Randomization Technique", IEEE, 978146734805 8/12, 2012.

Akanksha Mathur, A Research paper: An ASCII value based data encryption algorithm and its comparison with other symmetric data encryption algorithms, International Journal on Computer Science and Engineering, ISSN: 09753397, vol. 4, no. 09, 2012, pp. 16501657.

Sayak Guha, Tamodeep Das, Saima Ghosh, Joyshree Nath, Sankar Das, and Asoke Nath, "A New Data Hiding Algorithm With Encrypted Secret Message Using TTJSA Symmetric Key Crypto System", Journal of Global Research in Computer Science,ISSN2229 371X, vol. 3, no. 4, April 2012.

Somdip Dey, "SDAREE: An Advanced Modified Caesar Cipher Method to Exclude Repetition from a Message", International Journal of Information and Network Security, vol. 1, no. 2, ISSN: 20893299, June 2012.

Rajavel D, and Shantharajah S. P, "Cryptography Based on Combination of Hybridization and Cubes Rotation", International Journal of Computational Intelligence and Informatics, vol. 1: no. 4, ISSN: 2231 0258, March 2012.

Somdip Dey, Joyshree Nath, and Asoke Nath, "An Integrated Symmetric Key Cryptographic Method Amalgamation of TTJSA Algorithm, Advanced Caesar Cipher Algorithm, Bit Rotation and Reversal Method: SJA Algorithm", I. J. Modern Education and Computer Science, DOI: 10.5815/ijmecs.2012.05.01, 2012.

Somdip Dey, Kalyan Mondal, Joyshree Nath, and Asoke Nath, "Advanced Steganography Algorithm Using Randomized Intermediate QR Host Embedded With Any Encrypts Secret Message: ASA_QR Algorithm", I. J. Modern Education and Computer Science, DOI: 10.5815/ijmecs.2012.06.08, 2012.

Mr. Rangaswamy D. A., and Mr. Punithkumar M. B., "New Symmetric Key Cryptographic Algorithm Using Combined Bit Manipulation and MSA Encryption Algorithm: NJJSAA Symmetric Key Algorithm", International Journal of Innovative Research and Development, vol. 2, Issue 6, ISSN: 22780211, June 2013.

Thanapal P, Muthamil Selvan T, and Pratheeba T, "An Integrated Cryptography Approach Using MSA Symmetric Key", International Journal of Engineering Research and Technology, vol. 2, Issue 3, ISSN:2278 0181, March 2013
Nehal Kandele, B.E., M.E. Scholar in Computer Technology & Application from Shri Shankaracharya Technical Campus, Bhilai, Chhattisgarh, India. Research areas are Computer Network and Cryptography.
Dr. Shrikant Tiwari, currently working as Assistant Professor in Deartment of Computer Science & Engineering at Shri Shankaracharya Technical Campus, Bhilai, Chhattisgarh, India. He has received his Ph.D in Department of Computer Science and Engineering from the Indian Institute of Technology (Banaras Hindu University), Varanasi. He has published more than 20 papers in international journal and conference and also published 5 Book Chapters.