Skip to main content

Encrypt/Decrypt with ChaCha20-Poly1305

Project description

Vaulty

Encrypt/Decrypt with ChaCha20-Poly1305

Vaulty is an extremely lightweight encryption/decryption tool which uses ChaCha20-Poly1305 to provide 256-bit authenticated encryption (AEAD) using Scrypt as the password based key derivation function. It can be used to encrypt/decrypt files, or stdin if you don't specify any files - it is written in Python and requires Python 3.

If encrypting stdin then the output will be Base64 encoded whereas if encrypting a file then it won't and it will have a .vlt extension added to indicate it has been encrypted.

It relies on the cryptography Python module to provide the routines for ChaCha20-Poly1305 and Scrypt.

Installation

python3 -m pip install --upgrade --user pyvaulty

Vaulty Usage

vaulty encrypt|decrypt [file1[ file2[ ...]]]

Example Usage

echo "Hello World" | vaulty encrypt
$VAULTY;AY3eJ98NF6WFDMAP62lRdl58A2db5XJ2gNvKd0nmDs5ZrmNlJ8TSURpxc3bNF1iGw77dHA==

echo "$VAULTY;..." | vaulty decrypt
Hello World
from getpass import getpass
from vaulty import Vaulty

password = getpass('Vaulty Password: ').encode('utf-8')
ciphertext = Vaulty().encrypt('Hello World'.encode('utf-8'), password)

plaintext = Vaulty().decrypt(ciphertext, password).decode('utf-8')
if plaintext is None:
  print('error: invalid password or data not encrypted', file=sys.stderr)

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

pyvaulty-1.0.0.tar.gz (4.2 kB view details)

Uploaded Source

Built Distribution

pyvaulty-1.0.0-py3-none-any.whl (5.1 kB view details)

Uploaded Python 3

File details

Details for the file pyvaulty-1.0.0.tar.gz.

File metadata

  • Download URL: pyvaulty-1.0.0.tar.gz
  • Upload date:
  • Size: 4.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.6.0 importlib_metadata/4.8.2 pkginfo/1.8.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.2

File hashes

Hashes for pyvaulty-1.0.0.tar.gz
Algorithm Hash digest
SHA256 ec723a74ca4cd9837e17737836e2f58d19a0c77a8c132c5223d4ffac49a3285d
MD5 9111d86e192fd7becd6fe1409f6e06e5
BLAKE2b-256 17c9068b66ca4b73771a72fefcf1a1c7052414b3318c1c1cbb03ed071c4ce7fe

See more details on using hashes here.

File details

Details for the file pyvaulty-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: pyvaulty-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 5.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.6.0 importlib_metadata/4.8.2 pkginfo/1.8.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.2

File hashes

Hashes for pyvaulty-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 a33d0aa5f1c836afdd5e6ecb7766282fa33f247e6c4d883fd6c456017a67599d
MD5 1ca37294a80b3d65c7f85284d1f1e4f4
BLAKE2b-256 17aeb729d464e3316d2de7d4d27c0cbb068208625efc5539faf9224a0e55c9a0

See more details on using hashes here.

Supported by

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