Randomly Encryption Using Genetic Algorithm Web Site: www.ijaiem.org Email: ,

advertisement
International Journal of Application or Innovation in Engineering & Management (IJAIEM)
Web Site: www.ijaiem.org Email: editor@ijaiem.org, editorijaiem@gmail.com
Volume 2, Issue 8, August 2013
ISSN 2319 - 4847
Randomly Encryption Using Genetic Algorithm
ALI JASSIM MOHAMED ALI
Department of physics, College of Science, Al-Mustansiriyah University, Baghdad, Iraq.
SUMMARY
In this research work a genetic algorithm utilized to establish an approach for random key to each letter in text massage
encoding/ decoding. The test results indicated that using this approach achieved good performance to hide text massage that
because choosing random key by genetic algorithm gives the approach difficulties that can not easily discover or break the key.
Every character in text message encoded by random key, the highest value is 128 (i.e. each character except 128 probabilities).
Key words: Steganography, Information Hiding, Genetic Algorithms, Encryption, Description.
1. Basic Premise
Genetic algorithms (GA) have proven to be a well suited technique for solving selected combinatorial problems. When
solving real-world problems, often the main task is to find a proper representation for the candidate solutions [1].
Cryptography is "the art of writing in secret characters". Encrypting is the act of translating a 'normal message' to a
message written with 'secret characters' (also known as the encrypted message). Decrypting is the act of translating a
message written with 'secret characters' into a readable message (the unencrypted message). It is, by far, one of the most
important areas in computer security, since modern encryption algorithms can ensure all three pillars of a secure
conversation: privacy, integrity, and authentication
The use of encryption/decryption is as old as the art of communication. In wartime, a cipher, often incorrectly called a
code, can be employed to keep the enemy from obtaining the contents of transmissions; examples are Morse code and
ASCII.)[2][13]
2. Suggested Algorithms
The current implementation is done by using these. These can be described by see figure (1).
Fig. (1) generic process of encoding and decoding
We can illustrate from figure (1) as follows:
2.1 Key creation algorithms
The suggested algorithms to will generate two keys, the first key form text message (text) and the second key will
generated from genetic algorithm. This is certainly the most complicated part of the algorithm. These perform as follows:
2.1.1 Step 1 (First key):
Take the massage text (text) and convert each symbol (character) into decimal number, each symbols represented
decimal (decimal represent the ASCII Code of character).
2.1.2 Step 2(second key):
It will be doing by using genetic algorithm will generate dependent of randomly. I explain that as follow: it used simple
genetic algorithm:
Volume 2, Issue 8, August 2013
Page 242
International Journal of Application or Innovation in Engineering & Management (IJAIEM)
Web Site: www.ijaiem.org Email: editor@ijaiem.org, editorijaiem@gmail.com
Volume 2, Issue 8, August 2013
ISSN 2319 - 4847
2.1.2.1Genetic Algorithm
A Simple genetic algorithm is presented in this work .The implementation of Simple genetic algorithm and procedures
are discussed in detail as follow [3]
1) Encoding and Data Primary
The encoding of the chromosome is related to the cardinal number of symbols of ASCI code of character.
The encoding included randomly encoding, where each number had its randomly directly encoded on the string (that was
used for representing this problem), where two way generate number.
One: direct generate random number will be decimal
Two: generate binary number and convert to decimal number (it will take in suggest methods).
Table 2: sample of chromosome Representation
1
0
1
1
1
0
0
1
0
1
0
0
0
0
1
0
1
1
1
0
2) Fitness Function
This is used to compute the fitness value for the chromosomes of each population that will convert binary number to
decimal. Fitness used as follows:
 read binary number form chromosome will note the length of chromosome are 256
 divided chromosome a seven position where up value will 27 =128 and compute the number
 convert to decimal ,For example
3. Genetic Operators
When people use steganography, they strive for high security and capacity. So it is common that the embedded data is
compressed and encrypted. Also, it is statically random [11]. In the present work, such considerations have been taken
both subjective and objective evaluations. The subjective method depends on the human visual system (HVS), where as
the objective measure allows to compare different techniques with fixed analytical methods. Some of these used
estimators are [12]:
3.1 Selection [4]
In this method used Binary Tournament selection Goldberg Method where two individuals are chosen at random from
the population. A random number r is then chosen between 0 and 1. If r ≤ k (where k is parameter, for example 0.75), the
fitter of the two individuals is selected to be a parent; otherwise the less fit individual is selected. The two are then
returned to the original population and can be selected again. An analysis of this method was present by (Goldberg and
Deb 1991).
3.2 Crossover Operator (Uniform Crossover):
In this method used the procedure of uniform point crossover is the first described in [Gol89]. Each gene of the first
parent has a 0.5 probability of swapping with the corresponding gene of the second parent [5]. For example:
Table 3: Example of Uniform Crossover
Parent 1
Parent 2
1
0
0
1
0
0
1
0
0
1
1
1
Uniform point
crossover
→
Offspring 1
Offspring 2
0
1
0
1
1
0
0
1
0
1
1
1
3.3 Mutation
There are two types of mutation used in this method
 Mutation for one position [6]
