Skip to content

A lightweight, educational Python tool that demonstrates how to hide secret text inside RGB images using XOR encryption and ASCII encoding. This project showcases basic steganography principles by embedding encrypted messages directly into pixel color values.

License

Notifications You must be signed in to change notification settings

arshc0der/stego-xor-rgb-encoder

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation


🔐 stego-xor-rgb-encoder

A simple and educational steganography tool for hiding encrypted text inside RGB images using XOR encryption and ASCII encoding.

Project Cover

Status Badge License Badge Platform Badge Encryption Badge OpenCV Badge NumPy Badge Matplotlib Badge Stars Badge Forks Badge

Last Commit


📌 Overview

stego-xor-rgb-encoder allows you to:

  1. Encrypt a secret text using XOR cipher with a user-provided key.
  2. Embed the encrypted text into the pixel values of an RGB image.
  3. Extract and Decrypt the hidden message using the same key.

This combines encryption and steganography in a lightweight, easy-to-understand way.


✨ Features

  • 🔐 XOR encryption with a customizable key
  • 🎨 Embedding encrypted data into RGB pixels
  • 🧩 Compatible with JPG, PNG, and similar formats
  • 📘 Fully documented Jupyter Notebook for educational use

🛠 Tech Stack

  • Python 3.8+
  • OpenCV (cv2) for image operations
  • NumPy
  • Matplotlib for visual output

📂 Repository Structure

stego-xor-rgb-encoder/
├── stego-xor-rgb-encoder.ipynb     # Fully commented notebook
├── encrypted_output.jpg            # Sample result image (for quick access)
├── README.md                       # Project documentation (you're here)
├── LICENSE                         # MIT License
├── assets/                         # Visual assets for demo
│   ├── original.jpg                # Original unmodified image
│   ├── encrypted_output.jpg        # Encrypted image with hidden text

🚀 Quick Start

📥 Clone this repo:

git clone https://github.com/arshc0der/stego-xor-rgb-encoder.git
cd stego-xor-rgb-encoder

⚙️ Run the Notebook:

Open StegnoRGBImplementation.ipynb in Jupyter and follow the step-by-step instructions.


💡 Usage Example

secret_text = "hello"
encryption_key = "key123"
  • Encrypt and embed each character via XOR using the key.
  • Embedded values are hidden inside pixel channels.
  • Extract and decrypt using the same key.

🖼️ Demo

Original Image Encrypted Image
Original Encrypted

⚠️ Disclaimer

This project is for educational purposes only and is not intended for secure communications. It lacks cryptographic rigor and should NOT be used in production. For real encryption, use proven algorithms (AES, RSA) via libraries like cryptography or PyCryptoDome.


📜 License

Licensed under the MIT License. See LICENSE for details.


🙌 Contributing

Contributions, bug reports, and enhancements are welcome! Please fork the repo and create a pull request.


🎓 Author

arshc0der 📚 Exploring steganography & lightweight encryption methods


About

A lightweight, educational Python tool that demonstrates how to hide secret text inside RGB images using XOR encryption and ASCII encoding. This project showcases basic steganography principles by embedding encrypted messages directly into pixel color values.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published