Skip to main content

Package, encrypt and obfuscate Python scripts

Project description

DuctTape

DuctTape is a tool for packaging, encrypting, and obfuscating your python scripts. It is a fork of stickytape with added encryption and obfuscation features.

Features

  • Package your python scripts into a single file
  • Encrypt your python scripts using RSA
  • Obfuscate your python scripts

Installation

You can install DuctTape from source:

$ git clone https://github.com/bpradana/ducttape.git
$ cd ducttape
$ python setup.py install

Usage

Generate RSA key pair

This will generate private.pem and public.pem in your current directory

$ ducttape --keygen

Encrypt

$ ducttape entrypoint.py --public-key=your_public_key.pem > encrypted.py

Running encrypted script

make sure you have private.pem in your current directory

$ python encrypted.py

Example

You can find an example of original script here and the ducttaped one here, but you won't be able to run it because it's encrypted with my public key.

To run the example, you need to generate your own key pair and encrypt the script with your public key.

$ ducttape --keygen
$ ducttape example/hello/main.py --public-key=public.pem > example/ducttaped.py
$ python example/ducttaped.py

License

DuctTape is licensed under the BSD 2-Clause License

Credits

DuctTape is a fork of Michael Williamson's amazing project, stickytape

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

pyducttape-0.0.2.tar.gz (9.6 kB view hashes)

Uploaded Source

Built Distribution

pyducttape-0.0.2-py3-none-any.whl (10.3 kB view hashes)

Uploaded Python 3

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