๐Ÿ”’ Check file hash reputation with VirusTotal and Slack alerts

โšก 9 views ยท ๐Ÿ”’ SecOps & Security Automation

Description

๐Ÿงฉ Template Description

File Hash Reputation Checker is a security automation workflow that validates file hashes (MD5, SHA1, SHA256) and checks their reputation using the VirusTotal API. It is designed for SOC teams, security engineers, and automation pipelines that need fast and consistent malware verdicts from a single hash input.

The workflow supports two input methods:

Once a hash is submitted, the workflow normalizes and validates the input, queries VirusTotal for detection statistics, and determines whether the file is Malicious, Suspicious, Clean, or Unknown. Results are returned as a structured JSON response and also posted to Slack with severity-based formatting.

โš™๏ธ How It Works

  1. A file hash is submitted via HTTP POST or Slack using /hash-check FILE_HASH.

  2. The hash is normalized (lowercased and trimmed).

  3. The workflow validates the hash format (MD5, SHA1, or SHA256).

  4. VirusTotal is queried for hash reputation data.

  5. Detection statistics are analyzed to calculate a verdict:

    • Malicious
    • Suspicious
    • Clean
    • Unknown
  6. A Slack message is sent for all verdicts, with alert-style formatting for malicious results.

  7. A structured JSON response is returned to the requester.

๐Ÿ› ๏ธ Setup Steps

  1. VirusTotal API

    • Create or use an existing VirusTotal account.

    • Add your API key to n8n as VirusTotal API credentials.

  2. Slack Configuration

    • Create a Slack App.
    • Enable Slash Commands and create /hash-check.
    • Set the Request URL to the n8n webhook endpoint.
    • Connect your Slack account in n8n credentials.
  3. Activate the Workflow

    • Activate the workflow in n8n.

    • Test using:

      • HTTP POST: { "text": "file_hash" }

      • Slack: /hash-check FILE_HASH;

๐ŸŽ›๏ธ Customization Ideas

๐Ÿ”— Nodes Used

HTTP Request, Slack, Webhook

๐Ÿ“ฅ Import

Download workflow.json and import into n8n: Workflow menu โ†’ Import from File

๐Ÿ“– Importing guide ยท ๐Ÿ”‘ Credential setup