performing-jwt-none-algorithm-attack

Featured

Execute and test the JWT none algorithm attack to bypass signature verification by manipulating the alg header field in JSON Web Tokens.

AI & Automation 36,355 stars 4443 forks Updated 2 months ago Apache-2.0

Install

View on GitHub

Quality Score: 94/100

Stars 20%
100
Recency 20%
75
Frontmatter 20%
70
Documentation 15%
100
Issue Health 10%
50
License 10%
100
Description 5%
100

Skill Content

# Performing JWT None Algorithm Attack ## Overview The JWT none algorithm attack exploits a vulnerability in JSON Web Token libraries that accept tokens with the `alg` header set to `none`, effectively bypassing signature verification. When a server processes a JWT with `"alg": "none"`, it treats the token as valid without checking any cryptographic signature, allowing attackers to forge tokens with arbitrary claims such as escalated privileges, impersonated users, or extended expiration times. This vulnerability was first disclosed by Tim McLean in 2015 and has affected multiple JWT libraries across languages. ## When to Use - When conducting security assessments that involve performing jwt none algorithm attack - When following incident response procedures for related security events - When performing scheduled security testing or auditing activities - When validating security controls through hands-on testing ## Prerequisites - Target application using JWT for authentication or authorization - Ability to intercept and modify HTTP requests (Burp Suite, mitmproxy) - Python 3.8+ with PyJWT library for token crafting - Understanding of JWT structure (Header.Payload.Signature) - Authorization to perform security testing on the target > **Legal Notice:** This skill is for authorized security testing and educational purposes only. Unauthorized use against systems you do not own or have written permission to test is illegal and may violate computer fraud laws. ## JWT Str...

Details

Author
mukul975
Repository
mukul975/Anthropic-Cybersecurity-Skills
Created
8 months ago
Last Updated
2 months ago
Language
Python
License
Apache-2.0

Bundled in these plugins

Similar Skills

Semantically similar based on skill content — not just same category

AI & Automation Featured

exploiting-jwt-algorithm-confusion-attack

Exploits JWT algorithm confusion vulnerabilities where the server's token verification library accepts the algorithm specified in the JWT header rather than enforcing a fixed algorithm. The tester manipulates the alg header to switch from RS256 to HS256 (using the RSA public key as the HMAC secret), sets alg to none to bypass signature verification, or exploits kid/jku/x5u header injection to supply attacker-controlled keys. Activates for requests involving JWT algorithm confusion, alg none attack, key confusion attack, or JWT signature bypass.

36,355 Updated 2 months ago
mukul975
AI & Automation Listed

jwt

JWT (JSON Web Token) attack methodology. Covers algorithm confusion (RS256→HS256), none algorithm, weak secret cracking, kid injection, JKU header forgery, and claims manipulation.

4 Updated 1 months ago
sunilgentyala
AI & Automation Listed

defend-jwt

Defensive methodology against JSON Web Token (JWT) forgery and verification bypass: the alg:none downgrade, RS256-to-HS256 key confusion, unverified signatures, and missing claim checks that let an attacker mint a token your app will trust (MITRE ATT&CK T1606 Forge Web Credentials, then T1550.001 Use Alternate Authentication Material: Application Access Token). Signals live in application and API-gateway logs, WAF logs, and auth-service logs: the decoded JWT header alg and kid, the iss/aud/exp claims, and signature-verification failures. This skill gives the defender view of each bypass, the exact fields to log and alert on, a hypothesis-driven hunt, and library and key-management hardening mapped to ISO 27001:2022 and NIST CSF 2.0. Use when hardening JWT or bearer-token validation, reviewing a JWT auth flow, hunting for alg:none or key-confusion forgery, triaging a spike in JWT signature failures, or deciding how to rotate signing keys.

0 Updated 5 days ago
umbrasec-labs