Sesame: config file encryption
Almost all applications have configuration of some kind, and often this config is sensitive - database passwords, SMTP account details, API keys etc.
These days it’s common to use public source control; which means you can no longer store your application’s sensitive config with your code.
Sesame provides a simple way to encrypt (and decrypt) your application’s config so it can be safely stored in public source control.
Cryptography
Sesame leans on a little known project called keyczar, which was originally built by members of the Google Security Team.
Keyczar in turn builds upon pycrypto which aims to provide sane defaults for your Python crypto.
Installation
To install sesame, simply:
$ pip install --pre sesame
Since pip version 1.4 the --pre parameter is necessary since keyczar is still an alpha release. People using earlier versions of pip can omit the --pre.
Usage
The interface to Sesame intentionally resembles that of tar. There are only two sub-commands: encrypt and decrypt as described below:
usage: sesame encrypt [-h] [-k KEYFILE] [-f]
outputfile inputfile [inputfile ...]
positional arguments:
outputfile Encrypted file to be created
inputfile Files to be encrypted
optional arguments:
-h, --help show this help message and exit
-k KEYFILE, --keyfile KEYFILE
Path to keyczar encryption key
-f, --force Force overwrite of existing encrypted file
usage: sesame decrypt [-h] [-k KEYFILE] [-f] [-O OUTPUT_DIR] [-T] inputfile
positional arguments:
inputfile File to be decrypted
optional arguments:
-h, --help show this help message and exit
-k KEYFILE, --keyfile KEYFILE
Path to keyczar encryption key
-f, --force Force overwrite of existing decrypted file
-O OUTPUT_DIR, --output-dir OUTPUT_DIR
Extract files into a specific directory
-T, --try-all Search for keys from current directory and try all of
them
Metadata
Release files for sesame 0.3.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| sesame-0.3.3.tar.gz | 7.7 kB | Without provenance | Details for sesame-0.3.3.tar.gz |
Release files / sesame-0.3.3.tar.gz
| Download URL | sesame-0.3.3.tar.gz |
|---|---|
| Size | 7.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
1bb1c56dbe1241c898b64aa25caff9d5c28e788006dfc8816b2b6dcda0ca7e73
|
|
BLAKE2b-256 checksum How to use checksums |
1974c05b56c44d979e2ac4a7e6b98c1a281fbc8988f6867efc98697b4ca88fdc
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for sesame 0.3.3
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.