Token导航 LogoToken导航

Agent Skill · 研究检索

security-analysis-skills(证券分析技能)

用于辅助安全审计、权限检查、凭据风险、认证流程和常见漏洞排查。它适合让 Agent 梳理敏感配置、检查依赖风险、分析鉴权逻辑或生成安全复核清单。使用时不能把工具输出直接当最终结论,涉及密钥、令牌、用户数据或生产系统时,应先确认最小权限、脱敏方式和操作边界。

security-analysis-skills 是研究检索类 Agent Skill,可用宿主为 Codex、Claude、Cursor、Gemini CLI,通过GitHub 仓库获取,权限为接触敏感数据;许可证为 MIT,暂无第三方扫描结果,按安装量在研究检索类的 73,675 个 Skill 里排第 56,028。

总安装 465周安装 19GitHub Stars 公开资料未说明下载 150核验 2026-05-01

安装说明

本站只整理中文说明,不托管安装包,也不代用户安装。
GitHub
许可证
MIT

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:security-analysis-skills(证券分析技能)
来源仓库:https://github.com/kimasplund/claude_cognitive_reasoning
仓库路径:skills/security-analysis-skills
安装命令:
npx skills add kimasplund/claude_cognitive_reasoning --skill "security-analysis-skills"
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

AgentSkills.tonpx skills
npx skills add kimasplund/claude_cognitive_reasoning --skill "security-analysis-skills"

这个 Skill 是做什么的

研究检索类 Skill 主要解决「找资料、核对事实、把来源整理清楚」的问题,通常会让助手先检索再总结。

security-analysis-skills 用于发现并安装 AI 代理的技能。适用于 Codex、Claude、Cursor、Gemini CLI 等平台的安全增强扩展。通过 npx skills add 命令从 kimasplund/claude_cognitive_reasoning 安装。

需确保网络可达且具备仓库读取权限。建议查看原始文档了解技能分类与安全边界。

来源仓库内路径:skills/security-analysis-skills

上手步骤

4 步
  1. 1

    确认自己的宿主工具

    公开资料标注支持 Codex、Claude、Cursor、Gemini CLI;先确认自己用的是其中之一,再按对应工具的 Skills 目录放置。

  2. 2

    拿到安装命令

    可以直接复制的命令是 npx skills add kimasplund/claude_cognitive_reasoning --skill "security-analysis-…;命令里的占位符换成自己的路径或密钥再执行。

  3. 3

    安装后重启宿主

    命令执行完要完全退出宿主工具再打开,让新装的 Skill 被重新扫描到,否则列表里可能看不到。

  4. 4

    按最小权限试用

    它需要接触敏感数据,先在测试目录或测试账号里跑,确认没问题再放到正式项目。

常见问题

6 条

security-analysis-skills 怎么安装?

在终端执行 npx skills add kimasplund/claude_cognitive_reasoning --skill "security-analysis-skills"。装完完全退出宿主工具再打开,让它重新扫描本地 Skill。

security-analysis-skills 支持哪些 AI 工具?

公开资料标注支持 Codex、Claude、Cursor、Gemini CLI。其他工具只要能读取本地 Skill 目录,一般也能手动放进去,但要自己确认触发方式是否一致。

security-analysis-skills 需要什么权限?

权限级别是接触敏感数据。该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

security-analysis-skills 是免费的吗?

来源标注的许可证是 MIT。本站不代收任何费用,也不托管安装包;能否商用、要不要署名,以许可证原文为准。

security-analysis-skills 用的人多吗?

公开数据是累计安装 465 次,近一周安装 19 次,下载 150 次。这些数字来自第三方目录统计,只能当作热度参考,不代表质量或安全性。

security-analysis-skills 安全吗?

没有查到第三方扫描结果,安全性无法从公开资料判断,安装前请自行审查源码、依赖和命令行为。

值得选的地方和要先想清楚的地方

值得选的地方

  • 同时适配 4 种工具,换客户端不用重新找替代品。
  • 许可证明确为 MIT,商用和分发边界好判断。

先想清楚的地方

  • 需要接触敏感数据,装到常用环境前要先评估影响面。
  • 没有第三方扫描结果,安全性只能靠自己读源码判断。
  • 第三方目录整理,版本更新和行为细节以来源仓库为准。

适不适合你

更适合

  • 已经在用 Codex,想直接扩展它能力的人。
  • 需要处理研究检索类任务、又不想每次都手写提示词的人。

