跳至正文
OpenAgentSkill
浏览已开放 · 目录记录日期 2026-11-21 · 自动更新和账户服务暂时关闭。
金融

Cryptographic Analysis & Assessment

SSL/TLS auditing, cipher suite analysis, hash algorithm identification, encryption implementation review, and cryptographic weakness detection in code

Masriyan · 已有 AI 审核记录

安装与使用

运行命令前先阅读来源与依赖说明。复制命令不会自动安装或执行。

npx skills add Masriyan/Claude-Code-CyberSecurity-Skill --skill Cryptographic Analysis & Assessment

技能说明


name: Cryptographic Analysis & Assessment description: SSL/TLS auditing, cipher suite analysis, hash algorithm identification, encryption implementation review, and cryptographic weakness detection in code version: 3.0.0 author: Masriyan tags: [cybersecurity, cryptography, ssl, tls, encryption, hashing, cipher, pki, post-quantum]

Cryptographic Analysis & Assessment

Purpose

Enable Claude to assist with cryptographic security assessments including SSL/TLS configuration auditing, cipher suite analysis and recommendation, hash algorithm identification, encryption implementation code review, key management evaluation, and detection of cryptographic vulnerabilities. Claude directly analyzes provided configurations and code.


Activation Triggers

This skill activates when the user asks about:

  • Auditing SSL/TLS configuration of a server or service
  • Evaluating cipher suites for security strength
  • Identifying hash algorithms from hash values or code
  • Reviewing code for cryptographic implementation flaws
  • Assessing key lengths, key management, or rotation policies
  • Detecting hardcoded keys, weak IVs, or ECB mode usage
  • Generating TLS configuration recommendations (Mozilla profile)
  • Certificate analysis (expiration, chain, transparency)
  • Post-quantum cryptography guidance
  • Password hashing implementation review (bcrypt, Argon2, PBKDF2)

Prerequisites

pip install cryptography requests pyOpenSSL

Recommended tools:

  • sslyze — Python TLS scanner
  • testssl.sh — Comprehensive TLS testing
  • openssl — Command-line TLS operations
  • Wireshark — TLS traffic analysis
  • certbot — Certificate management

Core Capabilities

1. SSL/TLS Configuration Auditing

When the user asks to audit TLS for a server or paste a TLS configuration:

Command-line audit approach:

# Quick TLS check using openssl
openssl s_client -connect example.com:443 -tls1_2 2>/dev/null | grep -E "Protocol|Cipher"
openssl s_client -connect example.com:443 -tls1 2>/dev/null | grep -E "handshake|error"

# Check certificate details
openssl s_client -connect example.com:443 </dev/null 2>/dev/null | openssl x509 -noout -dates -subject -issuer

# Comprehensive scan with sslyze
sslyze --regular example.com --json_out result.json

# Or testssl.sh (most comprehensive)
./testssl.sh --severity HIGH --quiet example.com

# Use the skill's script
python scripts/tls_auditor.py --host example.com --port 443 --output report.json
python scripts/tls_auditor.py --host mail.example.com --port 993 --grade

TLS Version Support Ratings:

ProtocolStatusAction
SSLv2Critically brokenBlock immediately
SSLv3Broken (POODLE)Block immediately
TLS 1.0Deprecated (PCI-DSS violation)Disable — BEAST, POODLE
TLS 1.1DeprecatedDisable
TLS 1.2Acceptable (with strong ciphers)Keep with restrictions
TLS 1.3Current standardEnable and prefer

TLS Vulnerability Checklist:

[ ] Heartbleed (CVE-2014-0160): openssl s_client + heartbleed test
[ ] POODLE: SSLv3 enabled?
[ ] BEAST: TLS 1.0 + CBC cipher?
[ ] ROBOT: RSA key exchange supported?
[ ] DROWN: SSLv2 on any port of same server?
[ ] Logjam/FREAK: DHE < 2048-bit or EXPORT ciphers?
[ ] CRIME/BREACH: TLS compression enabled?
[ ] Sweet32: 3DES (64-bit block cipher) supported?
[ ] Weak certificate: RSA < 2048-bit, SHA-1 signed?
[ ] Certificate validity: Not expired, chain complete, not self-signed for prod?
[ ] HSTS: Strict-Transport-Security header present?
[ ] CT: Certificate in public transparency logs?

2. Cipher Suite Strength Evaluation

When the user asks about cipher suite security:

TLS 1.3 Cipher Suites (All Secure — Use These):

Cipher SuiteKey ExchangeAuthEncryptionMACRating
TLS_AES_256_GCM_SHA384ECDHERSA/ECDSAAES-256-GCMSHA-384A+
TLS_CHACHA20_POLY1305_SHA256ECDHERSA/ECDSAChaCha20Poly1305A+
TLS_AES_128_GCM_SHA256ECDHERSA/ECDSAAES-128-GCMSHA-256A

TLS 1.2 Cipher Suite Ratings:

Cipher SuiteRatingNotes
ECDHE-ECDSA-AES256-GCM-SHA384A+Perfect — AEAD, PFS
ECDHE-RSA-AES256-GCM-SHA384A+Perfect — AEAD, PFS
ECDHE-RSA-AES128-GCM-SHA256AGood — AEAD, PFS
DHE-RSA-AES256-GCM-SHA384AGood — if DHE ≥ 2048-bit
AES256-GCM-SHA384BNo forward secrecy
ECDHE-RSA-AES256-SHA384BCBC mode (timing attacks)
RC4-SHAFRC4 broken — never use
DES-CBC3-SHAF3DES vulnerable (Sweet32)
NULL-SHAFNo encryption
EXPORT-RC4-MD5FFREAK vulnerable

Recommended nginx TLS Configuration (Mozilla Modern Profile):

ssl_protocols TLSv1.2 TLSv1.3;
ssl_prefer_server_ciphers off;  # TLS 1.3 ignores this; client order for TLS 1.2

# For TLS 1.2 compatibility
ssl_ciphers ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:DHE-RSA-AES128-GCM-SHA256:DHE-RSA-AES256-GCM-SHA384;

# DH parameters for DHE cipher suites
ssl_dhparam /etc/nginx/dhparam.pem;  # Generate: openssl dhparam -out dhparam.pem 4096

# Session management
ssl_session_timeout 1d;
ssl_session_cache shared:SSL:10m;
ssl_session_tickets off;  # Disabling improves forward secrecy

# HSTS
add_header Strict-Transport-Security "max-age=63072000; includeSubDomains; preload" always;

# OCSP Stapling
ssl_stapling on;
ssl_stapling_verify on;
resolver 1.1.1.1 8.8.8.8 valid=300s;

Generate DH parameters:

# 4096-bit DH parameters (do this once, takes a few minutes)
openssl dhparam -out /etc/nginx/dhparam.pem 4096

3. Hash Algorithm Identification & Assessment

When the user provides a hash value or asks to identify hash algorithms:

Hash Identification by Format: | Hash Format

阅读完整来源 ↗