LightDSA (version 0.0.3) is a lightweight Python library providing Digital Signature Algorithm functionalities. Currently, it primarily supports the RSA algorithm for generating keys, signing data, and verifying signatures. Its development appears to be inactive since 2021, and new releases are infrequent.
pip install lightdsaVerified import paths — ran on the pinned version, not inferred.
This quickstart demonstrates how to generate RSA keys, sign a message, and verify the signature using the `LightDSA` class. It also shows how to load keys from PEM format.
Consider alternatives for actively maintained cryptographic libraries in production environments, such as `cryptography`.
Do not expect support for other DSA algorithms like ECDSA. If you require other signature types, use a more comprehensive library like `cryptography`.
Ensure `pycryptodome` is correctly installed: `pip install pycryptodome`. If you encounter build errors, consult `pycryptodome`'s documentation for platform-specific dependencies.
Install the `pycryptodome` package: `pip install pycryptodome`.
Convert your string data to bytes before passing it to `sign()` or `verify()`. For example, `my_string.encode('utf-8')`.