1
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

毎日write up 1日目 Power Cookie

Posted at

問題

Description

Can you get the flag?
Additional details will be available after launching your challenge instance.
スクリーンショット 2025-05-05 23.53.41.png

解法

普通にクリックすると以下のようになる。
名前と遷移先の文から、クッキーにてゲストかそうでないか判断しているのではとメタ読み
スクリーンショット 2025-05-05 23.54.35.png
Burp suite等のプロキシツールで見てみる
スクリーンショット 2025-05-05 23.56.25.png
するとguest.jsなるものがあることがわかる。

function continueAsGuest()
{
  window.location.href = '/check.php';
  document.cookie = "isAdmin=0";
}

cookieにisAdmin=0をセットしていることがわかる
check.phpのリクエストを見るとたしかにCookie: isAdmin=0の記述がある。
そのままプロキシツール等でisAdmin=1に書き換えるとflagゲット

1
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?