Skip to main content

A pure-python implementation of the Damm Algorithm in Base 32.

Project description


CircleCI Maintainability Test Coverage

Python implementation of the Damm Algorithm in Base 32

By default, it uses an alphabet as specified in RFC 4648 which contains 32 alphanumeric characters, with similar looking characters removed. The padding symbol is not included.


The package is available on PyPI and can be installed using pip.

pip install damm32

Alternatively, you can clone the repository and use the module.


The module contains a single class called Damm32, this class implements the methods for the checksum.

from damm32 import Damm32

d32 = Damm32()

digit = d32.calculate("HELLO")

d32.verify("HELLO" + digit)

You can also pass an list of length 32 to the constructor for the class to specify your alphabet.

from damm32 import Damm32

d32 = Damm32(['A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z', '2', '3', '4', '5', '6', '7'])

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for damm32, version 1.1.0
Filename, size File type Python version Upload date Hashes
Filename, size damm32-1.1.0-py3-none-any.whl (3.9 kB) File type Wheel Python version py3 Upload date Hashes View hashes
Filename, size damm32-1.1.0.tar.gz (3.6 kB) File type Source Python version None Upload date Hashes View hashes

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN SignalFx SignalFx Supporter DigiCert DigiCert EV certificate StatusPage StatusPage Status page