Secure Barcode Authentication using Genetic Algorithm

Dr. Poornima G. Naik
Mr. Girish R. Naik

Don't use plagiarized sources. Get Your Custom Essay on
Secure Barcode Authentication using Genetic Algorithm
Just from $13/Page
Order Essay

 
Abstract— Genetic Algorithm (GA) is an invaluable tool for solving optimization problems due to its robustness. It does not break even if the inputs are changed slightly or in the presence of a reasonable noise. GA offers significant benefits over other optimization techniques in searching a large state space or n-dimensional surface. In todays information age information sharing and transfer has increased exponentially. With the popularization of Internet and exponential increase in e-commerce transactions security has become an inevitable and an integral part of any e-commerce application. Data integrity, confidentiality, authenticity, non-repudiation have gained tremendous importance and have become important components of information security. In this paper we have made an attempt to exploit the randomness involved in crossover and mutation processes of GA for generating a barcode for authentication process. The number of crossover points and number of mutation points is fixed and cannot be altered by the user. In the current work we have employed a single crossover point and two mutation points. We have used Code-39 and Code-128 encoding techniques for generating a barcode. The barcode data comprises of 12 randomly generated decimal digits. Each decimal digit is represented using 4 bits. Hence the length of the barcode data is 36 bits. The randomly generated data is transformed into encoded form by applying crossover, mutation and XOR operations before generating a bar code. The randomness together with encoding makes the password robust and hard to track. Finally, the algorithm is implemented in Java and applied for authentication of employee data in a hypothetical organization. The methodology is general and can be applied to any task where authentication is required.
Index Terms— Genetic Algorithm, Cross-over, Mutation, Barcode, Encoding.
The paper is organized as follows. The first section gives an introduction to Genetic Algorithm under the heading of Introduction. Section II covers the literature survey and the current scenario of application of soft computing in implementing security. Section III focuses on the proposed method of barcode generation using Genetic Algorithm. Section IV covers implementation of the algorithm in Java. Finally, Section V is devoted for conclusion and scope for future enhancements.
I. Introduction
Genetic algorithms (GA) are adaptive heuristic search algorithms based on the evolutionary ideas of natural selection and genetics [1]. They are based on the principle of Darwinian idea of survival of the fittest and natural genetics.

Genetic Algorithm

Generally, a Genetic Algorithm consists of three basic operations.

Selection
Crossover
Mutation

The first step consists of searching individuals for reproduction. In our problem, we have selected two vectors of 16 bytes each as parents for reproduction. Since the problem is of encryption, there is no special preference given to any particular selection method. All the vectors are selected sequentially based on their order of appearance in a text file.
Cross-over is the process of taking two parents and producing from them a child. In an optimization problem, crossover operator is applied to the mating pool with the hope that it creates a better offspring. For the problem under consideration, crossover is taken as one of the steps in producing a decrypted vector. We have employed four-point crossover method. In the case of optimization problem, selecting more than four crossover points will result in the disruption of building blocks whereas in the case of encryption larger the disruption better is the algorithm which makes it robust and difficult to break.

Get Help With Your Essay
If you need assistance with writing your essay, our professional essay writing service is here to help!
Essay Writing Service

After crossover, the vectors are subject to mutation. In optimization problem, mutation prevents the algorithm from being trapped in a local minimum. Mutation plays the role of recovering the lost genetic matter as well for randomly distributed genetic information. In encryption problem, mutation is employed for inducing disorder into the vector. It introduces a new genetic structure in the population by randomly modifying some of the building blocks and maintains diversity into the population. We have employed flipping method, in which for a character 1 in mutation chromosome, the corresponding character b in the parent chromosome is flipped from b to (9-b) and corresponding child chromosome is produced. In the following example 1 occurs at
two random places of mutation chromosome, the corresponding characters in parent chromosomes are flipped and the child chromosomes are generated.

Structure of Code128 Bar Code

