Skip to main content

Utility tool to encrypt data using AWS KMS and store it in preferred backend.

Project description

aws-ket

Utility tool to encrypt data using AWS KMS and store it in preferred backend.

License

Overview

AWS-KET (AWS KMS Encryption Tool) uses AWS KMS Key to encrypt and decrypt files/contents based on user provided kms keys and push them to a datastore backend (S3, RDS or DynamoDB).

GitHub issues CodeQL Build Status codecovPyPIDocumentation Status

Setup

This application will only work if you have AWS account with full privileges on KMS and S3 services in AWS. You should also have aws cli tool installed.

Setup AWS CLI

Note: Currently this tool only uses AWS region us-east-2 for usage of kms and s3.

Initaliztion of app

cd src
python init.py

Encrypt text/file

python app.py --text <TEXT_TO_ENCRYPT> --save <FILE_NAME_IN_S3> 
python app.py --file <PATH_OF_FILE_TO_ENCRYPT> --save <FILE_NAME_IN_S3>

Decrypt text/file from S3

This will save with same name as remote

python app.py --decrypt <FILE_NAME_IN_S3> 

OR
To specify name for saved file

python app.py --decrypt <FILE_NAME_IN_S3>  --save <FILE_NAME_TO_SAVE_AS_IN_LOCAL>

Cleanup

To cleanup your S3 bucket and start over

python cleanup.py

Details

This project uses Makefile as a command registry, with the following commands:

  • make: list available commands
  • make develop: install and build this library and its dependencies using pip
  • make lint: perform lint using black
  • make scan: run static analysis on code using flake8
  • make test: run automated tests with pytest
  • make coverage: run automated tests with pytest and collect coverage information

coverage output can also be found in html format in htmlcover directory.

Example

First download the source code

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

aws-ket-0.1.4.tar.gz (12.5 kB view details)

Uploaded Source

File details

Details for the file aws-ket-0.1.4.tar.gz.

File metadata

  • Download URL: aws-ket-0.1.4.tar.gz
  • Upload date:
  • Size: 12.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.9.7

File hashes

Hashes for aws-ket-0.1.4.tar.gz
Algorithm Hash digest
SHA256 e46e05bc243b22c7255b9e8132a8ee7cf667145c72ca01b3c18c23bd283d18ea
MD5 a93f6b44faabf1ecc4af33c00d7444f5
BLAKE2b-256 fe8f0376dad3e1d1c3d316feeba79eff15b71632b4251286cb54c3a018a03c94

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