はまやんはまやんはまやん

hamayanhamayan's blog

fsociety [Zh3r0 CTF 2020]

Chall Link : http://web.zh3r0.ml:6565/
I hate this society.
Author : Cryptonic007,Finch
Automated tools allowed.

f:id:hamayanhamayan:20200619224849p:plain

ソースコードを見てみるとrobot.gifとなってるので、とりあえず/robots.txtを見てみよう。
/elliot.htmlが紹介される。
"check my js"
/myscript.jsを見てみよう。

(![]+[])[+[]]+(![]+[])[!+[]+!+[]+!+[]]+(!![]+[][(![]+[])[+[]]+([![]]+[][[]])[+!+[]+[+[]]]+(![]+[])[!+[]+!+[]]+(!![]+[])[+[]]+(!![]+[])[!+[]+!+[]+!+[]]+(!![]+[])[+!+[]]])[+!+[]+[+[]]]+([][(![]+[])[+[]]+([![]]+[][[]])[+!+[]+[+[]]]+(![]+[])[!+[]+!+[]]+(!![]+[])[+[]]+(!![]+[])[!+[]+!+[]+!+[]]+(!![]+[])[+!+[]]]+[])[!+[]+!+[]+!+[]]+([![]]+[][[]])[+!+[]+[+[]]]+(!![]+[])[!+[]+!+[]+!+[]]+(!![]+[])[+[]]+(+[![]]+[+(+!+[]+(!+[]+[])[!+[]+!+[]+!+[]]+[+!+[]]+[+[]]+[+[]]+[+[]])])[+!+[]+[+[]]]+([![]]+[][[]])[+!+[]+[+[]]]+(![]+[])[!+[]+!+[]+!+[]]+(![]+[])[!+[]+!+[]]+([![]]+[][[]])[+!+[]+[+[]]]+(!![]+[])[+[]]

おー、これはあれですね…JSFuckですね。
JSfuck Decoder | De-Obfuscator

fsocietyislit

あ、あれ…?
automated toolが使えるので、dirbを使ってスキャニングしよう。

/code/が403を返す。
エスパーをすると、/code/flag.phpが見つかる。

postでコードを送れとあるので、スーパーエスパーを働かせて、
先ほど見つかったfsocietyislitmd5ハッシュして、code=[hashed]をしてPOSTするとフラグが出てくる。