Weak hash

From zakirkun/ice-tea · View interactive version

Weak hash is an AI agent skill from the GitHub repository zakirkun/ice-tea. Detects usage of weak or deprecated cryptographic algorithms (MD5, SHA1, DES) and recommends modern replacements. Use when auditing code for insecure hashing, weak encryption, or crypto vulnerabilities.

How to use this skill

Skill file

Weak Cryptography Detection

Identifies imports and function calls for deprecated crypto algorithms and suggests modern replacements. See patterns.yaml for detection rules.

Detection Workflow

  1. Scan imports — flag crypto/md5, crypto/sha1, crypto/des, hashlib.md5, hashlib.sha1
  2. Scan calls — flag md5.New(), md5.Sum(), sha1.New(), sha1.Sum(), DES.new()
  3. Classify — hashing (MD5/SHA1) vs encryption (DES/RC4) vs password storage
  4. Recommend — SHA-256+ for hashing, AES-256 for encryption, bcrypt/scrypt/argon2 for passwords

Vulnerable

import "crypto/md5"
hash := md5.Sum(data)

Safe

import "crypto/sha256"
hash := sha256.Sum256(data)
Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.