Skip to content

meltedinhex/analyst-ai-pack / skills/hashing-and-fingerprinting-files

hashing-and-fingerprinting-files

Verified

Computes cryptographic and fuzzy fingerprints for malware samples: MD5/SHA-1/SHA-256 for exact identity, plus import hashing (imphash), section hashing, and fuzzy hashes (ssdeep, TLSH) to cluster related variants. Activates for requests to hash a sample, compute imphash, or fingerprint files for similarity clustering.

FileKindSize
LICENSEother340 B
SKILL.mdskill md3.0 KB
references/api-reference.mdmarkdown1.3 KB
scripts/analyst.pyscript2.3 KB

references/api-reference.md

View on GitHub
# API Reference: Hashing and Fingerprinting Files

## Overview

`scripts/analyst.py` computes MD5/SHA-1/SHA-256 with stdlib `hashlib`, adds PE imphash and
per-section SHA-256 when `pefile` is present, and includes ssdeep/TLSH fuzzy hashes when their
libraries are installed. It reads inert bytes and never executes the sample.

## Dependencies

| Package | Version | Purpose |
|---------|---------|---------|
| (stdlib) | — | hashlib cryptographic hashes |
| pefile | >= 2023.2.7 | imphash and section hashing (optional) |
| ssdeep | >= 3.4 | Fuzzy/context-triggered piecewise hashing (optional) |
| python-tlsh | >= 4.5 | Locality-sensitive similarity hashing (optional) |

## Core functions

### `crypto_hashes(data)`
Returns MD5, SHA-1, SHA-256, and size.

### `pe_hashes(path)`
Returns imphash and per-section SHA-256 for PE files.

### `fuzzy_hashes(data)`
Returns ssdeep/TLSH digests when available.

## Usage

```bash
python scripts/analyst.py hash sample.bin
```

## Sources

- ssdeep fuzzy hashing — https://ssdeep-project.github.io/ssdeep/
- TLSH locality-sensitive hashing — https://github.com/trendmicro/tlsh
- imphash concept (import-table hash for toolchain clustering) — Mandiant/FireEye research
- SHA-256 as canonical sample identity, general malware-handling practice
slack-gif-creatoranthropics/skillsKnowledge and utilities for creating animated GIFs optimized for Slack. Provides constraints, validation tools, and animation concepts. Use when users request animated GIFs for Slack like "make me a GIF of X doing Y for Slack."Stars: 198kUpdated Claude CodeCodexVerifiedInstall
ponytailDietrichGebert/ponytailLazy senior dev mode for any coding task: the smallest change that fully solves it, and a reply a busy human understands in one read.Stars: 194kUpdated Claude CodeCodexVerifiedInstall
ponytail-debtDietrichGebert/ponytailHarvest every shortcut: comment into one debt ledger, so deferrals get tracked instead of forgotten. One-shot report.Stars: 194kUpdated Claude CodeCodexVerifiedInstall
ponytail-debtDietrichGebert/ponytailList every `shortcut:` comment (and older `ponytail:` ones) as a debt ledger. One-shot report, changes nothing. Use for "ponytail debt", "what did ponytail defer", "list the shortcuts", /ponytail-debt.Stars: 194kUpdated Claude CodeCodexVerifiedInstall