Skip to main content

"A simple encrypted key storage, now with a simple throttler (using Redis)"

Project description

simple_keystore

This is a simple key storage solution for development or on-prem use. Use secrets/other builtin more-secure provider methods for production.

Uses an SQLite database to store/retrieve encrypted keys with metadata including expiration dates.

Uses Redis to throttle key usage.

There is a Dockerfile included, and .devcontainer for use with VSCode.

Requirements

If you are going to use the throttler (SKSRateThrottler), you will need Redis. This is not necessary if just using SimpleKeystore.

sudo apt-get install -y redis-server
sudo service redis-server start 

Installation

pip install simple_keystore

Usage

You can set the encryption key either via environment variable or as an entry in your .netrc where the password is the key and machine is SIMPLE_KEYSTORE_KEY

export SIMPLE_KEYSTORE_KEY = "myencryptionkeyphrase"

Create an SQLite DB to store keys in python:

ks = SimpleKeyStore(KEYSTORE_FILE_NAME)

# See tests/test_simple_keystore.py for adding keys, etc.

Add/Remove keys manually / intractively in bash with:

manage_simple_keys <KEYSTORE_FILE_NAME>

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

simple_keystore-0.6.1.tar.gz (19.8 kB view details)

Uploaded Source

Built Distribution

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

simple_keystore-0.6.1-py3-none-any.whl (16.0 kB view details)

Uploaded Python 3

File details

Details for the file simple_keystore-0.6.1.tar.gz.

File metadata

  • Download URL: simple_keystore-0.6.1.tar.gz
  • Upload date:
  • Size: 19.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: pdm/2.22.3 CPython/3.10.16 Linux/5.15.167.4-microsoft-standard-WSL2

File hashes

Hashes for simple_keystore-0.6.1.tar.gz
Algorithm Hash digest
SHA256 7e285fbc5578d0e8f5d99861f60fc6c3882b79e9d3a7a98880c9d9d26db87617
MD5 fd8f365766257464f27a82273748ae5b
BLAKE2b-256 5d21dda6caae31f2f831b89db25e0fba2be2b74d9e8695665c2e22bf69d83b53

See more details on using hashes here.

File details

Details for the file simple_keystore-0.6.1-py3-none-any.whl.

File metadata

  • Download URL: simple_keystore-0.6.1-py3-none-any.whl
  • Upload date:
  • Size: 16.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: pdm/2.22.3 CPython/3.10.16 Linux/5.15.167.4-microsoft-standard-WSL2

File hashes

Hashes for simple_keystore-0.6.1-py3-none-any.whl
Algorithm Hash digest
SHA256 7d4112e4bc0bd6775b72733f2c63798ce5e3a9da7996bf43fa36437a3e73414d
MD5 40f153689d1b5d0b980802b33f3b2cf8
BLAKE2b-256 5010d0b27be78361a478a7f53ffffa1e5a62f9beab8b76bde89a83c6a833ed84

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