You are on page 1of 7

Bit Level Encryption Standard (BLES) : Version-II

Gaurav Bhadra, Tanya Bala, Samik Banik,


Asoke Nath
Department oI Computer Science
St. Xavier`s College(Autonomous),
Kolkata, India
e-mail: gaurav.bhadragmail.com
bala.tanyagmail.com
sam.xavogmail.com
asokejoy1gmail.com
Joyshree Nath

Department oI Computer Science
Jogesh Chandra Chaudhuri College
Kolkata, India
e-mail: joyshreenathgmail.com





$EVWUDFW- In the present paper the authors have introduced a
new symmetric key cryptographic method called Bit Level
Encryption Standard(BLES) Version-II which is based on bit
exchanging or bit reshuffling method from left to right as well
as from right to left of the entire bit stream. In addition to that
the authors have used bit-wise XOR operation to make the
algorithm more powerful. Recently Nath et al has developed
BLES Version-I where they have used bit exchange method
but with some fixed block size which were multiple of 2. Due to
even power of two sometimes there were some repeat of
characters in the encrypted file if the input plain text has also
duplicate characters. To overcome this problem in the present
work the authors have taken block size of square of off
numbers starting from three onwards. For scanning from
right to left the authors used square of even numbers starting
from four onwards. After finishing bit exchange the authors
have performed bit-wise XOR to make the cryptosystem
almost unbreakable. The authors have also introduced a
special bit manipulation method so the encryption algorithm
will work even for all characters with ASCII Code 0 or all
characters with ASCII Code 255. The most of the standard
encryption algorithm will fail to encrypt a file where all
characters are ASCII 0` or all characters with ASCII 255`
but the present method will be able to encrypt a file where all
characters are ASCII 0` or all characters are ASCII 255`.
The present method will be effective for encrypting short
message, password, confidential key etc. The spectral analysis
in the result sections shows that the BLES version-II method is
free from known plain text attack, differential attack or any
type brute force attack.
*HQHUDO7HUPV-- encryption, bit exchange, byte exchange
.H\ZRUGV-BLES, ASCII, bit exchange, XOR, random key,
differential attack
I. INTRODUCTION
With the tremendous development in internet technology in the
last one decade it is a real challenge Ior the sender to send
conIidential data Irom one computer to another computer. There is
no guarantee that between the sender and the receiver there is no
one intercepting those conIidential data especially iI the data is not
encrypted or properly protected. The security or the originality oI
data has now become a very important issue in data communication
network. No conIidential or important message should be sent in
raw Iorm Irom one computer to another computer as it may be
hacker can intercept that conIidential message or important
message. Sending any type oI conIidential message thorugh e-mail
is not at all a proper solution. As any hacker can intercept the mail
and can tamper the actual inIormation and even they can divert it to
some wrong destination. There are many institutions such as
School, college and University there must be some security policy.
Any conIidential data must be protected Irom any unwanted
intruder to avoid any disaster. The disaster may happen iI a
marketing manager oI a private company is sending some crucial
data related to the sales oI the company to his Managing Director
over the e-mail and some intruder intercepts that data Irom the
internet and passes it on to some other rival company. This type oI
disaster may happen when the data is moving Irom one computer
to other computer in an unprotected manner. To overcome this
problem one has to send the encrypted text or cipher text Irom client
to server or to another client. To protect any kind oI hacking
problems nowadays network security and cryptography is an
emerging research area where the programmers are trying to
develop some strong encryption algorithm so that no intruder can
intercept the encrypted message. The proposed method is
symmetric key cryptography
The merit oI symmetric key cryptography is that the key
management is very simple as one key is used Ior both encryption
as well as Ior decryption purpose. In symmetric key algorithm the
key is called secret key and it should be known to sender and
receiver both and no one else. The public key is not secret and it can
be shared by anybody but the decryption key should be kept by the
receiver only and by no one else. The public key methods have both
merits as well as demerits. The problem oI Public key cryptosystem
is that one has to do massive computation Ior encrypting any plain
text. Moreover in some public key cryptography the size oI
encrypted message may increase. Due to massive computation the
public key crypto system may not be suitable in a case like sensor
networks. So the security problem in sensor node is a real problem.
In the present work we are proposing a symmetric key method
called BLES method which can be applied in sensor network,
mobile network, ATM network.

The present method uses bit exchange and byte exchange
methods with complements and xor operation. The key element is
the bit exchange depending on the randomized matrix which is
generated every time and each one is unique. With diIIerent levels
oI extractions such as 2 bytes, 8bytes, 32 bytes and 128 bytes, the
data Iinally gets shuIIled to such an extent that without knowing the
process and key, it would be impossible to decrypt. We have
implemented the bit-wise exchange method as Iollows:
Firstly, we begin with initial transIormation where the
data is broken down to its corresponding bits and are then xored and
121 978-1-4673-4805-8/12/$31.00 c 2012 IEEE
complemented. These bits are stored in a reverse manner into a new
Iile and this new Iile is now worked with.
Secondly, randomization number and encryption number
is calculated.
Thirdly, Iirst (3x3) or 9 bits then (5x5) or 25 bits then (7 x
7) or 49 bits and upto (17 x17) or 289 bits oI data is extracted till
the end oI the Iile is read and is exchanged with bits according to
the number available in the key matrix. AIter Iinishing scanning
Irom leIt to right we do the operation Irom right to leIt using block
size 16, 64, and so on and perIorm the bit-wise exchange method.

The multiple encryptions make our system very secure.
II. BLES VERSION-II ALGORITHM:
Encryption Algorithm:
Step-0: Start
Step-1: Enter input Iile name(plaintext Iile) and store it in
inputFile
Step-2: Enter output Iile name(ciphertext Iile)and store it in
outputFile
Step-3: Enter the key
Step-4: Use module-1 to compute the number oI times to
randomize and the encryption number.
Step-5: Extract bits oI the input Iile and store it in temporary
Iile temp1.txt
Step-6: use module-2 to perIorm bit manipulation method.
Step-7: Store the bits in another temporary Iile temp2.txt
Step-8: Ior i1 to encryption number perIorm the Iollowing
a.Use module-3 to perIorm bit permutation
method.
b. Store it in temporary Iile temp1.txt
c.End loop
Step-9: use module-4 to perIorm bitwise XOR operation on
the bitIile and store it in temp2.txt.
Step-10: Convert the Iile back to bytes and write it in the
outputFile. This is the encrypted Iile.
Step-11: End


Module 1: Calculation oI Encryption Number and Randomization
Number
Step-0: Start.
Step-1: lenlength oI the password
Step-2: II len8 then, base9-len
else base1
Step-3:Initialize s10,i0
Step-4: Calculate the Iollowing:
a)powbase`(i1)
b)nascii value oI ith character oI password
c)s1s1pow*n
Step-5: iI ilen goto Step-4.
Step-6: s2sum oI digits oI s1
Step-7: Randomization Number: rtimess1s2
Step-8: iI rtimes0 or rtimes~64, then rtimes64
Step-9:Initialize s30,i0
Step-10: Calculate the Iollowing:
a)powbase`(i1)
b)nascii value oI (len-1-i)th character oI
password
c)s3s3pow*n
Step-11: iI ilen goto Step-4.
Step-12: s4sum oI digits oI s3
Step-13: Encryption Number: ennums3s4
Step-14: iI ennum0 or ennum~64, then ennum64
Step-15: End


Example:
Suppose the user entered a key 'ABCD
ThereIore the length oI the key4
i)To calculate randomization number we proceed as Iollows:
a.Calculate a sum Irom the given text key as Iollows:
Sum base
postion
* ASCII value oI character
Here Ior ASCII code oI A65, B66, C67, D68
Base5
ThereIore s15
1
* 65 5
2
* 66 5
3
* 67 5
4
*
68325165083754250051365

b.Calculate again sum oI the digits in s1 as s25136520

c.Find the modulo with s1 to obtain randomization number:
Rtimess1 s251365 20 5

(ii) To calculate encryption number we proceed as Iollows:
a.Calculate a sum as Iollows:
S35
1
*685
2
*675
3
*665
4
*6534016758250 4062550890

b.Sum oI digits in s3 is s45089022

c.ThereIore encryption number is:
ennums3 s450890 22 4

Module 2:Bit Manupulation
Step-0: Start.
Step-1: Convert the entire input Iile to bits.
Step-2: Extract 8-bits at a time.
Step-3: Reverse the bits.
Step-4: Complement the bits.
Step-5: PerIorm XOR operation. Take bit-1 and bit-8 and XOR
the values and store it in position-8.Similarly XOR bit-2 and
bit-7,bit-3 and bit-6, and bit-4 and bit-5 and store in position-
7,position-6 and position-5 respectively.
Step-6: Store the manipulated bits in an outputIile1.
Step-6: End



ASCII1
Original 0 0 0 0 0 0 0 1
Reverse 1 0 0 0 0 0 0 0
1-s Comp 0 1 1 1 1 1 1 1
XorFinal
pattern
0 1 1 1 0 0 0 1


ASCII2
Original 0 0 0 0 0 0 1 0
Reverse 0 1 0 0 0 0 0 0
1-s Comp 1 0 1 1 1 1 1 1
XorFinal
pattern
1 0 1 1 0 0 1 0


122 2012 World Congress on Information and Communication Technologies
ASCII3
Original 0 0 0 0 0 0 1 1
Reverse 1 1 0 0 0 0 0 0
1-s Comp 0 0 1 1 1 1 1 1
XorFinal
pattern
0 0 1 1 0 0 1 1






Module 3:Bit Permutation

Step-0: Start.
Step-1: DeIine block-size19,25 ,49, 81, 121, 169, 225, 289,
361, 441, 529, 625, 729, 841, 961, 1089 and read size1 bits at
a time.
Step-2: Arrange the bits in a square array and randomize those
bits using MSA algorithm and store it in outputIile2. The Iirst
block should contain 9 bits, 2
nd
block should contain 25 bits
and so on.
Step-3: Continue Step-2 till there are suIIicient number oI bits
in the Iile. When the process stops copy the residual bits as it
is into outputIile2.
Step-4: Reverse the Iile and store it in outputIile1.
Step-5: Now deIine block-size24, 16, 36, 64, 100, 144, 196,
256, 324, 400, 484, 576, 676, 784, 900, 1024 and read size2
bits at a time.
Step-6: Arrange the bits in a square array and randomize those
bits using MSA algorithm and store it in outputIile2. Here
also continue the process until we have suIIicient bits in the
Iile. Copy the residual bytes into outputIile2.
Step-7: Reverse the Iile and store it in outputIile1.
Step-9: In each block operation the randomization number is
to be modiIied in each step by 1 up to a maximum value oI
400 and then again reset to 1.
Step-10: AIter the Iirst round we have to again apply Step-1
to Step-9 till n-rounds (Determined Irom the password).
Step-11: End.


Module 4: Bit XOR method:

Step-0: Start
Step-1: read 2 consecutive bits
Step-2: perIorm XOR operation
Step-3: store result in the position oI 2
nd
bit
Step-4: continue step-1 to step-3 till the end oI the Iile.
Step-5: Ior i1 to n do:
a. Read bit i and i2. perIorm XOR.
b. II i is odd, store in i2. else store the result in i.
c. End loop.

Step-6: take 8 bits at a time. Interchange the bits in the
Iollowing manner:
a. Ior i1 to 4 do
b. interchange with bit i4
c. end loop

Step-6: interchange bits in the Iollowing manner:
a. Ior i1 to n, (where npostion oI last bit)
b. interchange bit i and bit n-1.
c. End loop
Step-7: Reverse the entire bit pattern
Step-8:End


Decryption Algorithm:

Step-0: Start
Step-1: Enter input Iile name (Encrypted File)and store it in
inputFile
Step-2: Enter output Iile name(Decrypted File) and store it in
outputFile
Step-3: Enter the key
Step-4: Use module-1 to compute the number oI times to
randomize and the encryption number
Step-5: Convert the Iile to bits and then reverse the Iile.
Step-6: use module-4 to perIorm bitwise XOR operation on
the bitIile and store it in temp2.txt.
.
Step-7: Ior i1 to encryption number perIorm the Iollowing
a.Use module-3 to perIorm bit permutation
method.
b. Store it in temporary Iile temp1.txt
c.End loop
Step-8: use module-2 to perIorm bit manipulation method.
Step-10: Convert the Iile back to bytes and write it in the
outputFile. This is the encrypted Iile.
Step-11: End
The modules have been described in our encryption
algorithm. The only diIIerence is that decryption methods
will work in reverse order oI the encryption process.

,,, RESULTS AND DISCUSSION
We have tried our present algorithm on diIIerent patterns
where the same character is repeated quite a number oI times.
We Iound it gives a random set oI characters Ior any input
stream oI characters. The Iollowing are the Irequency graphs
oI the cipher text Iiles obtained Irom Iiles containing a
sequence oI 1050 single ASCII characters.





2012 World Congress on Information and Communication Technologies 123

124 2012 World Congress on Information and Communication Technologies

2012 World Congress on Information and Communication Technologies 125


Some miscellaneous text inputs and their corresponding
cipher texts are as Iollows:
(Password used:1234)






IV. CONCLUSION AND FUTURE SCOPE:
The encrypted text cannot be decrypted without knowing the exact
initial random matrix. To complete the whole process we choose
any oI the random matrix to perIorm bit exchange method and
there is no similarity between any two matrices and even iI there is
then it is very hard to Iind out the similar ones. The spectral
analysis shows that our present method is Iree Irom standard
cryptography attacks namely brute Iorce attack, known plain text
attack and diIIerential attack. The present method will be most
eIIective to encrypt short message such as SMS in mobile phone,
password encryption and any type oI conIidential message. We
have tested the present method on any type Iile such as text, audio,
video or any other Iile and we Iind that it is working perIectly ok.
In the Iuture work we will be adding some more complex bit-wise
operations and will integrate vernam cipher method in bit level.


ACKNOWLEDGMENT
We are very much grateIul to the Department oI Computer Science
to give us this opportunity to work on symmetric key
Cryptography. One oI the authors (AN) sincerely expresses his
gratitude to Fr. Dr. Felix Raj, Principal oI St. Xavier`s
College(Autonomous) Ior giving constant encouragement in doing
research in cryptography.

