Skip to main content

A simple way to encode plain text, keeps the result sortable and partly searchable.

Project description

srndcipher

A simple way to encode plain text, keeps the result sortable and partly searchable.

Install

pip install srndcipher

Usage

import os
import srndcipher

cipher1 = srndcipher.SrndCipher(password="Your password")
data1 = os.urandom(1024)
data2 = cipher1.encrypt(data1)
data3 = cipher1.decrypt(data2)
assert data1 == data3

cipher2 = srndcipher.SrndCipher(password="Your password", force_text=True)
data1 = "your plain message"
data2 = cipher2.encrypt(data1)
data3 = cipher2.decrypt(data2)
assert data1 == data3

Notice

  • SrndCipher instance init takes about 0.6 second time, so try to keep the instance reusable.

Test Passed With Python Versions

  • python 2.7
  • python 3.2
  • python 3.3
  • python 3.4
  • python 3.5
  • python 3.6
  • python 3.7
  • python 3.8
  • python 3.9
  • python 3.10
  • python 3.11

Releases

v0.5.0

  • First relase.

v0.6.2

  • Set SrndCipher.default_result_encoder to cipherutils.Utf8Encoder().
  • Works with fastutils>=0.42.11.

v0.6.3

  • Doc update.
  • Deps on zenutils.

v0.6.4

  • Doc update.

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

srndcipher-0.6.4.tar.gz (3.9 kB view details)

Uploaded Source

Built Distribution

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

srndcipher-0.6.4-py3-none-any.whl (3.7 kB view details)

Uploaded Python 3

File details

Details for the file srndcipher-0.6.4.tar.gz.

File metadata

  • Download URL: srndcipher-0.6.4.tar.gz
  • Upload date:
  • Size: 3.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.12

File hashes

Hashes for srndcipher-0.6.4.tar.gz
Algorithm Hash digest
SHA256 ff085636af18bede6dc56c017c045f0e60c81fb2b5508c7cb8cdbf7e58dc540f
MD5 b801411cbeddd9ec18cb6f5a0e34f027
BLAKE2b-256 08a5c16371e89b64fd3c4a80aae7256e29ba4f43b11824ff6ff269ab24c5660f

See more details on using hashes here.

File details

Details for the file srndcipher-0.6.4-py3-none-any.whl.

File metadata

  • Download URL: srndcipher-0.6.4-py3-none-any.whl
  • Upload date:
  • Size: 3.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.12

File hashes

Hashes for srndcipher-0.6.4-py3-none-any.whl
Algorithm Hash digest
SHA256 3e16b54cd8eb88f96d54d146effe85bbaefc3d2093a999fdc7712fd357043bd7
MD5 5c3f4feaa36cf2899b5d68fe5279a58a
BLAKE2b-256 2e9c5b356ace1f57b1842fd3db1320590df80e37014c316f3dfdf15d1c6bd46b

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