Skip to content

Check if file hashes are dangerous using the Team CYMRU Malware Hash Registry.

License

Notifications You must be signed in to change notification settings

Richienb/cymru-mhr

Repository files navigation

cymru-mhr Travis CI Build Status

Check if file hashes are dangerous using the Team CYMRU Malware Hash Registry.

NPM Badge

Install

npm install cymru-mhr

Usage

const mhr = require("cymru-mhr")

const { lastSeen, detectionRate } = await mhr("7697561ccbbdd1661c25c86762117613")

console.log(`Last seen on ${new Date(lastSeen * 1000).toString()}`)
console.log(`Detected by ${detectionRate} antivirus engines`)

API

mhr(hash)

Check a file hash. Returns a promise that resolves with { lastSeen: number, detectionRate: number }.

mhr.multiple(hashes)

Check multiple file hashes. Returns a promise that resolves with an array of { lastSeen: number, detectionRate: number }.

hash

Type: string

The MD5 or SHA1 hash to check.

hashes

Type: string[]

An array of MD5 or SHA1 hashes to check.