REFERENCES


|1| Symmetric Key Cryptography using Random Key generator : Asoke
Nath, Saima Ghosh, Meheboob Alam Mallik: 'Proceedings oI
International conIerence on security and management(SAM`10 held
at Las Vegas, USA Jull 12-15, 2010), Vol-2, Page: 239-244(2010).
|2| Advanced Symmetric key Cryptography using extended MSA
method: DJSSA symmetric key algorithm: Dripto Chatterjee,
Joyshree Nath, Soumitra Mondal, Suvadeep Dasgupta and Asoke
Nath,Jounal oI Computing, Vol 3, issue-2, Page 66-71,Feb(2011).
|3| A new Symmetric key Cryptography Algorithm using
extended MSA method :DJSA symmetric key algorithm,
Dripto Chatterjee, Joyshree Nath, Suvadeep Dasgupta and
Asoke Nath : Proceedings oI IEEE International ConIerence
on Communication Systems and Network Technologies, held
at SMVDU(Jammu) 03-06 June,2011, Page-89-94(2011).
|4| New Symmetric key Cryptographic algorithm using combined bit
manipulation and MSA encryption algorithm: NJJSAA
symmetric key algorithm :Neeraj Khanna, Joel James,Joyshree
Nath, Sayantan Chakraborty, Amlan Chakrabarti and Asoke
Nath : Proceedings oI IEEE CSNT-2011 held at SMVDU(Jammu)
03-06 June 2011, Page 125-130(2011).
|5| Symmetric key Cryptography using modiIied DJSSA symmetric key
algorithm, Dripto Chatterjee, Joyshree Nath, Sankar Das, Shalabh
Agarwal and Asoke Nath, Proceedings oI International conIerence
Worldcomp 2011 held at LasVegas 18-21 July 2011, Page-306-311,
Vol-1(2011).
|6| An Integrated symmetric key cryptography algorithm using
generalized vernam cipher method and DJSA method: DJMNA
symmetric key algorithm : Debanjan Das, Joyshree Nath, Megholova
Mukherjee, Neha Chaudhury and Asoke Nath: Proceedings oI IEEE
International conIerence : World Congress WICT-2011 to be held at
Mumbai University 11-14 Dec, 2011, Page No.1203-1208(2011).
|7| Symmetric key cryptosystem using combined cryptographic
algorithms- generalized modiIied vernam cipher method, MSA
126 2012 World Congress on Information and Communication Technologies
method and NJJSAA method: TTJSA algorithm Trisha Chatterjee,
Tamodeep Das, Joyshree Nath, Shayan Dey and Asoke Nath,
Proceedings oI IEEE International conIerence : World Congress
WICT-2011 t held at Mumbai University 11-14 Dec, 2011, Page No.
1179-1184(2011).
|8| Symmetric key Cryptography using two-way updated Generalized
Vernam Cipher method: TTSJA algorithm, International Journal oI
Computer Applications(IJCA, USA), Vol 42, No.1, March, Pg: 34 -
39( 2012).
|9| Ultra Encryption Standard(UES) Version-I: Symmetric Key
Cryptosystem using generalized modiIied Vernam Cipher method,
Permutation method and Columnar Transposition method, Satyaki
Roy, Navajit Maitra, Joyshree Nath,Shalabh Agarwal and Asoke
Nath, Proceedings oI IEEE sponsored National ConIerence on
Recent Advances in Communication, Control and Computing
Technology-RACCCT 2012, 29-30 March held at Surat, Page 81-
88(2012).
|10| An Integrated Symmetric Key Cryptographic Method
Amalgamation oI TTJSA Algorithm, Adbvanced Caeser Cipher
Algorithm, Bit Rotation and reversal Method : SJA Algorithm.,
International Journal oI Modern Education and Computer Science,
Somdip Dey, Joyshree Nath, Asoke Nath,(IJMECS), ISSN: 2075-
0161 (Print), ISSN: 2075-017X (Online), Vol-4, No-5, Page 1-
9,2012.
|11| An Advanced Combined Symmetric Key Cryptographic Method
using Bit manipulation, Bit Reversal, ModiIied Caeser
Cipher(SD-REE), DJSA method, TTJSA method: SJA-I Algorithm,
Somdip dey, Joyshree Nath, Asoke Nath, International Journal oI
Computer Applications(IJCA 0975-8887, USA), Vol. 46, No.20,
Page- 46-53,May, 2012.
|12| Ultra Encryption Standard(UES) Version-IV: New Symmetric Key
Cryptosystem with bit-level columnar Transposition and ReshuIIling
oI Bits, Satyaki Roy, Navajit Maitra, Joyshree Nath, Shalabh
Agarwal, Asoke Nath, International Journal oI Computer
Applications, USA, Vol 51-No 1, Page 28-35(2012).
|13| Bit Level Encryption Standard(BLES): Version-I, Neeraj Khanna,
Dripto Chatterjee, Joyshree Nath, Asoke Nath, International Journal
oI Computer Applications, USA, Vol 52-No 2, Page 41-46(2012).
|14| Cryptography and Network Security, William Stallings, Prectice Hall
oI India.





2012 World Congress on Information and Communication Technologies 127

You might also like