Skip to content
KitploitKITPLOIT
उपकरणब्लॉग
जमा करें
उपकरणब्लॉग
जमा करें

हैकिंग, पेनटेस्ट और साइबर सुरक्षा उपकरण आपके सुरक्षा शस्त्रागार के लिए!

Kitploit हैकिंग, साइबर सुरक्षा और पेंटेस्टिंग टूल्स की एक निर्देशिका है। कमजोरियों को खोजने, सिस्टम का विश्लेषण करने, परीक्षण को स्वचालित करने और अपनी सुरक्षा को मजबूत करने के लिए नवीनतम प्रोजेक्ट अपडेट खोजें।

··फ़ीड·संपर्क·गोपनीयता·© 2026 Kitploit

टूल निर्देशिका

श्रेणियाँ

सभी श्रेणियाँ देखें
Loading categories
jwt-hack — JSON Web Token Hack Toolkit | Kitploit
उपकरण/GitHubGitHub/hahwul/jwt-hack
Password CrackingVulnerability ScannersEncryption/Decryption ToolsPayload GenerationWeb SecurityPenetration Testing
GitHubhahwul/jwt-hack

jwt-hack

JSON Web Token Hack Toolkit

रिपॉजिटरी देखें
1.0k1213घं 42मि पहलेKitploit द्वारा समीक्षित

सबसे लोकप्रिय

सभी देखें →

हमारे समुदाय द्वारा सबसे अधिक उपयोग किए जाने वाले उपकरण खोजें।

सभी उपकरण खोजें

हमारे उपकरणों का संग्रह ब्राउज़ करें

सभी उपकरण देखें →
साझा करें
वेबसाइट
अनुरोधित भाषा में सामग्री उपलब्ध नहीं है। अंग्रेज़ी संस्करण दिखाया जा रहा है।
jwt-hack

JSON Web Token Hack Toolkit


A high-performance toolkit for testing, analyzing and attacking JSON Web Tokens.

Installation

Cargo

root@kitploit:~
cargo install jwt-hack

Homebrew

root@kitploit:~
brew install jwt-hack

Snapcraft (Ubuntu)

root@kitploit:~
sudo snap install jwt-hack

From source

root@kitploit:~
git clone https://github.com/hahwul/jwt-hack
cd jwt-hack
cargo install --path .

Docker images

GHCR

root@kitploit:~
docker pull ghcr.io/hahwul/jwt-hack:latest

Docker Hub

root@kitploit:~
docker pull hahwul/jwt-hack:v2.6.0

Features

Basic Usage

Decode a JWT

You can decode both regular and DEFLATE-compressed JWTs. The tool will automatically detect and decompress compressed tokens.

root@kitploit:~
jwt-hack decode eyJhbGciOiJIUzI1NiJ9.eyJzdWIiOiIxMjM0In0.CHANGED
jwt-hack decode COMPRESSED_JWT_TOKEN

Decode a JWE

Decode JWE (JSON Web Encryption) tokens to analyze their structure. The tool automatically detects JWE format (5 parts) and displays the encryption details.

root@kitploit:~
# Decode JWE token structure
jwt-hack decode eyJhbGciOiJkaXIiLCJlbmMiOiJBMjU2R0NNIn0..ZHVtbXlfaXZfMTIzNDU2.eyJ0ZXN0IjoiandlIn0.ZHVtbXlfdGFn

# Shows JWE header, encrypted key, IV, ciphertext, and authentication tag

Encode a JWT

root@kitploit:~
jwt-hack encode '{"sub":"1234"}' --secret=your-secret

Encode a JWT with DEFLATE Compression

You can use the --compress option to apply DEFLATE compression to the JWT payload.

root@kitploit:~
jwt-hack encode '{"sub":"1234"}' --secret=your-secret --compress
root@kitploit:~
# With Private Key
ssh-keygen -t rsa -b 4096 -E SHA256 -m PEM -P "" -f RS256.key
jwt-hack encode '{"a":"z"}' --private-key RS256.key --algorithm=RS256

Encode a JWE

Create JWE (JSON Web Encryption) tokens for testing encrypted JWT scenarios.

root@kitploit:~
# Basic JWE encoding
jwt-hack encode '{"sub":"1234", "data":"encrypted"}' --jwe --secret=your-secret

# JWE tokens are encrypted and can only be decrypted with the proper key
jwt-hack encode '{"sensitive":"data"}' --jwe

Verify a JWT

Checks if a JWT's signature is valid using the provided secret or key.

root@kitploit:~
# With Secret (HMAC algorithms like HS256, HS384, HS512)
jwt-hack verify YOUR_JWT_TOKEN_HERE --secret=your-256-bit-secret

# With Private Key (for asymmetric algorithms like RS256, ES256, EdDSA)
jwt-hack verify YOUR_JWT_TOKEN_HERE --private-key path/to/your/RS256_private.key

Crack a JWT

Dictionary and brute force attacks also support JWTs compressed with DEFLATE.

root@kitploit:~
# Dictionary attack
jwt-hack crack -w wordlist.txt JWT_TOKEN
jwt-hack crack -w wordlist.txt COMPRESSED_JWT_TOKEN

# Bruteforce attack
jwt-hack crack -m brute JWT_TOKEN --max=4
jwt-hack crack -m brute COMPRESSED_JWT_TOKEN --max=4

Generate payloads

root@kitploit:~
jwt-hack payload JWT_TOKEN --jwk-attack evil.com --jwk-trust trusted.com

Scan for vulnerabilities

Automatically scan JWT tokens for common security issues and vulnerabilities.

root@kitploit:~
# Full scan including weak secret detection and payload generation
jwt-hack scan JWT_TOKEN