不太适合

  • 环境里有大量密钥、凭证,不方便给第三方 Skill 读取的人。
  • 要求有安全扫描结论才肯安装的团队。
  • 需要厂商级技术支持和 SLA 的生产系统。

研究检索类 Skill 对比

6 个同类
Skill总安装GitHub 星权限许可证扫描
find-skills

寻找技能 · Codex、Claude

31,199,81316,486操作浏览器MIT有提醒
self-improving-agent

自我改进 Agent · OpenClaw

16,464,0023,396接触敏感数据MIT-0通过
soultrace

灵魂追踪 · Codex、Claude

7,588,94412需要联网未明确有提醒
self-improving

自我完善 · OpenClaw

6,829,2841,046需要联网MIT-0通过
microsoft-foundry

微软代工厂 · Codex、Claude

6,614,144764调用外部服务未明确有提醒
security-analysis-skills

证券分析技能 · 本页

465—接触敏感数据MIT未收录

按安装量取同分类前几名;数字来自第三方目录统计,只作热度参考,不代表质量结论。

SKILL.md 原文

name
security-analysis-skills
description
Comprehensive security analysis framework teaching STRIDE threat modeling, OWASP Top 10 vulnerabilities, CVSS risk scoring, and secure coding patterns. Use when conducting security assessments, code reviews, threat modeling, or implementing security controls. Applicable to all development work requiring security consideration.
license
MIT

Security Analysis Skills

Purpose: Universal security knowledge framework for threat modeling, vulnerability assessment, risk scoring, and secure coding. Designed to be applied by ALL development agents (security-agent, developer-agent, devops-agent, rust-expert, python-ml-expert) to ensure security-first development practices.

Created: 2025-11-08


When to Use Security Analysis Skills

✅ Use this skill when:

  • Conducting threat modeling for new features/systems
  • Performing security code review
  • Assessing vulnerabilities and scoring risk
  • Implementing authentication/authorization
  • Handling sensitive data (PII, credentials, payment info)
  • Deploying to production (security checklist)
  • Investigating security incidents
  • Designing secure architectures

❌ NOT required for:

  • Pure documentation tasks with no code
  • Read-only data analysis with public data
  • Internal tools with no network exposure (but still recommended)

Target Audience: Security specialists AND general developers integrating security into daily work


Core Security Frameworks

1. STRIDE Threat Modeling

Purpose: Systematic identification of threats by category

STRIDE Categories:

  1. S - Spoofing Identity

- Definition: Attacker pretends to be someone else - Examples: Stolen credentials, session hijacking, JWT forgery - Mitigations: MFA, certificate pinning, signed tokens

  1. T - Tampering with Data

- Definition: Unauthorized modification of data - Examples: Man-in-the-middle, SQL injection, XSS - Mitigations: HTTPS/TLS, input validation, integrity checks (HMAC)

  1. R - Repudiation

- Definition: User denies performing an action - Examples: Missing audit logs, unsigned transactions - Mitigations: Audit logging, digital signatures, timestamps

  1. I - Information Disclosure

- Definition: Exposure of confidential information - Examples: Directory traversal, verbose errors, unencrypted data - Mitigations: Encryption at rest/transit, least privilege, sanitized errors

  1. D - Denial of Service

- Definition: Service becomes unavailable - Examples: Resource exhaustion, infinite loops, DDoS attacks - Mitigations: Rate limiting, resource quotas, circuit breakers

  1. E - Elevation of Privilege

- Definition: Unauthorized permission escalation - Examples: Privilege escalation bugs, insecure defaults - Mitigations: Principle of least privilege, role-based access control

How to Apply STRIDE:

  1. For each component/feature, ask: "What STRIDE threats apply?"
  2. Fill out threat modeling worksheet (see reference section)
  3. Prioritize threats by impact × likelihood
  4. Document mitigations for each identified threat

2. OWASP Top 10 (2021 Edition)

Purpose: Most critical web application security risks

A01: Broken Access Control

Description: Users can act outside their intended permissions

Examples:

  • Direct object references: /user/1234/profile → change to /user/5678/profile
  • Missing function-level access control: Regular user accesses /admin/delete
  • IDOR (Insecure Direct Object Reference): Manipulating IDs in URLs/APIs

Secure Patterns:

