Pure Python SHA-256 hashing implementation
Project description
███████ ██ ██ █████ ██████ ███████ ██████ ██████ ██ ██
██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██
███████ ███████ ███████ █████ ███████ ███████ ██████ ████
██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██
███████ ██ ██ ██ ██ ███████ ███████ ██████ ██ ██
-----------------------------------------------------------------
A pure Python implementation of the SHA-256 hashing algorithm.
Explanation
SHA-256 is a hash function that produces a 256-bit (32-byte) hash value. It is widely used in various security applications and protocols, to ensure data integrity and authenticity.
I've created a detailed explanation of the algorithm in the docs.
Installation
See the installation guide for full details.
Quickstart
pip install sha256py
Usage
As library
from sha256py import Sha256
my_hash = Sha256("Hello World!")
print(my_hash.hexdigest())
As command line tool
sha256py "hello world"
A full list of options can be found in the usage guide.
Testing
This project uses pytest for testing.
pip install pytest
pytest
Tests are located in the tests directory.
Contributing
I won't actively maintain this project. If you want to add features or optimize the code, feel free to do so.
A short explanation how to contribute can be found in the contributing guide.
License & Metadata
Lenard Felix - contact@lenardfelix.de
This project is licensed under MIT. See LICENSE for details.
Compatible with Python 3.7 and above.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file sha256py-0.1.1.tar.gz.
File metadata
- Download URL: sha256py-0.1.1.tar.gz
- Upload date:
- Size: 7.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
efcceb17ea2530fe51dad9c7b7588898655da74fe82ceeaad4e7de635d78f0b1
|
|
| MD5 |
72ea43d2d574828bc4dafcd1a48dce07
|
|
| BLAKE2b-256 |
b8359b57ebf6ff0a9565901c0a828d03be72d748738551f0287671ec91fa0bc8
|
File details
Details for the file sha256py-0.1.1-py3-none-any.whl.
File metadata
- Download URL: sha256py-0.1.1-py3-none-any.whl
- Upload date:
- Size: 7.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1ee1356bcca0cf08d8268b3634998622b6bacac5f64d5901f102347c8a1a020b
|
|
| MD5 |
7238e61fbaaf3448117dab44a829ccee
|
|
| BLAKE2b-256 |
04bf351c396a812c32c056900f77d132f54e51d808b5b37907156c37c83e56cd
|