From appsec
This skill should be used when the user asks to "check for logging issues", "analyze security logging", "find missing audit logs", "check for log injection", "audit monitoring configuration", or mentions "logging", "audit trail", "log injection", "monitoring", or "alerting" in a security context. Maps to OWASP Top 10 2021 A09: Security Logging and Monitoring Failures.
npx claudepluginhub florianbuetow/claude-code --plugin appsecThis skill uses the workspace's default tool permissions.
Analyze source code for security logging and monitoring failures including missing
Acquire memory dumps from live systems/VMs and analyze with Volatility 3 for processes, networks, DLLs, injections in incident response or malware hunts.
Provides x86-64/ARM disassembly patterns, calling conventions, control flow recognition for static analysis of executables and compiled binaries.
Identifies anti-debugging checks like IsDebuggerPresent, NtQueryInformationProcess in Windows binaries; suggests bypasses via patches/hooks/scripts for malware analysis, CTFs, authorized RE.
Analyze source code for security logging and monitoring failures including missing audit logging for security events, sensitive data in logs, log injection, absence of alerting on failures, logs only stored locally, and missing tamper protection.
This is the most architectural OWASP category. Scanners provide minimal coverage for logging failures, so Claude's analysis of code patterns, logging configuration, and event coverage is the primary value of this skill.
Read ../../shared/schemas/flags.md for the full flag specification. This skill
supports all cross-cutting flags. Key flags for this skill:
--scope determines which files to analyze (default: changed)--depth standard reads code and checks logging around security-critical operations--depth deep traces security event flows to verify each produces an audit log entry--severity filters output (logging gaps are often medium, sensitive data in logs is high)Read ../../shared/frameworks/owasp-top10-2021.md, section A09:2021 - Security
Logging and Monitoring Failures, for the full category description, common
vulnerabilities, and prevention guidance.
Key CWEs in scope:
Read references/detection-patterns.md for the full catalog of code patterns,
search heuristics, language-specific examples, and false positive guidance.
Parse flags and resolve the file list per ../../shared/schemas/flags.md.
Filter to files likely to contain logging logic or security-critical operations:
**/auth/**, **/login/**, **/session/**)**/middleware/**, **/guards/**, **/policies/**)**/logging/**, **/logger/**, **/*log*config*)**/errors/**, **/exceptions/**, **/handlers/**)**/routes/**, **/controllers/**, **/api/**)**/config/**, *.yaml, *.toml, *.ini, *.env*)Detect scanners per ../../shared/schemas/scanners.md:
semgrep -- can detect some log injection and sensitive data in logsbandit -- Python-specific logging issues (e.g., sensitive data in debug logs)Record which scanners are available and which are missing. Note: scanner coverage for logging failures is limited. Claude analysis is the primary detection mechanism for this category.
If semgrep is available, run with rules targeting logging patterns:
semgrep scan --config auto --json --quiet <target>
Filter results to rules matching log injection, sensitive data exposure in logs, and logging configuration issues. Normalize output to the findings schema.
This is the primary analysis step for logging failures. Perform manual code analysis:
When --depth deep, additionally trace:
Format output per ../../shared/schemas/findings.md using the LOG prefix
(e.g., LOG-001, LOG-002).
Include for each finding:
These are the high-signal patterns specific to logging and monitoring failures. Each
maps to a detection pattern in references/detection-patterns.md.
Missing authentication event logging -- Login, failed login, logout, password reset, and MFA events that produce no audit log entry.
Sensitive data in log statements -- Passwords, tokens, API keys, credit card numbers, or PII written to logs, especially at DEBUG or INFO level.
Log injection via user input -- User-controlled strings passed directly into log format strings without sanitization, enabling log forgery or CRLF injection.
Missing access control failure logging -- Authorization denials that are not logged, making it impossible to detect brute-force or enumeration attacks.
Silent error swallowing -- Catch/except blocks with pass, empty bodies, or
comments like "ignore" that discard errors without logging.
No centralized logging configuration -- Logging set up ad-hoc per file with no consistent format, level, or destination configuration.
Logs stored only locally -- Log output goes to local files or stdout with no forwarding to a centralized log management system.
Missing alerting configuration -- No evidence of alerting thresholds for security-critical events (repeated failed logins, privilege escalation attempts).
Excessive logging of request/response bodies -- Logging full HTTP bodies that may contain sensitive data without redaction.
| Scanner | Coverage | Command |
|---|---|---|
| semgrep | Log injection, sensitive data in debug logs | semgrep scan --config auto --json --quiet <target> |
| bandit | Python logging of sensitive data | bandit -r <target> -f json -q |
Fallback (no scanner): Use Grep with patterns from references/detection-patterns.md
to find log statements with user input interpolation, catch blocks without logging,
authentication functions without log calls, and sensitive data patterns in log arguments.
Report findings with confidence: medium.
Scanner coverage for this category is inherently limited. Most logging failures are architectural gaps (missing logging) rather than code-level bugs (present but incorrect code), making Claude analysis the primary detection mechanism.
Relevant semgrep rule categories:
python.lang.security.audit.logging.*javascript.express.security.audit.logging.*java.lang.security.audit.logging.*generic.logging.security.*Use the findings schema from ../../shared/schemas/findings.md.
LOG (e.g., LOG-001)loggingowaspA09A09:2021R (Repudiation)Severity guidance for this category: