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.5.0.tar.gz (6.0 kB view details)

Uploaded Source

Built Distribution

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

Uploaded Python 3

File details

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

File metadata

  • Download URL: imagecrypto-0.5.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.5.0.tar.gz
Algorithm Hash digest
SHA256 dae2577af60b7dabdd729fab403580f366cdba25fa73222b0bf72c1356c244c8
MD5 09f4f33c0cd62eb5d11990842c4aabb8
BLAKE2b-256 cc650c2b139c2a417a1f248dbe8759f8a4e9b144c8dcf9ae341bf346cbf5a8ef

See more details on using hashes here.

File details

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

File metadata

  • Download URL: imagecrypto-0.5.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.5.0-py3-none-any.whl
Algorithm Hash digest
SHA256 79d9465e65540780c62d3128689112b93734562aea6a85e5247c5328102af694
MD5 97727f21468d9e6ad3f267f20b29f6a6
BLAKE2b-256 0595e4931328c7b69031755f4e6631f50baa07092c0cd2e500914ff9cd9a4d45

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