# ❌ VULNERABLE: No ownership check
@app.route('/document/<doc_id>')
def get_document(doc_id):
    doc = Document.query.get(doc_id)
    return render_template('doc.html', doc=doc)

# ✅ SECURE: Verify ownership
@app.route('/document/<doc_id>')
@login_required
def get_document(doc_id):
    doc = Document.query.get(doc_id)
    if not doc or doc.owner_id != current_user.id:
        abort(403)  # Forbidden
    return render_template('doc.html', doc=doc)

Checklist:

  • [ ] All endpoints verify user permissions
  • [ ] Object ownership validated before access
  • [ ] Default deny (whitelist not blacklist)
  • [ ] Disable directory listing
  • [ ] Invalidate sessions on logout

A02: Cryptographic Failures

Description: Sensitive data exposed due to weak/missing encryption

Examples:

  • Storing passwords in plaintext
  • Using weak algorithms (MD5, SHA1 for passwords)
  • Transmitting sensitive data over HTTP
  • Hardcoded encryption keys

Secure Patterns:

# ❌ VULNERABLE: Weak hashing
import hashlib
password_hash = hashlib.md5(password.encode()).hexdigest()

# ✅ SECURE: Proper password hashing
import bcrypt
password_hash = bcrypt.hashpw(password.encode(), bcrypt.gensalt())

# ❌ VULNERABLE: Hardcoded key
AES_KEY = "mysecretkey12345"

# ✅ SECURE: Environment variable
import os
AES_KEY = os.environ['AES_ENCRYPTION_KEY']

Checklist:

  • [ ] Use TLS 1.2+ for all data in transit
  • [ ] Hash passwords with bcrypt/Argon2 (not MD5/SHA1)
  • [ ] Never hardcode secrets (use env vars/vaults)
  • [ ] Encrypt sensitive data at rest
  • [ ] Use strong key generation (crypto.randomBytes, secrets module)

A03: Injection

Description: Untrusted data sent to interpreter as command/query

Types: SQL Injection, NoSQL Injection, Command Injection, LDAP Injection, XPath Injection

SQL Injection Example:

# ❌ VULNERABLE: String concatenation
username = request.form['username']
query = f"SELECT * FROM users WHERE username = '{username}'"
# Attacker inputs: ' OR '1'='1' --
# Result: SELECT * FROM users WHERE username = '' OR '1'='1' --'

# ✅ SECURE: Parameterized query
username = request.form['username']
query = "SELECT * FROM users WHERE username = ?"
cursor.execute(query, (username,))

Command Injection Example:

# ❌ VULNERABLE: Shell injection
filename = request.form['filename']
os.system(f"cat {filename}")  # Attacker: "; rm -rf /"

# ✅ SECURE: Avoid shell, use safe APIs
import subprocess
subprocess.run(['cat', filename], check=True, capture_output=True)

Checklist:

  • [ ] Use parameterized queries (prepared statements)
  • [ ] Avoid dynamic query construction with string concat
  • [ ] Validate input against whitelist (not blacklist)
  • [ ] Escape special characters for context
  • [ ] Use ORM frameworks (with parameterization)

A04: Insecure Design

Description: Missing or ineffective security controls in design phase

Examples:

  • No rate limiting on login (brute force)
  • Password reset without identity verification
  • Predictable session IDs
  • No transaction verification (CSRF)

Secure Design Patterns:

  • Defense in depth (multiple security layers)
  • Principle of least privilege
  • Fail securely (default deny)
  • Separation of duties
  • Security by default (opt-in for risky features)

Checklist:

  • [ ] Threat model created during design
  • [ ] Rate limiting on authentication/sensitive endpoints
  • [ ] CSRF tokens for state-changing operations
  • [ ] Cryptographically secure random IDs (not sequential)
  • [ ] Security requirements defined before coding

A05: Security Misconfiguration

Description: Insecure default configurations, incomplete setups, exposed admin interfaces

Examples:

  • Default admin credentials (admin/admin)
  • Verbose error messages revealing stack traces
  • Unnecessary features enabled (debug mode in production)
  • Missing security headers
  • Outdated software versions

Secure Configuration:

# ❌ VULNERABLE: Debug mode in production
app = Flask(__name__)
app.config['DEBUG'] = True  # Exposes code, allows RCE

# ✅ SECURE: Environment-based config
import os
app.config['DEBUG'] = os.environ.get('FLASK_ENV') == 'development'

