Skip to main content

ImageCrypto is a Python package for secure image encryption using various symmetric ciphers with asymmetric Elliptic Curve Cryptography (ECC) for key generation.

Reason this release was yanked:

Not working

Project description

🔐 ImageCrypto

License: MIT Python Versions

ImageCrypto is a powerful and easy-to-use Python package for secure image encryption using various symmetric ciphers with asymmetric Elliptic Curve Cryptography (ECC) for key generation.

🌟 Features & Available Modules

ImageCrypto offers multiple symmetric encryption algorithms, each implemented as a separate module:

  • aes_gcm_128: AES-128 in GCM mode
  • aes_ccm_128: AES-128 in CCM mode
  • aes_gcm_256: AES-256 in GCM mode
  • aes_eax_128: AES-128 in EAX mode
  • chacha20_poly1305: ChaCha20-Poly1305
  • salsa20: Salsa20

Key features:

  • Secure key generation using asymmetric ECC (SECP256R1 curve)
  • Fast symmetric encryption
  • Easy-to-use API
  • Performance metrics (encryption time)
  • Visualization of original and encrypted images

Each module provides the same API:

  • get_encrypted_image(image_path): Encrypts the image and returns the encrypted image data
  • get_encryption_time(image_path): Returns encryption time
  • display_images(original_path, encrypted_image): Displays the original and encrypted images

This consistent API across all encryption algorithms allows for easy comparison and flexibility in choosing the most suitable method for your needs.

🚀 Installation

Install ImageCrypto using pip:

pip install imagecrypto

📝 Usage Example

Here's an example of how to use ImageCrypto and display the results:

from imagecrypto import aes_gcm_256
import matplotlib.pyplot as plt

# Define the path for your original image
original_image = "path/to/your/image.jpg"

# Encrypt an image
encrypted_image = aes_gcm_256.get_encrypted_image(original_image)

# Get encryption time
encrypt_time = aes_gcm_256.get_encryption_time(original_image)
print(f"Encryption time: {encrypt_time:.2f} ms")

# Display the original and encrypted images
aes_gcm_256.display_images(original_image, encrypted_image)

Inputs

  • Path to an original image file (JPEG, PNG, etc.)

Outputs

  • Encrypted image data
  • Encryption time (in milliseconds)
  • Visual display of original and encrypted images

🛠️ Dependencies

  • OpenCV (cv2)
  • cryptography
  • pycryptodome
  • numpy
  • matplotlib

📄 License

ImageCrypto is released under the MIT License.

📧 Contact

Project Link: https://github.com/nidhi-bhatt/imagecrypto


Made with ❤️ by Nidhi

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

imagecrypto-0.6.0.tar.gz (6.0 kB view details)

Uploaded Source

Built Distribution

imagecrypto-0.6.0-py3-none-any.whl (10.5 kB view details)

Uploaded Python 3

File details

Details for the file imagecrypto-0.6.0.tar.gz.

File metadata

  • Download URL: imagecrypto-0.6.0.tar.gz
  • Upload date:
  • Size: 6.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.8.3 CPython/3.12.3 Linux/6.8.0-38-generic

File hashes

Hashes for imagecrypto-0.6.0.tar.gz
Algorithm Hash digest
SHA256 49143d5789bed14b58dbe696d8d8529015b37262a64e902e32935d086055c942
MD5 271fe7adc88eb73d1e77bea802ea46c1
BLAKE2b-256 36ac0b90b3cf41578f5ce64b6e21966a678818668de8191a48fe5a81d71156b6

See more details on using hashes here.

File details

Details for the file imagecrypto-0.6.0-py3-none-any.whl.

File metadata

  • Download URL: imagecrypto-0.6.0-py3-none-any.whl
  • Upload date:
  • Size: 10.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.8.3 CPython/3.12.3 Linux/6.8.0-38-generic

File hashes

Hashes for imagecrypto-0.6.0-py3-none-any.whl
Algorithm Hash digest
SHA256 34b05483311e25d0eab8e8594ee64341cb496c9bd972720f84ce8b5a844031ae
MD5 d92d4963c50874cac8ba1f8574893930
BLAKE2b-256 b917d9763bca4f9e6f68a55f2d131da2d080ffc9d64cfc82873cdbe7ca5fcdcb

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page