Skip to main content

kripta-py

An simple implementation of a Symmetric(AES) and Asymmetric(RSA) encryption based on pycryptodome module.

Requirements

  • Python (3.10 recommended)

Features

  • Generate RSA keys like
  • Encrypt/Decrypt messages, files, binaries on symmetric or asymmetric

How to use

  • Install the lib
pip install kripta-py
  • To use the symmetric encryption (AES):

    • Schema :

      drawing

    • Code :

      from kripta_py import KriptaAES
      
      
      message = "secret-message"
      secret_key = "secret-code-password"
      
      k = KriptaAES()
      # to encrypt
      encrypted_msg = k.encrypt(message, secret_key)
      
      # to decrypt
      print(k.decrypt(encrypted_msg1, secret_key).decode())
      # secret-message 
      
  • To use an asymmetric encryption (RSA):

    • Schema :

      drawing

    • Code example:

      from kripta_py import KriptaRSA
      
      
      message = "secret-message"
      pub_key = """-----BEGIN PUBLIC KEY-----
      ....
      -----END PUBLIC KEY-----"""
      
      k = KriptaRSA()
      k.setPublicKey(pub_key)
      # To encrypt a message
      encrypted_msg = k.encrypt(k.getPublicKey(), message.encode())
      
      priv_key = """-----BEGIN RSA PRIVATE KEY-----
      .....
      -----END RSA PRIVATE KEY-----"""
      
      k.setPrivateKey(priv_key)
      # To decrypt
      print(k.decrypt(encrypted_msg).decode())
      # secret-message 
      

Release files for kripta-py 0.1.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for kripta-py 0.1.3
File Size Uploaded
kripta-py-0.1.3.tar.gz 5.5 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for kripta-py 0.1.3
File Interpreter ABI Platform
kripta_py-0.1.3-py3-none-any.whl Python 3 none any Details

Total release size: 11.2 kB

Release files / kripta-py-0.1.3.tar.gz

Download URL kripta-py-0.1.3.tar.gz
Size 5.5 kB
Tags Source
SHA-256 checksum
How to use checksums
5bfed33c6eae330a0cc44d35b425d2c9659eae8e91095faa11d59579007f61fb
BLAKE2b-256 checksum
How to use checksums
5709813b98ed0ba590f37438cf4d81f3ca68167b26c44f5d50c0cae1d14e4c79
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.1.13 CPython/3.10.4 Linux/5.14.0-1036-oem

Release files / kripta_py-0.1.3-py3-none-any.whl

Download URL kripta_py-0.1.3-py3-none-any.whl
Size 5.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
d62082d33cd7c182a49b9354fde3a4a749e80aaaf3493007b0e01222f4201b2e
BLAKE2b-256 checksum
How to use checksums
b7da3195350229275125056a66acbeddf9cd4e755166e05b1e7858d84b8e897c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.1.13 CPython/3.10.4 Linux/5.14.0-1036-oem

Release history Release notifications | RSS feed

This release

0.1.3 This release

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page