# ✅ SECURE: Security headers
@app.after_request
def set_security_headers(response):
    response.headers['X-Content-Type-Options'] = 'nosniff'
    response.headers['X-Frame-Options'] = 'DENY'
    response.headers['X-XSS-Protection'] = '1; mode=block'
    response.headers['Strict-Transport-Security'] = 'max-age=31536000; includeSubDomains'
    return response

Checklist:

  • [ ] Change all default credentials
  • [ ] Disable debug mode in production
  • [ ] Remove unnecessary features/services
  • [ ] Configure security headers (CSP, HSTS, X-Frame-Options)
  • [ ] Regular security updates applied

A06: Vulnerable and Outdated Components

Description: Using libraries/frameworks with known vulnerabilities

Examples:

  • Unmaintained dependencies (no security patches)
  • Using deprecated crypto libraries
  • Outdated frameworks (old Rails, Django, Spring)

Secure Practices:

# Check for vulnerabilities
npm audit          # Node.js
pip-audit          # Python
bundle audit       # Ruby
cargo audit        # Rust

# Update dependencies
npm update
pip install --upgrade -r requirements.txt
cargo update

Checklist:

  • [ ] Dependency scanning in CI/CD
  • [ ] Regular updates (monthly for deps, immediate for critical CVEs)
  • [ ] Remove unused dependencies
  • [ ] Pin versions (avoid wildcards like *)
  • [ ] Monitor CVE databases (NVD, GitHub Security Advisories)

A07: Identification and Authentication Failures

Description: Weak authentication allows attackers to compromise accounts

Examples:

  • Weak password policy (no complexity requirements)
  • Session fixation
  • Missing MFA
  • Predictable session tokens
  • No account lockout on brute force

Secure Authentication:

# Password Policy
MIN_LENGTH = 12
REQUIRE_UPPERCASE = True
REQUIRE_DIGIT = True
REQUIRE_SPECIAL = True

# Session Management
from secrets import token_urlsafe
session_id = token_urlsafe(32)  # Cryptographically secure

# Rate Limiting
from flask_limiter import Limiter
limiter = Limiter(app, default_limits=["5 per minute"])

@app.route('/login', methods=['POST'])
@limiter.limit("5 per minute")
def login():
    # Login logic with rate limiting
    pass

Checklist:

  • [ ] Strong password policy enforced
  • [ ] MFA available (TOTP, WebAuthn)
  • [ ] Account lockout after N failed attempts
  • [ ] Session timeout configured
  • [ ] Secure session cookie flags (HttpOnly, Secure, SameSite)

A08: Software and Data Integrity Failures

Description: Code/infrastructure relies on untrusted sources without integrity verification

Examples:

  • Downloading dependencies without checksum verification
  • Auto-update without signature validation
  • Insecure CI/CD pipeline
  • Deserialization of untrusted data

Secure Practices:

# ❌ VULNERABLE: Deserialize untrusted data
import pickle
data = pickle.loads(request.data)  # RCE risk!

# ✅ SECURE: Use safe serialization
import json
data = json.loads(request.data)  # Only deserializes JSON primitives

# Verify package integrity
pip install --require-hashes -r requirements.txt

Checklist:

  • [ ] Use signed commits (GPG)
  • [ ] Verify package checksums/signatures
  • [ ] Secure CI/CD pipeline (no secrets in logs)
  • [ ] Avoid insecure deserialization (pickle, YAML.unsafe_load)
  • [ ] Implement software bill of materials (SBOM)

A09: Security Logging and Monitoring Failures

Description: Insufficient logging prevents detection of breaches

Examples:

  • No logging of authentication events
  • Logs not reviewed/alerted
  • Sensitive data in logs (passwords, tokens)
  • No integrity protection (logs can be tampered)

Secure Logging:

import logging
import hashlib

# ✅ SECURE: Log security events
logger = logging.getLogger('security')

@app.route('/login', methods=['POST'])
def login():
    username = request.form['username']
    password = request.form['password']

    if authenticate(username, password):
        logger.info(f"Successful login: user={username}, ip={request.remote_addr}")
        return "Success"
    else:
        logger.warning(f"Failed login: user={username}, ip={request.remote_addr}")
        return "Invalid credentials", 401

# ❌ VULNERABLE: Log sensitive data
logger.info(f"User {username} logged in with password {password}")  # DON'T!

