One area of data science that has always interested me is Data Encryption. With security breaches happening on a daily basis I felt it would be a fun project to develop my own encryption algorithm using Markov principle. I realized that for a good encryption library you need 3 key components. Hand Shake/Identity Validation, Passcode to Key Encryption, and lastly of course the Core Encryption algorithm. Sicarii is a prototype cryptographic swift cipher framework library that has 2 of the 3 key components. The Core Encryption algorithm as well as PKE.
The library requires a minimum environment of swift 5 with iOS 12.2.
Sicarii cipher can use either a key & model, key, passcode or passcode with model encryption. The key generated is a 8192 bit array and the model generated is a 4096 bit array. The passcode used must be at least 8 chars long.
Encryption is achieved via constant multi directional dynamic transformations to ensure no simple substitution is applied. Passcode to key creation is achieved by a combination of (dynamic salting)+(char expansion)x2+(constant multi directional data transformations)+(sorting)+(normalization)x2
YOU CAN FIND THE FRAMEWORK LOCATED IN THE GITHUB PROJECT LIBRARY
Sample input and ecrypted showing only using 0’s and 1’s.
//Create instance let sicarii: SicariiCipher = SicariiCipher()
//Generate 512 Key let key = sicarii.generate512Key()
//Optionally generate model let model = sicarii.generateModel()
// To Encrypt Data returns [UInt8] let encrypted = sicarii.encrypt(ary: array, key: key, model: model)
// To Decrypt Data returns [UInt8] let decrypted = sicarii.decrypt(ary: encrypted, key: key, model: model)
//Using Passcode let sicarii: SicariiCipher = SicariiCipher() let encrypted = sicarii.encrypt(ary: array, passcode: “passcode”) let decrypted = sicarii.decrypt(ary: encrypted, passcode: “passcode”)