Skip to main content

mbed TLS (PolarSSL) wrapper

Project description

python-mbedtls is a thin wrapper to ARM’s mbed TLS library.

According to the official mbed TLS website

mbed TLS (formerly known as PolarSSL) makes it trivially easy for developers to include cryptographic and SSL/TLS capabilities in their (embedded) products, facilitating this functionality with a minimal coding footprint.

License

python-mbedtls is licensed under the Apache 2.0 license in order to be fully compatible with mbed TLS. The Apache 2.0 license enables the use of python-mbedtls in both open source and closed source projects.

Installation

The wrapper is currently developed and tested on Debian Jessie and targets Python 3.4. It probably works with earlier Python releases although this was not tested.

mbed TLS

python-mbedtls requires the mbed TLS library that can be installed with:

git clone https://github.com/ARMmbed/mbedtls.git mbedtls.git
cd mbedtls.git
SHARED=1 make no_test
sudo make install

python-mbedtls

Building python-mbedtls requires Cython:

python3 -m pip install cython

then,

git clone https://github.com/Synss/python-mbedtls.git python-mbedtls.git
cd python-mbedtls.git
python3 setup.py build_ext

The unit tests further require nose and pyCrypto:

python3 -m pip install nose pycrypto
nosetests -v tests

Hashing module (md.h)

The hashing module is wrapped, which provides message, file, and HMAC with the following algorithms: MD5, SHA-1, SHA-2, and RIPEMD-160.

Symmetric cipher module (cipher.h)

The symmetric cipher module is wrapped, which provides:

  • Aes encryption/decryption (128, 192, and 256 bits) in ECB, CBC, CFB128, CTR, GCM, or CCM mode;

  • Arc4 encryption/decryption;

  • Blowfish encryption/decryption in ECB, CBC, CFB64, or CTR mode;

  • Camellia encryption/decryption (128, 192, and 256 bits) in ECB, CBC, CFB128, CTR, GCM, or CCM mode;

  • DES encryption/decryption in ECB, or CBC mode;

Notes:

Tagging and padding are not wrapped.

Contribution

python-mbedtls is in an early stage of development and contributions in any form is welcome. Note, however, that bugs against mbed TLS should be reported upstream directly.

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

python-mbedtls-0.3.tar.gz (8.5 kB view details)

Uploaded Source

File details

Details for the file python-mbedtls-0.3.tar.gz.

File metadata

File hashes

Hashes for python-mbedtls-0.3.tar.gz
Algorithm Hash digest
SHA256 d4daa7bb273c889a5cc95fbe5b9e572ba6ed2c68b1904a4cc34c6a889b25ae56
MD5 9cae9b1efb35d437fef55104ae292a2a
BLAKE2b-256 d4ff06c037ac452be5106ecc5aba583eec7de19a8ce3e7dd5aa5a06f2c92b975

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 Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page