ppdeep
Pure-Python library for computing fuzzy hashes (ssdeep)
What it is and what it does
ppdeep is a pure-Python implementation of fuzzy hashing (CTPH), a technique for determining whether two inputs are similar rather than identical. It provides three main functions: hash() to compute a fuzzy hash from a string, compare() to measure similarity between two hashes on a 0-100 scale, and hash_from_file() to hash file contents directly. The library has no external runtime dependencies and works across operating systems.
Fuzzy hashing is commonly used in digital forensics and malware detection to identify related files or data that may have been slightly modified. The implementation is based on SpamSum by Dr. Andrew Tridgell and follows the ssdeep algorithm, making it compatible with the fuzzy hash format produced by the popular ssdeep tool.
Use it for:
- Detect similar malware samples that have been slightly modified or repackaged.
- Identify related files in digital forensics investigations where exact matching is too strict.
- Compare document or data versions to find near-duplicates in large datasets.
- Build similarity-based deduplication systems for file storage or backup.
- Analyze suspicious files by comparing their fuzzy hashes against known malicious samples.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
ppdeep computes fuzzy hashes (CTPH/ssdeep) to measure similarity between inputs rather than testing for exact equality, useful in digital forensics and malware detection.
Yes. ppdeep is actively maintained, has no dependencies, installs easily, carries no known vulnerabilities, and uses a permissive license. It fills a specific and legitimate need in forensics and malware analysis. Install it if you need fuzzy hashing; skip it if you only need exact-match hashing or cryptographic digests.
Install
ppdeep on PyPI
pip
pip install ppdeepuv
uv add ppdeeppoetry
poetry add ppdeepInstalling ppdeep
Before you install
Low install friction with no runtime dependencies. Actively maintained as of 2026-02-21 with recent commits and a small but engaged user base.
License in practice
Licensed under Apache Software License (ASL 2.0), a permissive license allowing commercial and private use with minimal restrictions.
Quickstart
pip install ppdeep
import ppdeep
h1 = ppdeep.hash('The equivalence of mass and energy translates into the well-known E = mc²')
h2 = ppdeep.hash('The equivalence of mass and energy translates into the well-known E = MC2')
similarity = ppdeep.compare(h1, h2) # Returns 0-100 similarity score
Verify before relying
- Whether the package handles very large files efficiently or has memory constraints for hash_from_file().
- Performance characteristics compared to the original ssdeep tool or other fuzzy hashing implementations.
Package facts
| License | ASL 2.0 (permissive) |
| Python support | not specified |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | none |
| Maintenance | actively maintained — 174 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 75,317/month — #14,728 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: ppdeep-20260221-py3-none-any.whl
Tags
More Security packages
Provides Python bindings to the FreeDesktop.org…
permissive · top 1,000 on PyPI
msalMSAL for Python handles OAuth2 and OpenID…
permissive · top 1,000 on PyPI
joserfcjoserfc implements JOSE standards (JWS, JWE,…
permissive · top 1,000 on PyPI
AuthlibAuthlib provides a complete implementation of…
permissive · top 1,000 on PyPI
argon2-cffi-bindingsProvides low-level CFFI bindings to the…
permissive · top 1,000 on PyPI
adalADAL for Python authenticates applications with…
permissive · top 1,000 on PyPI
py-tlshGenerates locality-sensitive hashes for fuzzy…
permissive · top 15,000 on PyPI
ImageHashImageHash computes perceptual fingerprints of…
permissive · top 5,000 on PyPI
simhashComputes Simhash fingerprints for text and…
permissive · top 15,000 on PyPI
filehashCalculates and verifies file checksums and…
permissive · top 15,000 on PyPI
ngramExtends Python's set class to perform fuzzy…
copyleft · top 15,000 on PyPI
dirhashComputes a single hash value for an entire…
permissive · top 5,000 on PyPI
siphashProvides a Python implementation of SipHash, a…
permissive · top 15,000 on PyPI
pysimstringProvides fast approximate string matching and…
unclear · top 15,000 on PyPI
pyfarmhashProvides Python bindings to Google's FarmHash,…
permissive · top 15,000 on PyPI
spookyhashProvides fast 32-, 64-, and 128-bit hashing via…
permissive · top 15,000 on PyPI