Barcodes are made up of a series of lines that vary in width and correspond to various numeric, alphanumeric, or multicode configurations which can then be read in by a laser barcode scanner.Code 128 is a very effective, high-density symbology which permits the encoding of alphanumeric data. It includes verification protection both via a checksum digit and byte parity checking. This symbology has been widely implemented in many applications where a relatively large amount of data must be encoded in a relatively small amount of space. Itsspecific structure also allows numeric data to be encoded at, effectively, double-density. A Code 128 barcode consists of a leading “quiet zone”, one of three start codes, the data itself, a check character, a stop character, and a trailing quiet zone as shown in Fig. 1. The Code 128 data is encoded in strips of bars and spaces. The sequences of zeros or ones simply appear as thicker bars or spaces. The checksum is included in the barcode, and is a digit that verifies that the data just read in was correct. The checksum digit is based on a modulo 103 calculation based on the weighted sum of the values of each of the digits in the message that is being encoded, including the start character.

Fig. 1. Code-128 Barcode
Similar structure exists for Code-39 Barcode.
ii Literature survey
In literature to date, many GA based encryption algorithms have been proposed. A. Tragha et.al [2] have describe a new symmetric block cipher system namely, ICIGA (Improved Cryptographic Inspired by Genetic Algorithm) which generates a session key in a random process. The block size and key length are variables and can be fixed by the end user in the beginning of the cipher process. ICIGA is an enhancement of the system GIC (Genetic Algorithm inspired Cryptography) [3]. There are various proposed methods for image encryption such as quad tree approach, cellular automata [4, 5]. There are wide applications of GA in solving non-linear optimization problems in various domains [6,7]. But very few papers exist which exploit the randomness in the algorithm for implementation of security. Chaos theory and entropy have large application in secure data communication and the desired disorder is provided by inherent nature of genetic algorithm [8, 10]. Mohammad SazzadulHoque et.al [11] have presented an intrusion detection system by applying GA to efficiently detect various types of network intrusions. They have used evolutionary theory to filter the traffic data and thus reduce the complexity [12]. There are several papers related to IDS all of which use GA in deriving classification rules [13, 15]. But to the best of our knowledge very few papers exist which exploit randomness in generating barcode for authentication purpose.
III Proposed Method
Fig. 2. Application Architecture
We have used Code-39 and Code-128 encoding techniques for generating a barcode. The barcode data comprises of 12 randomly generated decimal digits. Each decimal digit is represented using 4 bits. Hence the length of the barcode data is 36 bits.The randomly generated data is transformed into encoded form by applying crossover, mutation and XOR operations before generating a bar code. The application architecture is shown in Fig. 2.

Data

Encoding

Barcode Generation

Physical File

Pseudocode

The pseudo code for barcode generation process using GA is depicted in Fig 3.
Step 1 : Generate a 12 digit random number and store it in a vector.
Step 2 : Each decimal digit in step 1 can be represented using 4 binary digits. Hence the total number of binary digits required to represent the data is 4 x 12 = 48 bits. Generate a hash H, by repeating digits 0 and 1 (if the digit is > 8) and 0 and 0, otherwise, required number of times.
Step 3 : Perform the XOR operation between the data and a 48-bit hash computed above.
Step 4 : Split the vector into two vectors of size six each.
Step 5 : Compute 10’s complement of each digit.
Step 6 : Perform the crossover operation at the midpoint.
Step 7 : Perform the mutation at the extreme positions of the vector. The mutation operation consists of flipping the digit from its original value to its complement.
Step 8 : Combine the vectors to reconstruct a 12-digit vector.
Step 9 : Perform the XOR operation between the data and a 48-bit hash computed above.
Step 10 : Use the 12-digit number generated above to generate a barcode in code-128 fromat.
Step 11 : End
Fig 3 Pseudo code for barcode generation using GA

Mathematical Formulation.