Volume 2, Issue 8, August 2013
Page 243
International Journal of Application or Innovation in Engineering & Management (IJAIEM)
Web Site: www.ijaiem.org Email: editor@ijaiem.org, editorijaiem@gmail.com
Volume 2, Issue 8, August 2013
ISSN 2319 - 4847
For example, we have the string where:
A: =a1 a2 a3 ..an
And randomly we select the point p
Where p=r; then we have
a1,a2,a3 .. an a1 a2 a3.. ar-1 br ar+1 ….an
 Mutation for two point [Nad02,Maw02,Dav85,SS97]
Here we have two points p1and p2 where 1<=p1<p2 <= n.
For example:
a1 a2 a3..ai.. aj..ana1 a2 a3.. ai-1 aj aj+1.. aj-1 ai aj+1…an
3.4 Swapping (The basic generation update scheme):
Consists in producing N children from a population of size N to form the population at the next time step (generation),
and this new population of children completely replaces the parent selection. Clearly this kind of update implies that an
individual can only reproduce with individuals from the same generation [7].
3.5 Stopping Criterion
The most common stopping criterion for GA is to specify a maximum number of its generations.
Table 4: illustrate the sample result of genetic algorithm
14
13
114
1
1
0
128
32
2
Step 3:
After that will summation with the value that obtain form first key (text) and the second key form genetic[15][16]. That
will have cipher text.
As example (Running-key Cipher)
1) The first key: Plaintext image text converted to binary number (as pervious in table (2))
2) The second key generate as genetic algorithm
3) “Added” first key values with second key giving cipher text that represent message encryption in figure (2).
Plaintext :( massages)
Ahmed, meet me at nine clocks in …..
Ahmed meet mee nine clocks in
In this search used that key to encryption as follow steps:Step 1: the First key ()
65 104 109 101 100 32 109 101 101 116 32 109 101 101 32 110 105 110 101 32 99 108 111 99 107 115 32 105 110
Will obtain the values form text (here generate key encryption form text that will obtain about ASCII code
Step 2 (The Second key):
Will obtain the values form genetic algorithm
5 34
39 31 30
0
39
31 31 46
0 39 31
27
0 52
45
30 49
0 33 20 35
53
21
29
0
57
30
Step 3:
We will now obtain the key which will be used to encrypt the message. Now, we arrive at the encrypted message by
adding both numbers:
Step 4: (Cipher text)
Cipher text will obtain form step 3. The resulting message
70 138 148 132 130 32 148 132 132 162 32 148 132 128 32 162 150 140 150 32 132 128 146 152 128 144 32 162 140
is the encrypted message.
70 138 148 132 130 32 148 132 132 162 32 148 132 128 32 162 150 140 150 32 132 128 146 152 128 144 32 162 140
Fig. (5)
illustrate the Cipher text
Volume 2, Issue 8, August 2013
Page 244
International Journal of Application or Innovation in Engineering & Management (IJAIEM)
Web Site: www.ijaiem.org Email: editor@ijaiem.org, editorijaiem@gmail.com
Volume 2, Issue 8, August 2013
ISSN 2319 - 4847
The decryption algorithm restores an encrypted to its original form.
1. The recipient uses his/her will take the message that attach
2. The recipient will attach file with massage that will contain second key
3. The recipient uses will operation subtract
4. The recipient will obtain original character that represent original text
Ahmed, meet me at nine clocks in …..
Please note that this is a very trivial example. Current key-based algorithms are much more sophisticated (for starters,
keys are much longer, and the encryption process is not as simple as 'adding the message and the key'). However, these
complex algorithms are based on the same basic principle shown in our
4. The Result Analysis
One can represent the results by the next steps:
1. The security of a strong system resides with the secrecy of the key
2. Use genetic algorithm to generate key encryption.
3. The key that will generate will be change in every once.
4. Subjectively, not easily to discover key used because randomly that will add by used genetic algorithm
5. High security keys in control by the fewest number of persons.
6. Key destruction: Securely destroy, to protect encrypted data to be retired
7. Non Fixed-length result regardless of text size Impossible (or very difficult) to derive original message from digest No
other message should produce the same digest (such pairs are collisions)
8. speed and equivalent
9. Every character wills encryption with a different value form other character.
5. Conclusions
The performance of the suggested approach proves that encoding information inside decoding information can be done
and will
 Text encryption
 file encryption
 uses 128 -bit key encryption algorithm
 multiple encryption
 advanced password generator
 easy-to-use
 Strong text and file encryption software for personal and professional security. Encryption and Decryption Pro protects
privacy of your email messages, documents and sensitive files by encrypting them.
 The design and strength of all key lengths of the algorithm (i.e., 128) are sufficient to protect classified information up
to the SECRET level. TOP SECRET information will require use of either the 128 key lengths (high Security).
Further extend to this work is by using the proposed system to hide the text into secret image as cover sources.
References
[1] E.Goldberg,”Genetic Algorithm in search, optimization, and Machine learning”, Addison-Wesley, 1989.
[2] O. Billet, H. Gilbert, C. Ech-Chatbi, Cryptanalysis of a White-box AES Implementation, SAC,2004,Learning",
Wesley, 1989.
[3] Melanie Mitchell, “An Introduction to Genetic Algorithms”, Printice- Hall, India, 1998.
[4] Mawada Mohammed Saleiman ,”Study of Per mutative Crossover Behavior on Cryptanalysis of Substitution Cipher
and traveling salesman Problems”, Master’s thesis ,2002.
[5] Nada thanoon Ahmed,”The Discoverying of neural networks Learning rules using GAs”, Master’s thesis, 2002.
[6] Ho Sung C. Lee, ”Timetabling Highly Constrained system Via Genetic Algorithms”,
( Master’s
thesis)Masters of Science in Applied Mathematics, thesis Department of Mathematics College of science, University
of The Philippines Diliman, Quezon City, 2000. Email: hslee@admu.edu.ph
[7] Janet Hui-wen Hsiao, ”Literature Review- Genetic Algorithms”, 1999.
[8] 1 Schneier. Applied Cryptography , 2e. John Wiley & Sons. 1996.
M. Blaze, W. Diffie, R. L. Rivest, B. Schneier, T. Shimomura, E. Thompson, 2- Wiener. ``Minimal Key Lengths for
Symmetric
Ciphers
to
Provide
Adequate
Commercial
Security''.
Available
at
ftp://ftp.research.att.com/dist/mab/keylength.ps and http://theory.lcs.mit.edu/~rivest/bsa-final-report.ascii
[9] O. Billet, H. Gilbert, C. Ech-Chatbi, Cryptanalysis of a White-box AES Implementation, SAC,2004.
Volume 2, Issue 8, August 2013
Page 245
International Journal of Application or Innovation in Engineering & Management (IJAIEM)
Web Site: www.ijaiem.org Email: editor@ijaiem.org, editorijaiem@gmail.com
Volume 2, Issue 8, August 2013
ISSN 2319 - 4847
[10] [10] Draft ANSI X9.44, Public Key Cryptography for the Financial Services Industry - Key Establishment Using
Integer Factorization Cryptography, Draft 6, 2003
[11] Michael Backes, Birgit Pfitzmann, and Andre Scedrov. Key-dependent message security under active attacks brsim/uc-soundness of symbolic encryption with key cycles. In,20th IEEE Computer Security Foundations
Symposium (CSF’07), Venice, Italy, July,2007. IEEE. Extended version available at Cryptology ePrint Archive,
Report 2005/421, http://eprint.iacr.org/.
[12] John Black, Phillip Rogaway, and Thomas Shrimpton. Encryption-scheme security in the presence of key-dependent
messages. In Kaisa Nyberg and Howard M. Heys, editors,Selected Areas in Cryptography, volume 2595 of Lecture
Notes in Computer Science,pages 62–75. Springer, 2002
[13] Ronald Cramer and Victor Shoup. A practical public key cryptosystem provably secure against adaptive chosen
ciphertext attack. In Hugo Krawczyk, editor, CRYPTO, volume 1462 of Lecture Notes in Computer Science, pages
13–25. Springer, 1998.31
[14] Shafi Goldwasser and Silvio Micali. Probabilistic encryption. J. Comput. Syst. Sci.,28(2):270–299, 1984.
Volume 2, Issue 8, August 2013
Page 246
Download