CyCode is a robust, cross-platform C++ utility designed for secure file encryption and decryption. By leveraging the XOR Cipher and a custom Metadata Footer, it ensures your files are protected while maintaining their original identity.
- Universal Compatibility: Seamlessly encrypts any file format (Images, Videos, PDFs, Executables).
-
Zero-Footprint Processing: Employs an
$O(1)$ space complexity approach, processing files byte-by-byte to handle massive files without RAM overhead. - Smart Metadata Recovery: Implements a custom 32-byte footer to store the original file extension and a security signature.
- Cross-Platform Core: Built to run natively on both Windows and Linux systems.
The application utilizes a symmetric XOR operation. The beauty of this logic is its reversibility:
To avoid losing file types after renaming to .cry, CyCode appends a metadata block:
- Signature (Bytes 0-14):
NeTRuNNeRGLiTCH(Verification ID). - Original Extension (Bytes 15-31): Stores the file type (e.g.,
png,mp4) to restore it during decryption.
| Metric | Complexity | Description |
|---|---|---|
| Time Complexity | Linear pass through file bytes. | |
| Space Complexity | Minimal memory usage regardless of file size. | |
| Encryption Type | Symmetric | Repeated-key XOR Cipher. |
- C++ Compiler (MSVC for Windows, GCC for Linux).
- For Windows/Visual Studio:
_CRT_SECURE_NO_WARNINGSmust be defined.
- Clone the Repository:
git clone [https://github.com/NeTRuNNeRGLiTCH/CyCode.git](https://github.com/NeTRuNNeRGLiTCH/CyCode.git)
- Compile:
- Open
test.slnin Visual Studio and build in Release mode. - Or use G++:
g++ -o cycode main.cpp.
- Open
This project is developed for educational purposes to explore File I/O and basic cryptographic concepts in C++. While efficient, XOR-based encryption is not intended for high-security environments compared to standards like AES-256.