# ✅ SECURE: Redact sensitive data
logger.info(f"User {username} logged in")

Checklist:

  • [ ] Log all authentication events (success/failure)
  • [ ] Log authorization failures
  • [ ] Log input validation failures
  • [ ] Never log passwords, tokens, PII
  • [ ] Centralized logging with alerting
  • [ ] Tamper-evident logs (write-once storage)

A10: Server-Side Request Forgery (SSRF)

Description: Web app fetches remote resource without validating user-supplied URL

Examples:

  • Fetching arbitrary URLs from user input
  • Accessing internal services (localhost, 169.254.169.254)
  • Port scanning via web app

SSRF Example:

# ❌ VULNERABLE: Fetch arbitrary URL
import requests
url = request.args.get('url')
response = requests.get(url)  # Attacker: http://localhost:6379/

# ✅ SECURE: Whitelist domains
ALLOWED_DOMAINS = ['api.example.com', 'cdn.example.com']
from urllib.parse import urlparse

url = request.args.get('url')
parsed = urlparse(url)
if parsed.hostname not in ALLOWED_DOMAINS:
    abort(400, "Invalid domain")
response = requests.get(url)

Checklist:

  • [ ] Whitelist allowed domains/IPs
  • [ ] Block private IP ranges (10.0.0.0/8, 192.168.0.0/16, 127.0.0.1)
  • [ ] Disable URL redirects or validate redirect targets
  • [ ] Use network segmentation (no internet access from app servers)

3. Risk Scoring (CVSS v3.1)

Purpose: Quantify vulnerability severity for prioritization

CVSS Formula: Base Score (0-10) = f(Impact, Exploitability)

Severity Levels:

  • Critical (9.0-10.0): Immediate action required, exploit in the wild
  • High (7.0-8.9): High priority, exploitable remotely
  • Medium (4.0-6.9): Medium priority, requires user interaction
  • Low (0.1-3.9): Low priority, limited impact

Impact Scoring:

  • Confidentiality Impact: None / Low / High
  • Integrity Impact: None / Low / High
  • Availability Impact: None / Low / High

Exploitability Scoring:

  • Attack Vector: Network (highest) / Adjacent / Local / Physical (lowest)
  • Attack Complexity: Low (easy) / High (difficult)
  • Privileges Required: None (highest) / Low / High (lowest)
  • User Interaction: None (highest) / Required (lower)

Quick Risk Matrix (Impact × Likelihood):

Impact / LikelihoodLowMediumHigh
HighMedHighCrit
MediumLowMedHigh
LowLowLowMed

Example Scoring:

Vulnerability: SQL Injection in login endpoint

CVSS Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N
- Attack Vector: Network (AV:N) - remotely exploitable
- Attack Complexity: Low (AC:L) - easy to exploit
- Privileges Required: None (PR:N) - unauthenticated
- User Interaction: None (UI:N) - no user action needed
- Confidentiality: High (C:H) - all user data exposed
- Integrity: High (I:H) - data can be modified
- Availability: None (A:N) - no DoS

Base Score: 9.1 (CRITICAL)

Checklist:

  • [ ] Score all identified vulnerabilities using CVSS
  • [ ] Prioritize remediation: Critical → High → Medium → Low
  • [ ] Define risk acceptance criteria (e.g., no Critical in production)
  • [ ] Track vulnerabilities in registry (Jira, GitHub Security)

4. Security Code Review Patterns

Purpose: Identify common vulnerabilities during code review

Input Validation

Rule: Never trust user input

Patterns:

# Whitelist validation (preferred)
ALLOWED_EXTENSIONS = {'.jpg', '.png', '.pdf'}
file_ext = os.path.splitext(filename)[1].lower()
if file_ext not in ALLOWED_EXTENSIONS:
    raise ValueError("Invalid file type")

# Regex validation
import re
EMAIL_PATTERN = re.compile(r'^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$')
if not EMAIL_PATTERN.match(email):
    raise ValueError("Invalid email")

# Type validation
from pydantic import BaseModel, validator

class UserInput(BaseModel):
    age: int
    email: str

    @validator('age')
    def age_must_be_positive(cls, v):
        if v < 0 or v > 150:
            raise ValueError('Invalid age')
        return v

Authentication & Authorization

Rule: Verify identity and permissions at every access point

Patterns:

# Decorator-based authorization
from functools import wraps