# Skip secret cracking for faster results
jwt-hack scan JWT_TOKEN --skip-crack

# Skip payload generation
jwt-hack scan JWT_TOKEN --skip-payloads

# Use custom wordlist for weak secret detection
jwt-hack scan JWT_TOKEN -w custom_wordlist.txt

# Limit secret testing attempts
jwt-hack scan JWT_TOKEN --max-crack-attempts 50

The scan command checks for:

  • None algorithm vulnerability: Detects if the token accepts unsigned tokens
  • Weak secrets: Tests against common passwords (customizable with wordlist)
  • Algorithm confusion: Identifies tokens vulnerable to RS256->HS256 attacks
  • Token expiration issues: Checks for missing or improper expiration claims
  • Missing security claims: Verifies presence of recommended JWT claims
  • Kid header injection: Detects potential SQL/path injection vulnerabilities
  • JKU/X5U header attacks: Identifies URL spoofing attack vectors

Server (REST API)

Start a local REST API for automation and integrations. To require authentication, use --api-key and include X-API-KEY in requests.

root@kitploit:~
# Start on localhost:3000 with API key protection
jwt-hack server --api-key your-api-key

# Example request (must include X-API-KEY when --api-key is set)
curl -s http://127.0.0.1:3000/health -H 'X-API-KEY: your-api-key'

MCP (Model Context Protocol) Server Mode

jwt-hack can run as an MCP server, allowing AI models to interact with JWT functionality through a standardized protocol.

root@kitploit:~
# Start MCP server (communicates via stdio)
jwt-hack mcp

The MCP server exposes the following tools:

Example MCP Usage

The MCP server is designed to be used by AI models and MCP clients. Each tool accepts JSON parameters and returns structured responses.

Decode Tool:

root@kitploit:~
{
  "name": "decode",
  "arguments": {
    "token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9..."
  }
}

Encode Tool:

root@kitploit:~
{
  "name": "encode",
  "arguments": {
    "json": "{\"sub\":\"1234\",\"name\":\"test\"}",
    "secret": "mysecret",
    "algorithm": "HS256"
  }
}

MCP Client Integration Examples

You can connect jwt-hack’s MCP server to popular MCP-enabled clients. Make sure the jwt-hack binary is on your system and accessible by the client.

VSCode

root@kitploit:~
{
  "servers": {
    "jwt-hack": {
      "type": "stdio",
      "command": "jwt-hack",
      "args": [
        "mcp"
      ]
    }
  },
  "inputs": []
}

Claude Desktop

root@kitploit:~
{
  "mcpServers": {
    "jwt-hack": {
      "command": "jwt-hack",
      "args": ["mcp"],
      "env": {}
    }
  }
}

Supported Algorithms

Signature Algorithms (JWS)

Encryption Algorithms (JWE)

AlgorithmDescription
A128GCMAES-GCM using 128-bit key
A256GCMAES-GCM using 256-bit key

Key Management Algorithms (JWE)

AlgorithmDescription
dirDirect use of shared symmetric key

DEFLATE Compression Support

DEFLATE Compression Support The jwt-hack toolkit supports DEFLATE compression for JWTs.

  • Use the --compress option with encode to generate compressed JWTs.
  • The decode and crack modes automatically detect and handle compressed JWTs.

Contribute

Urx is open-source project and made it with ❤️ if you want contribute this project, please see CONTRIBUTING.md and Pull-Request with cool your contents.

टूल डाउनलोड करें
ModeDescriptionSupport
EncodeJWT/JWE EncoderSecret based / Key based / Algorithm / Custom Header / DEFLATE Compression / JWE
DecodeJWT/JWE DecoderAlgorithm, Issued At Check, DEFLATE Compression, JWE Structure
VerifyJWT VerifierSecret based / Key based (for asymmetric algorithms)
CrackSecret CrackerDictionary Attack / Brute Force / DEFLATE Compression
PayloadJWT Attack Payload Generatornone / jku&x5u / alg_confusion (signed via --public-key) / kid & claim injection / claims tampering / signature malleability / JWE probes / x5c / cty
ScanVulnerability ScannerAutomated security checks for common JWT vulnerabilities
ServerAPI ServerRun API Server Mode (http://localhost:3000)
MCPModel Context Protocol ServerAI model integration via standardized protocol
ToolDescriptionParameters
decodeDecode JWT tokenstoken (string)
encodeEncode JSON to JWTjson (string), secret (optional), algorithm (default: HS256), no_signature (boolean)
verifyVerify JWT signaturestoken (string), secret (optional), validate_exp (boolean)
crackCrack JWT tokenstoken (string), mode (dict/brute), chars (string), max (number)
payloadGenerate attack payloadstoken (string), target (string), jwk_attack (optional), jwk_protocol (default: https), public_key (optional PEM/path for signed alg-confusion)
AlgorithmDescriptionType
HS256HMAC using SHA-256Symmetric
HS384HMAC using SHA-384Symmetric
HS512HMAC using SHA-512Symmetric
RS256RSASSA-PKCS1-v1_5 using SHA-256Asymmetric
RS384RSASSA-PKCS1-v1_5 using SHA-384Asymmetric
RS512RSASSA-PKCS1-v1_5 using SHA-512Asymmetric
ES256ECDSA using P-256 and SHA-256Asymmetric
ES384ECDSA using P-384 and SHA-384Asymmetric
PS256RSASSA-PSS using SHA-256Asymmetric
PS384RSASSA-PSS using SHA-384Asymmetric
PS512RSASSA-PSS using SHA-512Asymmetric
EdDSAEdwards-curve Digital Signature AlgorithmAsymmetric
noneNo digital signature-