Skip to main content

A Python package that provides robust encryption and decryption mechanisms, utilizing AES, FERNET, JWE, Hybrid Encryption, AWS KMS, and AWS Secrets Manager.

Project description

🔐 Cryptorix

Cryptorix is a powerful Python package that makes it easy to securely encrypt and decrypt data using:

  • AES, FERNET, JWE, and Hybrid Encryption
  • AWS KMS and Secrets Manager for secure key management

It supports both symmetric (AES) and asymmetric (RSA) encryption, and integrates directly with AWS services to keep your secrets safe.

🧩 Overview

Cryptorix simplifies encryption workflows by offering modular support for:

  • AES and FERNET for secure data encryption
  • JWE for secure token exchange
  • Hybrid Encryption (AES + RSA)
  • AWS KMS for encrypting values
  • AWS Secrets Manager for retrieving and decrypting secrets

🚀 Features

AES

Encrypt and decrypt Python dictionaries with AES encryption.

from Cryptorix.aes import encrypt, decrypt

encrypted = encrypt(data="your_data", hex_key="your_hex_key")
decrypted = decrypt(encrypted_data=encrypted, hex_key="your_hex_key")

Fernet

Encrypt and decrypt Python dictionaries with Fernet encryption.

from Cryptorix.fernet import encrypt, decrypt

encrypted = encrypt(data="your_data", key=b"your_key")
decrypted = decrypt(encrypted_data=encrypted, key=b"your_key")

JWE

Use RSA + AES-GCM to encrypt and decrypt data in JWE format.

from Cryptorix.jwe import encrypt, decrypt

jwe_token = encrypt(data={}, public_key_pem="your_public_key_pem")
original_data = decrypt(encrypted_data=jwe_token, private_key_pem="your_private_key_pem")

Hybrid Encryption

Combines AES for content and RSA for key encryption.

from Cryptorix.hybrid import encrypt, decrypt

result = encrypt(data={}, public_key_pem="your_public_key_pem")
original = decrypt(
    encrypted_data=result["encryptedData"],
    encrypted_key=result["encryptedKey"],
    private_key_pem="your_private_key_pem"
)

AWS KMS

Encrypt and decrypt plain strings using AWS Key Management Service.

from Cryptorix.kms import encrypt, decrypt

enc = encrypt(plaintext="hello", kms_key_id="your_kms_key_id")
dec = decrypt(ciphertext_b64=enc)

AWS Secrets Manager

Fetch secrets securely from AWS.

from Cryptorix.secrets import get_secret_dict, get_secret_value

all_secrets = get_secret_dict(secret_name="your_secret_name")
plain = get_secret_value(secret_name="your_secret_name", key="your_secret_key")

📦 Installation

Install via pip:

pip install Cryptorix

✅ AWS Permissions

Ensure the following IAM permissions:

  • KMS

    • kms:Encrypt
    • kms:Decrypt
  • Secrets Manager

    • secretsmanager:GetSecretValue

🧰 Dependencies


📄 License

MIT License


🤝 Contributing

Contributions are welcome! Feel free to open issues or pull requests.


👤 Author

M Santhosh Kumar 📧 santhoshse7en@gmail.com


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

cryptorix-1.0.7.tar.gz (8.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

cryptorix-1.0.7-py3-none-any.whl (10.8 kB view details)

Uploaded Python 3

File details

Details for the file cryptorix-1.0.7.tar.gz.

File metadata

  • Download URL: cryptorix-1.0.7.tar.gz
  • Upload date:
  • Size: 8.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.2

File hashes

Hashes for cryptorix-1.0.7.tar.gz
Algorithm Hash digest
SHA256 5c0df4c6a26f5088cabbd705b9e2ed87341bacf84aa278a8106d65526365cf6a
MD5 65c768914a5257eba80f156c86873cb3
BLAKE2b-256 2f6908437d8ce7ad1ebe8f814c7fe8b77186766ca687a0398b32ede18d2702f6

See more details on using hashes here.

File details

Details for the file cryptorix-1.0.7-py3-none-any.whl.

File metadata

  • Download URL: cryptorix-1.0.7-py3-none-any.whl
  • Upload date:
  • Size: 10.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.2

File hashes

Hashes for cryptorix-1.0.7-py3-none-any.whl
Algorithm Hash digest
SHA256 7586c5d359fde9f1ccdb2bc676129754e2f343c6f62eb0c5d03eaf7cf3a3020c
MD5 78e8060d00d795a9048e147c538002b5
BLAKE2b-256 5657bb2786e045d0a0ac2c33676b0a4821630589ced3dbcf24e772876d474e9c

See more details on using hashes here.

Supported by

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