def require_role(role):
    def decorator(f):
        @wraps(f)
        def decorated_function(*args, **kwargs):
            if not current_user.has_role(role):
                abort(403)
            return f(*args, **kwargs)
        return decorated_function
    return decorator

@app.route('/admin/users')
@require_role('admin')
def list_users():
    return render_template('users.html', users=User.query.all())

# Resource ownership check
def check_ownership(resource, user):
    if resource.owner_id != user.id and not user.is_admin():
        abort(403, "Not authorized to access this resource")

Cryptography Best Practices

Rules:

  1. Don't roll your own crypto
  2. Use standard libraries (cryptography, libsodium)
  3. Use authenticated encryption (AES-GCM, ChaCha20-Poly1305)

Patterns:

# ✅ SECURE: Modern authenticated encryption
from cryptography.hazmat.primitives.ciphers.aead import AESGCM
import os

key = AESGCM.generate_key(bit_length=256)
aesgcm = AESGCM(key)
nonce = os.urandom(12)  # 96-bit nonce
ciphertext = aesgcm.encrypt(nonce, plaintext, associated_data=None)

# ✅ SECURE: Password hashing
import bcrypt
hashed = bcrypt.hashpw(password.encode(), bcrypt.gensalt(rounds=12))

# ✅ SECURE: Secure random token
import secrets
token = secrets.token_urlsafe(32)

Secrets Management

Rule: Never hardcode secrets

Patterns:

# ❌ VULNERABLE
API_KEY = "sk_live_abc123xyz789"

# ✅ SECURE: Environment variables
import os
API_KEY = os.environ['API_KEY']

# ✅ SECURE: Secrets manager (AWS Secrets Manager)
import boto3
client = boto3.client('secretsmanager')
response = client.get_secret_value(SecretId='prod/api-key')
API_KEY = response['SecretString']

# ✅ SECURE: Configuration file (gitignored)
import json
with open('/etc/secrets/config.json') as f:
    config = json.load(f)
    API_KEY = config['api_key']

Checklist:

  • [ ] No secrets in source code
  • [ ] No secrets in git history (use git-secrets)
  • [ ] Secrets in environment variables or vault
  • [ ] Rotate secrets regularly
  • [ ] Use different secrets per environment (dev/staging/prod)

STRIDE Threat Modeling Worksheet

Use this template for every new feature/component:

## Threat Model: [Feature/Component Name]

**Description**: [Brief description of functionality]

**Date**: [YYYY-MM-DD]

**Reviewer**: [Your name]

---

### Components

List all components involved:
1. [Component 1: e.g., Login API endpoint]
2. [Component 2: e.g., User database]
3. [Component 3: e.g., Session store]

---

### Data Flow

Describe how data flows:
1. User submits credentials → Login API
2. Login API queries User DB
3. On success, create session in Session Store
4. Return session token to user

---

### Threats Identified

#### Spoofing
- [ ] **Threat**: Attacker uses stolen credentials
  - **Mitigation**: Implement MFA
  - **Priority**: High

#### Tampering
- [ ] **Threat**: Man-in-the-middle modifies login request
  - **Mitigation**: Enforce HTTPS/TLS 1.3
  - **Priority**: Critical

#### Repudiation
- [ ] **Threat**: User denies login action
  - **Mitigation**: Log all authentication events with timestamp
  - **Priority**: Medium

#### Information Disclosure
- [ ] **Threat**: Verbose error reveals username existence
  - **Mitigation**: Generic error message "Invalid credentials"
  - **Priority**: Medium

#### Denial of Service
- [ ] **Threat**: Brute force attack exhausts server resources
  - **Mitigation**: Rate limiting (5 attempts/minute)
  - **Priority**: High

#### Elevation of Privilege
- [ ] **Threat**: Session fixation allows privilege escalation
  - **Mitigation**: Regenerate session ID on login
  - **Priority**: High

---

### Risk Summary

Total threats identified: [N]
- Critical: [N]
- High: [N]
- Medium: [N]
- Low: [N]

**Overall Risk Level**: [Critical/High/Medium/Low]

Security Checklist (Pre-Deployment)

Use this before deploying any code to production:

Authentication & Authorization

  • [ ] Strong password policy enforced (12+ chars, complexity)
  • [ ] MFA available for sensitive accounts
  • [ ] Session timeout configured (15-30 minutes)
  • [ ] Secure session cookies (HttpOnly, Secure, SameSite)
  • [ ] Authorization checks on all endpoints
  • [ ] Default deny (whitelist approach)

