Skip to main content

Python bindings for MRSHv2: a fast, modular similarity digest tool for malware analysis, forensics and much more

Project description

mrshw

Thin, ctypes-based Python bindings for the mrsh CLI tool. Implements the Bloom-filter–based similarity hashing algorithm originally proposed by Frank Breitinger and Harald Baier in their paper Similarity Preserving Hashing: Eligible Properties and a new Algorithm MRSH-v2 (da/sec Biometrics and Internet Security Research Group, Hochschule Darmstadt). Use Bloom-filter–based fingerprinting directly from Python with minimal overhead.


Installation

Install from PyPI:

pip install mrshw

Or directly from GitHub (tagged release v0.1.1):

pip install git+https://github.com/w4term3loon/mrsh.git@v0.1.1

Quickstart

import mrsh

# Generate hash
hash_value = mrsh.hash("file.exe")

# Create and compare fingerprints
fp1 = mrsh.Fingerprint("file1.exe")
fp2 = mrsh.Fingerprint("file2.exe")
similarity = fp1.compare(fp2)

# Batch operations
fpl = mrsh.FingerprintList()
fpl.add("file1.exe")
fpl.add("file2.exe")
results = fpl.compare_all(threshold=50)

License

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mrshw-0.1.1.tar.gz (9.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

mrshw-0.1.1-py3-none-any.whl (9.0 kB view details)

Uploaded Python 3

File details

Details for the file mrshw-0.1.1.tar.gz.

File metadata

  • Download URL: mrshw-0.1.1.tar.gz
  • Upload date:
  • Size: 9.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.3

File hashes

Hashes for mrshw-0.1.1.tar.gz
Algorithm Hash digest
SHA256 d1ae70f8374c5dd6b559decc6eef0ec520b4da2bcacf4d3d5b6327624f5e3cbc
MD5 3a54103b333543a14d761d34bd6475fe
BLAKE2b-256 e4112ffad5ca971c0f5ce7c98d40c1d46125204ccf6cec29262c4762510a3280

See more details on using hashes here.

File details

Details for the file mrshw-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: mrshw-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 9.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.3

File hashes

Hashes for mrshw-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 fca65c1598bd6c472035d0ae76c6a54d36ba625dd4bd447f6fe691462dc73b1d
MD5 f34bbea76c0d6859560feb298784925a
BLAKE2b-256 fbd61eda636a8c4962211f218715026222f636fd598bc35ff06a395f92787c46

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page