JaWT Scratchpad
Problem
Check the admin scratchpad! https://2019shell1.picoctf.com/problem/12283/ or http://2019shell1.picoctf.com:12283
Solution
Login as any user. I used
john
.Get the
jwt token
from thejwt cookie
. Example token:eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyIjoiam9obiJ9._fAF3H23ckP4QtF1Po3epuZWxmbwpI8Q26hRPDTh32Y
Paste the
jwt token
into a file calledtoken.txt
Run this command with hashcat to crack the token:
hashcat -a0 -m 16500 token.txt rockyou.txt
Run the same command but with
--show
to get the password used:hashcat -a0 -m 16500 token.txt rockyou.txt --show
Paste original token into https://www.jsonwebtoken.io/
Type password
ilovepico
into theSigning Key
field and changeuser
in the payload toadmin
Copy and paste the new token into the
jwt cookie
Refresh the page to get the flag
Flag
picoCTF{jawt_was_just_what_you_thought_9de8e25511a8841ab9ade0aa092be116}
Last updated