Input Validation

  • [ ] All user input validated (whitelist preferred)
  • [ ] Parameterized queries used (no string concatenation)
  • [ ] File upload restrictions (type, size, content)
  • [ ] Output encoding for XSS prevention

Cryptography

  • [ ] TLS 1.2+ enforced for all connections
  • [ ] Passwords hashed with bcrypt/Argon2
  • [ ] No hardcoded secrets
  • [ ] Secrets in environment variables or vault
  • [ ] Secure random generators used (secrets module)

Error Handling

  • [ ] Generic error messages (no stack traces)
  • [ ] Errors logged with context (user, IP, timestamp)
  • [ ] No sensitive data in logs

Security Headers

  • [ ] Content-Security-Policy configured
  • [ ] X-Content-Type-Options: nosniff
  • [ ] X-Frame-Options: DENY or SAMEORIGIN
  • [ ] Strict-Transport-Security (HSTS)
  • [ ] X-XSS-Protection: 1; mode=block

Logging & Monitoring

  • [ ] Authentication events logged
  • [ ] Authorization failures logged
  • [ ] Security alerts configured
  • [ ] Log retention policy defined

Dependencies

  • [ ] No known vulnerabilities (npm audit, pip-audit)
  • [ ] Dependencies up to date
  • [ ] Unused dependencies removed
  • [ ] CI/CD includes security scanning

Infrastructure

  • [ ] Debug mode disabled in production
  • [ ] Default credentials changed
  • [ ] Unnecessary services disabled
  • [ ] Network segmentation implemented
  • [ ] Rate limiting configured

Reference Materials

Detailed Guides:

  • OWASP Top 10: https://owasp.org/www-project-top-ten/
  • STRIDE Methodology: https://learn.microsoft.com/en-us/azure/security/develop/threat-modeling-tool-threats
  • CVSS Calculator: https://www.first.org/cvss/calculator/3.1
  • CWE Database: https://cwe.mitre.org/

Secure Coding Guides:

  • OWASP Cheat Sheet Series: https://cheatsheetseries.owasp.org/
  • NIST Secure Software Development Framework: https://csrc.nist.gov/projects/ssdf

Tools:

  • Static Analysis: Bandit (Python), ESLint (JS), cargo-audit (Rust)
  • Dependency Scanning: Snyk, Dependabot, npm audit
  • Dynamic Analysis: OWASP ZAP, Burp Suite

Self-Assessment

After applying security analysis, verify:

  • [ ] STRIDE Coverage: All 6 threat categories considered for this component
  • [ ] OWASP Awareness: Top 10 vulnerabilities reviewed and mitigated
  • [ ] Risk Scoring: Vulnerabilities scored and prioritized
  • [ ] Secure Patterns: Code review patterns applied
  • [ ] Checklist Completion: Pre-deployment checklist 100% complete
  • [ ] Documentation: Threat model and mitigations documented
  • [ ] Testing: Security tests written (auth bypass, injection, etc.)

Confidence Level:

  • High (90%+): All frameworks applied, threat model complete, security tests passing
  • Medium (70-89%): Main threats addressed, some edge cases remain
  • Low (<70%): Significant security gaps identified - continue working

Summary

Security Analysis Skills provide systematic frameworks for integrating security into all development work:

  1. STRIDE Threat Modeling: Identify threats by category (Spoofing, Tampering, Repudiation, Information Disclosure, DoS, Elevation of Privilege)
  2. OWASP Top 10: Address most critical web vulnerabilities
  3. CVSS Risk Scoring: Quantify and prioritize vulnerability remediation
  4. Secure Coding Patterns: Apply proven security patterns in code review

Remember: Security is not a feature, it's a requirement. Apply these frameworks proactively during design and development, not reactively after incidents.

Target: Zero Critical/High vulnerabilities in production deployments.

平台分布

Antigravity

27.7%
按下载量换算42

Claude Code

23.95%
按下载量换算36

Gemini CLI

20.77%
按下载量换算31

OpenCode

13.18%
按下载量换算20

windsurf

7.64%
按下载量换算11

github-copilot

3.66%
按下载量换算5

安全审计

暂无安全审计结果可展示。

权限和风险

接触敏感数据

该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。目前只有一个公开来源,建议同时核对源仓库。

继续浏览同类 Skills