find
Scan arbitrary text for embedded JWTs and print each one found, one per line. JWTs often turn up hidden inside a URL query parameter, a JSON response body, an HTML page, a log file, or an Authorization header — find locates and extracts them so they can be piped into other jwtop commands.
Only structurally valid JWTs are returned; look-alike strings that fail to decode are silently skipped.
jwtop find [text]jwtop find --file <path>echo <text> | jwtop findInput sources, in priority order:
--file <path>— read text from a file[text]— inline text argument- stdin — used when no argument or
--fileis given
Examples
Section titled “Examples”# Extract every JWT from a captured HTTP responsecurl -s https://api.example.com/profile | jwtop find
# Extract the JWT from a URLjwtop find "https://example.com/callback?token=eyJhbGciOiJIUzI1NiJ9...&state=xyz"
# Scan a saved page or log filejwtop find --file response.htmlCombine with other commands
Section titled “Combine with other commands”Since every command that accepts a token also reads it from stdin, find composes directly into a pipeline:
# Decode the first JWT found in a filejwtop find --file response.html | head -1 | jwtop decode
# Decode a JWT found in a URLecho "https://example.com/?token=eyJ..." | jwtop find | jwtop decode
# Verify every JWT in a log filejwtop find --file app.log | while read tok; do jwtop verify "$tok" --secret mysecret && echo "OK: $tok"done
# Crack all tokens found in a captured HTTP responsecurl -s https://api.example.com/profile | jwtop find | while read tok; do jwtop crack "$tok"done