testing-jwt-token-security

Tests JWT implementations for algorithm confusion, weak secrets, and authorization bypass vulnerabilities.

4|Updated Apr 28, 2026
One-click install
npx skills add https://github.com/braydos-h/BreachPilot --skill testing-jwt-token-security-braydos-h
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: testing-jwt-token-security
Source: https://github.com/braydos-h/BreachPilot/tree/main/skills/testing-jwt-token-security
Command: npx skills add https://github.com/braydos-h/BreachPilot --skill testing-jwt-token-security-braydos-h

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires pyjwt, requests, urllib3, and includes scripts (resource) and references (resource) components.

What problem does it solve? Applications that rely on JSON Web Tokens for authentication often contain exploitable weaknesses such as accepting unsigned tokens, using crackable HMAC secrets, or failing to revoke tokens after logout. This Skill provides a structured workflow and automation script to systematically assess JWT security during authorized penetration tests. ## Core Features & Use Cases - Algorithm Attack Testing: Detects algorithm none acceptance and RS256-to-HS256 confusion attacks using jwt_tool and PyJWT. - Secret Cracking & Token Forgery: Brute-forces weak HMAC secrets with wordlists or Hashcat, then forges tokens with arbitrary claims. - Lifecycle & Revocation Checks: Verifies whether expired tokens are accepted and whether tokens remain valid after logout. - Use Case: During an authorized web application assessment, capture a JWT from the login flow, run the agent script against the API, and receive a JSON report of confirmed vulnerabilities with severity ratings. ## Quick Start Run the JWT security agent against my captured token to test for algorithm none attacks, weak HMAC secrets, and token revocation issues on the authorized target API.

Frequently Asked Questions about testing-jwt-token-security

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I test JWT tokens for security vulnerabilities?▼

Decode the token to inspect its header and payload, then test for algorithm none acceptance, RS256-to-HS256 confusion, and weak HMAC secrets using jwt_tool or the included Python agent. Also verify claim tampering, expired token acceptance, and revocation after logout.

What tools are used for JWT penetration testing?▼

jwt_tool provides automated attack modules, Burp Suite's JWT Editor enables real-time token manipulation, and Hashcat (mode 16500) or John the Ripper crack HMAC secrets. PyJWT supports scripted token forging and manipulation.

How does the RS256 to HS256 algorithm confusion attack work?▼

If a server accepts both RS256 and HS256, an attacker retrieves the public RSA key (often from /.well-known/jwks.json) and uses it as the HMAC secret to sign a forged HS256 token. The server verifies it with the same public key, accepting the forgery.

Can weak JWT HMAC secrets be cracked?▼

Yes, HS256 tokens signed with dictionary words or short secrets can be cracked offline using Hashcat or John the Ripper with wordlists like rockyou.txt. Once recovered, the secret allows forging arbitrary tokens with any claims.

Why are JWTs still valid after logout?▼

JWTs are stateless, so servers cannot invalidate them without a server-side revocation list or blocklist. If the application only checks the signature and expiration, captured tokens remain usable until they expire, which is a reportable finding.