- Open Access
- Authors : Dhanraj Chavan
- Paper ID : IJERTV11IS110107
- Volume & Issue : Volume 11, Issue 11 (November 2022)
- Published (First Online): 25-11-2022
- ISSN (Online) : 2278-0181
- Publisher Name : IJERT
- License: This work is licensed under a Creative Commons Attribution 4.0 International License
CryptoCam: An Approach to Enhance Cryptography with Machine Learning
Department of Computer Science & Engineering KITs College of Engineering, Kolhapur Kolhapur, Maharashtra, India
Abstract Every day, millions of text and other files are exchanged across the web. It is critical to safeguard the confidentiality and integrity of the data being sent. Cryptography plays a significant role in data security by providing different techniques. The computational difficulty of mathematical problems determines the security of cryptographic algorithms. Any breakthrough in the solution of such mathematical problems can expose a cryptographic technique. In this paper, the author will demonstrate a concept that can be used with machine learning to enhance cryptography. The paper summarizes the research done in this area & provides suggestions for future directions in research.
Keywords Cryptography, machine learning, cybersecurity, data security, data confidentiality, data integrity, encryption, decryption, security, cryptographic algorithms, cipher
As the world is evolving, and the demand for information services is proliferating, the need for advanced methods of securing data has increased.
Modern cryptography is built on mathematics, computer science, and cleverness. Furthermore, various technologies can be integrated into the process of cryptography to enhance encryption and decryption. When we require a machine to learn to solve a problem based on previously provided data, we call this machine learning. Machine learning can be an effective solution finder for situations that do not have a clear algorithm to solve.
This paper presents an overview of a new approach to how various technologies can be integrated into the cryptography process to innovate the future of Data Security, Data Confidentiality & Data Integrity.
CryptoCam aims to introduce & demonstrate a new concept of how machine learning can be used with cryptography to improve data security.
CryptoCam is a camera that uses Machine Learning to encrypt and decode data inside a physical item. CryptoCam uses VisionKit which provides the cameras live video used to recognize images or feed of objects & MobileNetV2 Machine Learning Model  which contains 53 layers of deep neural network and can categorize photos into 1000 categories.
Click on the "Encrypt" Button. Hold the camera steady focusing on the Object & it will capture the object.
It will start to analyze & classify the image of the object. CryptoCam will use the MobileNetV2 ML model to identify the name of the object in the image frame.
It will provide an alert with the name of the detected object; validate the name of the object. If it's not correct, then feel free to scan it again.
In the Text Field, Add the message that you want to encrypt
& tap on the "Save" button. CryptoData will save this encrypted message.
Your message is encrypted inside the object.
Click on the "Decrypt" Button & Hold the camera steady focusing on the Object.
It will start to analyze & classify the image of the object. After finishing the countdown, it will identify the name of
the object in the camera frame using ML Model & VisionKit.
If the indicated item is found in CryptoData, the message will be decrypted. After decrypting the message successfully, it will play the Success sound. Otherwise, it will play a Fail sound if the object is not found.
The message is decrypted.
In basic cryptography , encryption requires two parameters: plaintext & key whereas decryption requires two parameters: encrypted text & key. In the case of CryptoCam, it uses the same key for both encryption & decryption. Lets break down the process of Cryptocam & understand how the key is created dynamically with the help of an example.
Consider an object in our day-to-day life. Ex. Keyboard
When a user scans & captures the object using encrypt button, the live feed is monitored in real-time.
After the countdown finishes, the feed is passed to the MobileNetV2 ML model.
MobileNetV2 analyzes the feed & gives a result in the dictionary format. This dictionary is an array of key-value pairs where the key is the object name & value is the confidence percentage.
CryptoCam uses the top 5 results from the dictionary to create a dynamic key which is required for encryption.
An alert with the top 3 results & a text field will be shown where the user can verify the identity of the object & add a message in the text field.
CryptoCam will use the top 5 results as a key & user input as plaintext to encrypt.
For a demonstration of this concept, it will only store the combination of the top 5 results & plaintext. No further encryption algorithm is used. In the future, it will be stored
& retrieved using a specific cryptographic algorithm. AppStorage database from Apple Developer is used to store all the values.
For decryption, if you scan the same object, MobileNetV2 will identify the object & gives a result in the form of a dictionary.
CryptoCam will use the top 3 results in decryption. If these top 3 results are found in the stored results of AppStorage, the decrypted message will be shown to the user.
If these top 3 results do not found in the top 5 results of any stored results of AppStorage, it will throw an error that indicates that identification has failed.
The concept of the cryptographic algorithm used in CryptoCam is based on Object Identification done by MobileNetV2 ML Model. CryptoCam stores the results in AppStorage in a non-encrypted form. CryptoData is referred to as AppStorage here.
MobileNetV2  has been trained to identify the dominating object in a camera frame or image. It has 75% top 1 accuracy
& 92.5% top 5 accuracy .
For the demonstration purpose of this concept, top(top 5 for encryption, top 3 for decryption) results with high confidence values are chosen to maintain accuracy. To achieve high accuracy, other models can be used, but the size of the model increases as accuracy increases. To eliminate the size issue of the ML model, the ML model can be hosted on any cloud service & applications can connect to it via APIs. Hence, high accuracy with low size can be achieved in the future.
This project aimed to demonstrate a new concept of how Machine Learning can be used with Cryptography.
REFERENCES MobileNetV2, Apple Developer CoreML Models  Wade Trappe, Lawrence C. Washington – Introduction to Cryptography with Coding Theory  MobileNetV2, TensorFlow Models, GitHub(tensorflow/models)