
Security News
Ruby's Bundler 4.0.18 Extends Cooldown to bundle lock and bundle cache
The supply chain control that delays freshly published gems now covers lockfile generation and gem vendoring in Ruby projects.
fast-hashes
Advanced tools
Lightweight, zero-dependency* hashing utilities for Python — wrapping
hashlibwith a clean API and BLAKE2b support.
*Only colorama for pretty terminal output on non-Linux platforms.
pip install fast-hashes
Note: Native optimized bindings are available on Linux only (Ubuntu 20.04+, Debian 11+, Fedora 38+). On other platforms the library falls back to pure-Python hashlib wrappers.
from fast_hashes import sha256, md5, blake2
# String input
print(sha256("hello world"))
# → b94d27b9934d3e08a52e52d7da7dabfac484efe37a5380ee9088f7ace2efcde9
# Bytes input
print(md5(b"binary data"))
# → 4c3c7c067634daec9716a80ea886d734
# BLAKE2b with custom digest size
print(blake2("fast!", digest_size=16))
# → 32-char hex string
| Function | Description | Returns |
|---|---|---|
md5(data) | MD5 hex digest | str |
sha1(data) | SHA-1 hex digest | str |
sha256(data) | SHA-256 hex digest | str |
sha512(data) | SHA-512 hex digest | str |
blake2(data, digest_size=32) | BLAKE2b hex digest | str |
All functions accept str or bytes. Strings are automatically UTF-8 encoded.
| Platform | Status |
|---|---|
| Ubuntu 20.04+ | ✅ Full support (native bindings) |
| Debian 11+ | ✅ Full support (native bindings) |
| Fedora 38+ | ✅ Full support (native bindings) |
| Arch Linux | ✅ Full support (native bindings) |
| macOS | ⚠️ Fallback (pure Python) |
| Windows | ⚠️ Fallback (pure Python) |
Compared to raw hashlib calls, fast-hashes adds negligible overhead (~2μs per call) while providing:
MIT
FAQs
Lightweight, fast hashing utilities wrapping hashlib with BLAKE2 support
The pypi package fast-hashes receives a total of 0 weekly downloads. As such, fast-hashes popularity was classified as not popular.
We found that fast-hashes demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
The supply chain control that delays freshly published gems now covers lockfile generation and gem vendoring in Ruby projects.

Security News
During a UK cyber test, a Mythos 5 agent used sockpuppets, social engineering, and prompt injection to try to get a maintainer to merge malware.

Company News
Socket is now in the AWS Security Hub Extended plan. Adopt it through AWS, apply committed spend, and block malicious open source packages.