Let the original vector be represented by VOriginal. Let H be the hash constructed as follows.
H= ∑’ Hi where 1 Hi = 0000, for i = 8 or 9
= 0101, otherwise.
H is the generated hash of length 48 bits.
Compute the hash of VOriginal as shown below:
VOriginal θ H = VHash
Split the hash into two vectors of size six each. Let the two parts be represented by, V1Hash and V2Hash, respectively.
VHash = V1Hash + V2Hash
 
Compute 10’s complement of each digit. Let the two parts be represented by ( V1Hash)́ and (V2Hash )́, respectively.
Perform the crossover operation at the midpoint. Let the two new parts now be represented by C( V1Hash )́ and C(V2Hash ), respectively, where C is the crossover operator.
Perform the mutation at the extreme positions of the vector. Let the two parts now be represented by MC( V1Hash )́ and MC(V2Hash ) ́, respectively, where M is the crossover operator. Combine the vectors to reconstruct a 12-digit vector.
Perform the XOR operation between the data and a 48-bit hash, H computed above to generate a final vector. Let it be VTransformed. We get,
VTransformed = [ MC( V1Hash )́ + MC(V2Hash ) ́] θ H (1)
Decoding Vector into original Vector
Perform XOR operation between H and VTransformed given by equ(1) to get, [ MC( V1Hash )́ + MC(V2Hash ) ́].
Split the hash into two vectors of size six each. Let the two parts be represented by, MC( V1Hash )́ and MC(V2Hash ) ́ respectively.
Perform reverse mutation operation and then reverse cross0ver operation on two individual parts to get, ( V1Hash)́ and (V2Hash ) ́, respectively.
Take 10’s complement of each digit in the two vectors to get, ( V1Hash) and (V2Hash ), respectively.
Combine the two vectors to get VHash, where
VHash =VOriginal θ H
Perform XOR operation between H and VHashto get the original vector.
The entire process of generating the barcode is illustrated below with the help of an example.
Step 1: Generate a 12 digit random number and store it in a vector. Let the number be represented by

Step 2 : Generate Hash H as shown below.

Step 3 : Perform the XOR operation between the data and a 48-bit hash computed above.

Step 4 : Split the vector into two vectors of size six each.

and

Step 5 : Compute 10’s complement of each digit.

and

Step 6 : Perform the crossover operation at the midpoint.

and

Step 7 : Perform the mutation at the extreme positions of the vector.

Step 8 : Combine the vectors to reconstruct a 12-digit vector.

Step 9 :Generate Hash H as shown below..

Step 10 : Perform the XOR operation between the data and a 48-bit hash computed above

Step 11 : Use the 12-digit number generated above to generate a barcode in code-128 fromat.
CODE128- 996108946439.

Decoding the barcode

Step 1: Extract the rightmost 12 digits from the barcode.

Step 2 : Generate a hash as shown below:

Step 3 : Perform the XOR operation between the data and a 48-bit hash computed above

Step 4 : Split the vector into two vectors of size six each.

Step 5 : Perform reverse mutation at the extreme positions of the vector.

and

Step 6 : Perform the crossover operation at the midpoint.

and

Step 7 : Compute 10’s complement of each digit.

and

Step 8 : Combine the vectors to reconstruct a 12-digit vector.

Step 9 : Generate a hash as shown below:

Step 10 : Perform the XOR operation between the data and a 48-bit hash computed above

which represents the original vector
iv implementation in JAVA
The model proposed above is implemented in Java using MS Access as backend and Swing for GUI development. JDBC Type-I driver is used. The structure of the Barcode table used in the implementation is as follows :

Column Name

Column Type

Description

Name

Text

Stores User Name of an Employee

Barcode

Text

Stores encoded barcode data.

ID

Text

Stores unique identification for an Employee.

The following figures 4.1 to 4.4 show the output windows generated by Barcode tool developed in Java.

Fig. 4.1 Java Barcode Generation Tool

Fig. 4.2 Generation of Barcode

Fig. 4.3 Barcode generated in Code-39 Format

