ワンクリックで
auth-failures
Enforces secure authentication patterns before any login, session, token, or credential management code is written or modified.
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
メニュー
Enforces secure authentication patterns before any login, session, token, or credential management code is written or modified.
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
SOC 職業分類に基づく
Full pre-ship security review that runs all ten OWASP Top 10 checks in sequence. Use before any significant feature ships to production.
Checks for server-side request forgery risk before any code that makes outbound HTTP requests based on user-supplied URLs or parameters is written or modified.
Requires structured security event logging before any authentication, authorization, or sensitive data access code ships.
Checks deserialization safety, CI/CD pipeline integrity, and dependency integrity before any code that deserializes objects or executes pipeline scripts is written or modified.
Checks CVE status, license compatibility, and maintenance health of any new dependency before it enters the codebase.
Checks for insecure default settings, exposed debug endpoints, permissive CORS, open cloud storage, and missing security headers before any configuration or deployment code ships.
| name | auth-failures |
| description | Enforces secure authentication patterns before any login, session, token, or credential management code is written or modified. |
| when_to_use | Apply automatically when writing or modifying authentication flows, login endpoints, session management, token issuance, password reset, MFA, or credential storage. |
Authentication failures include broken login flows, weak session management, and credential handling that is technically functional but exploitable. An agent implementing an auth flow will produce something that works. The question is whether it resists brute force, session fixation, credential stuffing, and token leakage.
1. Rate limiting on login and credential endpoints Login, password reset, and MFA verification endpoints must have rate limiting. Without it, brute force and credential stuffing are possible. State the limit: requests per minute, lockout threshold, and lockout duration.
2. Session management Sessions must be invalidated on logout. Session tokens must be regenerated after privilege escalation (e.g., after login, after MFA completion). Session tokens must not appear in URLs.
3. Token security
JWTs must use a strong algorithm (RS256, ES256, HS256 with a secret of 32+ bytes). The alg: none attack must be blocked. JWT secrets must not be hardcoded. Token expiry must be set.
4. Password policy Minimum length of 8 characters. No maximum length below 64 characters (password truncation is a vulnerability). Rejection of known breached passwords (Have I Been Pwned list) is best practice.
5. MFA For any system handling financial data, health data, or admin access, MFA is required. State whether it is implemented, planned, or explicitly out of scope with justification.
6. Account enumeration Login failure messages must not distinguish between "user not found" and "wrong password." Both conditions must return the same response.
## Authentication Failures Check
**Auth flow type:** [login / registration / password reset / session / token / MFA]
### Findings
- Rate limiting: [yes — state limit / no — BLOCKED]
- Session invalidation on logout: [yes / no — BLOCKED / not applicable]
- Token algorithm: [algorithm name — flag if alg:none or weak symmetric]
- Token expiry set: [yes / no — BLOCKED if no]
- Account enumeration prevention: [yes / no]
- MFA: [implemented / planned / out of scope — justification required if out of scope for sensitive systems]
### Verdict
[CLEAR / BLOCKED — list each failure]
Block before writing auth code if:
alg: none or uses a weak/hardcoded secret# Good: rate-limited login with account enumeration prevention
@limiter.limit("5/minute")
@app.route("/login", methods=["POST"])
def login():
user = User.query.filter_by(email=request.form["email"]).first()
if not user or not user.check_password(request.form["password"]):
return jsonify({"error": "Invalid credentials"}), 401 # same message both cases
session.clear() # session fixation prevention
session["user_id"] = user.id
return jsonify({"status": "ok"})