Skip to main content

The python-wrapper for ssdeep

https://img.shields.io/github/license/drobotun/virustotalapi3?style=flat https://readthedocs.org/projects/pyssdeep/badge/?version=latest https://api.travis-ci.org/drobotun/pyssdeep.svg?branch=master&status=unknown https://codecov.io/gh/drobotun/pyssdeep/branch/master/graph/badge.svg?token=VHQQRO279Z

This package is a Python wrapper for ssdeep by Jesse Kornblum, which is a library for computing Context Triggered Piecewise Hashes (CTPH).

Installation

$ pip install pyssdeep

Usage

Get a fuzzy hash value for a string:

import pyssdeep

try:
    result = pyssdeep.get_hash_buffer(
        'The string for which you want to calculate a fuzzy hash'
    )
escept pyssdeep.FuzzyHashError as err:
    print(err)
except TypeError as err:
    print(err)
print('The fuzzy hash value is {}'.format(result))

Get a fuzzy hash value for a file:

import pyssdeep

try:
    result = pyssdeep.get_hash_file('e:/file.txt')
escept pyssdeep.FuzzyHashError as err:
    print(err)
except IOError as err:
    print(err)
print('The fuzzy hash value is {}'.format(result))

Get a fuzzy hash value for a file (using the pep 452 API):

import pyssdeep

buffer_size = 1024
fuzzy_hash_obj = pyssdeep.new()
with open('e:/file.txt', 'rb') as file:
    buffer = file.read(buffer_size)
    while len(buffer) > 0:
        fuzzy_hash_obj.update(buffer)
        buffer = file.read(buffer_size)
result = fuzzy_hash_obj.digest()

License

MIT Copyright (c) 2020 Evgeny Drobotun

Release hystory

1.0.0 (20.10.2020)

  • First release of ‘pyssdeep’

Metadata

Release files for pyssdeep 1.0.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pyssdeep 1.0.0
File Size Uploaded Provenance Actions
pyssdeep-1.0.0.tar.gz 181.9 kB Without provenance Details for pyssdeep-1.0.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for pyssdeep 1.0.0
File Interpreter ABI Platform Actions
pyssdeep-1.0.0-py3-none-any.whl Python 3 none any Details for pyssdeep-1.0.0-py3-none-any.whl

Total release size: 369.0 kB

Release files / pyssdeep-1.0.0.tar.gz

Download URL pyssdeep-1.0.0.tar.gz
Size 181.9 kB
Tags Source
SHA-256 checksum
How to use checksums
6e6d21538aafc2bae47588a093009fd9572495a4b3001892fa4770692123ad1c
BLAKE2b-256 checksum
How to use checksums
129e2d9a39fa9071dd764c00bbd31acc51d5fc5b9d4b0eec3596c791a801ade8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via Python-urllib/3.8

Release files / pyssdeep-1.0.0-py3-none-any.whl

Download URL pyssdeep-1.0.0-py3-none-any.whl
Size 187.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
9b97f844ef84de66780cecd0a1ff189202c3ce84f6bd3cad7a275fc640c4efb2
BLAKE2b-256 checksum
How to use checksums
1ba6af1c739fa604382b28168f820fd97ca9929f17bbac0feef45b0e8e7b3ccd
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via Python-urllib/3.8

Security for pyssdeep 1.0.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

1.0.0 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page