Fig. 4.4 Barcode Authentication Process.
V.CONCLUSION AND SCOPE FOR FUTURE WORK
In this paper we have proposed a model for barcode generation based on genetic algorithm and is implemented in Java for authentication of employees in a hypothetical organization. The password is encrypted by applying crossover, mutation and XOR operations and is difficult to track. This model provides a unique security layer on top of existing barcode security layer which makes the password more robust and difficult to break. Even if the database is hacked, the password cannot be stolen because the relationship between barcode and ID is not known. The model can be employed in situations where authentication is of prime significance and can be used for secure transmission of limited data such as credit card number. It provides a cheaper solution to RFID for authentication. Due to the symmetry in the operations involved and symmetry of XOR operation, the coding and encoding processes are reversible. Our future work consists of interfacing the software with barcode scanner and study of various coding techniques with reference to their applicability.
References

David. E. Goldberg, “Genetic Algorithms in Search, Optimization, and Machine Learning”, Pearson Education, 1989, ISBN-13: 978-020115767.
X. F. Liao, S. Y.Lai and Q. Zhou. Signal Processing. 90 (2010) 2714–2722.
H. Cheng and X. Li. IEEE Transactions on Signal Processive. 48 (8) (2000) 2439–2451.
O. Lafe. Engineering Applications of Artificial Intelligence. 10 (6) (1998) 581–591.
R. J. Chen and J. L. Lai. Pattern Recognition. 40 (2007) 1621–1631
Dr.Poornima G. Naik, Girish R. Naik, Application of Genetic Algorithm to Mass Production Line for Productivity Improvement, International Journal of Latest Trends in Engineering and Technology (IJLTET) Special Issue – IDEAS-2013 ISSN:2278-621X.
S. Li, G. Chen and X. Zheng. Multimedia security handbook. LLC, Boca Raton, FL, USA: CRC Press; (2004) [chapter 4].
Y. Mao and G. Chen. Handbook of computational geometry for pattern recognition, computer vision, neural computing and robotics. Springer; (2003).
H. S. Kwok, W. K. S. Tang, Chaos Solitons and Fractals, (2007) 1518–1529.
Mohammad SazzadulHoque, Md. Abdul Mukit and Md. Abu NaserBikas,An Implementation of Intrusion Detection System Using Genetic Algorithm, International Journal of Network Security & Its Applications (IJNSA), Vol.4, No.2, March 2012
L.M.R.J Lobo, Suhas B. Chavan, Use of Genetic Algorithm in Network Security, International Journal of Computer Applications (0975 – 8887)Volume 53– No.8, September 2012
W. Lu, I. Traore, “Detecting New Forms of Network Intrusion Using Genetic Programming”. Computational Intelligence, vol. 20, pp. 3, Blackwell Publishing, Malden, pp. 475-494, 2004.
M. M. Pillai, J. H. P. Eloff, H. S. Venter, “An Approach to Implement a Network Intrusion Detection System using Genetic Algorithms”, Proceedings of SAICSIT, pp:221-228, 2004.
S. M. Bridges, R. B. Vaughn, “Fuzzy Data Mining And Genetic Algorithms Applied To Intrusion Detection”, Proceedings of 12th Annual Canadian Information Technology Security Symposium, pp. 109-122, 2000.
M. Middlemiss, G. Dick, “Feature selection of intrusion detection data using a hybrid geneticalgorithm/KNN approach”, Design and application of hybrid intelligent systems, IOS Press Amsterdam, pp.519-527, 2003.

 

What Will You Get?

We provide professional writing services to help you score straight A’s by submitting custom written assignments that mirror your guidelines.

Premium Quality

Get result-oriented writing and never worry about grades anymore. We follow the highest quality standards to make sure that you get perfect assignments.

Experienced Writers

Our writers have experience in dealing with papers of every educational level. You can surely rely on the expertise of our qualified professionals.

On-Time Delivery

Your deadline is our threshold for success and we take it very seriously. We make sure you receive your papers before your predefined time.

24/7 Customer Support

Someone from our customer support team is always here to respond to your questions. So, hit us up if you have got any ambiguity or concern.

