/viperclaw:viper-webauthn-passkey-mfafrom viperclaw
Audits WebAuthn, FIDO2 Passkey, and TOTP MFA implementations for security flaws including challenge reuse, rpId/origin validation, signCount clone detection, userVerification enforcement, and step-up MFA binding.
Ships in viperclaw. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
viper-webauthn-passkey-mfa)flowchart LR
Auth["Navigator.credentials.get()"] --> Chal["Atomic getDel(Challenge) + Pinned RPID"] --> UV["requireUserVerification: true"] --> Count["Verify & Update signCount"]
viperclaw taint . --db .viperclaw/graph.db
verifyRegistrationResponse, verifyAuthenticationResponse, clientDataJSON, expectedOrigin, expectedRPID, userVerification, totp.verify.challenge must be >= 16 bytes of CSPRNG output, stored in the server-side session/cache bound to the specific user_id with a short TTL (e.g., 5 minutes), and deleted atomically upon the first verification attempt.expectedOrigin & expectedRPID Pinning: Never derive expectedOrigin or expectedRPID dynamically from the incoming Origin or Host HTTP request header; compare against a hardcoded configuration constant.userVerification: "required" for Passwordless Flows: When passkeys act as a single-factor password replacement, enforce userVerification: "required" (UV flag checked in authenticatorData) so a stolen physical security key cannot authenticate without biometrics/PIN.signCount) & TOTP Replay Prevention: Update the stored credential signCount on each login and alert/revoke if newSignCount <= storedSignCount (when signCount > 0); for TOTP, record the last used 30-second time step per user so a 6-digit code cannot be replayed within the same window./mfa; issue a restricted, short-lived pre_mfa_token that is only valid on /api/mfa/verify.// ❌ VULNERABLE: Trusts client-supplied challenge & Origin header without deleting challenge
const verification = await verifyAuthenticationResponse({
response: req.body,
expectedChallenge: req.body.challenge,
expectedOrigin: req.headers.origin,
expectedRPID: req.hostname,
authenticator,
});
// ✅ HARDENED: Consumes server-stored challenge atomically & pins RPID/Origin + requireUserVerification
const expectedChallenge = await redis.getDel(`webauthn:chal:${session.userId}`);
if (!expectedChallenge) throw new UnauthorizedError("Expired or missing challenge");
const verification = await verifyAuthenticationResponse({
response: req.body,
expectedChallenge,
expectedOrigin: "https://login.example.com",
expectedRPID: "example.com",
requireUserVerification: true,
authenticator,
});
W3C WebAuthn L3, NIST SP 800-63B, CWE-294, CWE-287| Severity Tier | Baseline CVSS v3.1 Vector | Qualifying Security Impact |
|---|---|---|
| CRITICAL (9.0–10.0) | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H | Unauthenticated remote code execution, cross-tenant authentication or isolation gap, or direct theft of funds/keys. |
| HIGH (7.0–8.9) | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:N | Authenticated privilege escalation, unauthorized sensitive data exposure, or single-request service outage. |
| MEDIUM (4.0–6.9) | CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N | Scoped information disclosure, non-admin state mutation, or configuration weakness requiring user interaction. |
| LOW (0.1–3.9) | CVSS:3.1/AV:N/AC:H/PR:H/UI:N/S:U/C:L/I:N/A:N | Defense-in-depth hardening gap requiring high precondition complexity and minimal direct impact. |
viperclaw taint . --db .viperclaw/graph.db and viperclaw verify to record the verified state in .viperclaw/graph.db.What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub zahidoverflow/viperclaw --plugin viperclaw72 skills in this plugin
/viper-agent-skill-supplychainAI Agent Skill, Plugin & MCP Config Supply-Chain Auditor (modeled on NVIDIA SkillSpector & OWASP Agentic Skills Top 10). Audits SKILL.md bundles and MCP JSON configs./viper-ai-llm-guardrailsAI, LLM & MCP Application Security & Guardrails Auditor (OWASP LLM Top 10). Reviews prompt boundaries, RAG data isolation, tool-call authorization, and output sanitization./viper-api-gateway-apigee-kongAPI Gateway, BFF & Rate-Tier Policy Auditor (Kong, AWS API Gateway, Apigee, Envoy Gateway). Reviews JWT authorizers, backend origin lockdown, and route-level quotas.Other plugins' skills for the same job