Forensicshashingmd5sha1sha256sha512whirlpooljhhmacrecursionforensicsnetwork-security

Hashrat

Hashrat is a hashing utility supporting multiple hash algorithms including MD5, SHA1, SHA256, SHA512, Whirlpool, and JH variants, with HMAC support. It offers recursive directory hashing, device hashing, traditional output formats, and remote operations.

Description

Hashrat is a versatile hash-generation tool designed for security professionals, particularly useful in forensics investigations and network security assessments. It supports a wide range of hash functions (md5, sha1, sha256, sha512, whirlpool, jh-244, jh256, jh-384, jh-512) and their HMAC versions, providing flexibility for various verification and integrity checking needs.

The tool can output hashes in multiple formats including traditional (md5sum/shasum style), octal, decimal, hexadecimal, uppercase hexadecimal, or base64. Key features include directory recursion, hashing entire devices or directories, and operations on remote machines. It also includes a CGI mode for web-based hash lookup functionality.

Hashrat detects when run via symlinks like md5sum, shasum, etc., automatically applying appropriate default flags for compatibility with standard Unix hash tools.

How It Works

Hashrat computes cryptographic hashes using specified algorithms on files, directories, devices, or remote targets. It supports algorithm chaining (e.g., sha256,whirlpool), recursive traversal for directories, HMAC computation, and multiple output encodings. When invoked via symlinks (md5sum, sha1sum, etc.), it auto-configures traditional output with the corresponding hash type. The CGI mode enables HTTP-based hash lookup services.

Installation

bash
sudo apt install hashrat

Flags

--helpPrint this help
-helpPrint this help
-?Print this help
--versionPrint program version
-versionPrint program version
-list-hashesPrint a list of hashes that can be used with the '-type' option
-type <hash>specify a hash type to use. Supports chaining like -type sha256,whirl
-md5Use md5 hash algorithm

Examples

Basic usage: hash files or directories with specified options
hashrat [options] [path to hash]...
Verify hashes against an input file containing hash values
hashrat -c [options] [input file of hashes]...
Use chained hash types (sha256 then whirlpool) on target files
hashrat -type sha256,whirl
When run as md5sum symlink: computes MD5 hash in traditional format
md5sum file.txt
When run as shasum symlink: computes SHA256 hash in traditional format
shasum -a 256 file.txt
Recursively hash entire directory using SHA256 in traditional format
sha256sum directory/
Hash entire block device using SHA512
hashrat -type sha512 /dev/sda
Updated 2026-04-16kali.org ↗