Complete Confidentiality

Sit back and relax while we help you out with writing your papers. We have an ultimate policy for keeping your personal and order-related details a secret.

Authentic Sources

We assure you that your document will be thoroughly checked for plagiarism and grammatical errors as we use highly authentic and licit sources.

Moneyback Guarantee

Still reluctant about placing an order? Our 100% Moneyback Guarantee backs you up on rare occasions where you aren’t satisfied with the writing.

Order Tracking

You don’t have to wait for an update for hours; you can track the progress of your order any time you want. We share the status after each step.

image

Areas of Expertise

Although you can leverage our expertise for any writing task, we have a knack for creating flawless papers for the following document types.

Areas of Expertise

Although you can leverage our expertise for any writing task, we have a knack for creating flawless papers for the following document types.

image

Trusted Partner of 9650+ Students for Writing

From brainstorming your paper's outline to perfecting its grammar, we perform every step carefully to make your paper worthy of A grade.

Preferred Writer

Hire your preferred writer anytime. Simply specify if you want your preferred expert to write your paper and we’ll make that happen.

Grammar Check Report

Get an elaborate and authentic grammar check report with your work to have the grammar goodness sealed in your document.

One Page Summary

You can purchase this feature if you want our writers to sum up your paper in the form of a concise and well-articulated summary.

Plagiarism Report

You don’t have to worry about plagiarism anymore. Get a plagiarism report to certify the uniqueness of your work.

Free Features $66FREE

  • Most Qualified Writer $10FREE
  • Plagiarism Scan Report $10FREE
  • Unlimited Revisions $08FREE
  • Paper Formatting $05FREE
  • Cover Page $05FREE
  • Referencing & Bibliography $10FREE
  • Dedicated User Area $08FREE
  • 24/7 Order Tracking $05FREE
  • Periodic Email Alerts $05FREE
image

Our Services

Join us for the best experience while seeking writing assistance in your college life. A good grade is all you need to boost up your academic excellence and we are all about it.

  • On-time Delivery
  • 24/7 Order Tracking
  • Access to Authentic Sources
Academic Writing

We create perfect papers according to the guidelines.

Professional Editing

We seamlessly edit out errors from your papers.

Thorough Proofreading

We thoroughly read your final draft to identify errors.

image

Delegate Your Challenging Writing Tasks to Experienced Professionals

Work with ultimate peace of mind because we ensure that your academic work is our responsibility and your grades are a top concern for us!

Check Out Our Sample Work

Dedication. Quality. Commitment. Punctuality

Categories
All samples
Essay (any type)
Essay (any type)
The Value of a Nursing Degree
Undergrad. (yrs 3-4)
Nursing
2
View this sample

It May Not Be Much, but It’s Honest Work!

Here is what we have achieved so far. These numbers are evidence that we go the extra mile to make your college journey successful.

0+

Happy Clients

0+

Words Written This Week

0+

Ongoing Orders

0%

Customer Satisfaction Rate
image

Process as Fine as Brewed Coffee

We have the most intuitive and minimalistic process so that you can easily place an order. Just follow a few steps to unlock success.

See How We Helped 9000+ Students Achieve Success

image

We Analyze Your Problem and Offer Customized Writing

We understand your guidelines first before delivering any writing service. You can discuss your writing needs and we will have them evaluated by our dedicated team.

  • Clear elicitation of your requirements.
  • Customized writing as per your needs.

We Mirror Your Guidelines to Deliver Quality Services

We write your papers in a standardized way. We complete your work in such a way that it turns out to be a perfect description of your guidelines.

  • Proactive analysis of your writing.
  • Active communication to understand requirements.
image
image

We Handle Your Writing Tasks to Ensure Excellent Grades

We promise you excellent grades and academic excellence that you always longed for. Our writers stay in touch with you via email.

  • Thorough research and analysis for every order.
  • Deliverance of reliable writing service to improve your grades.
Place an Order Start Chat Now
image

Order your essay today and save 30% with the discount code Happy