首页 试题详情
单选题

如下代码所示functioncheck($page){$whitelist=array(‘db_sql.php’,’db_page.php’);$_page=urldecode($page);$_page=mb_substr($_page,0,mb_strpos($_page.‘?‘,‘?‘));if(in_array($_page,$whitelist)){returntrue;}(1分)

A$page=db_sql.php?/../../../windows/win.ini

B$page=db_sql.php%3f/../../../../windows/win.ini

C$page=db_page.php%253f/../../../windows/win.ini

D$page=db_page.php?/../../../../windows/win.ini

正确答案:A (备注:此答案有误)

相似试题

  • 单选题

    如下代码functioncheck($page){$whitelist=array(‘db_sql.php’,’db_page.php’);$_page=urldecode($page);$_page=mb_substr($_page,0,mb_strpos($_page.‘?‘,‘?‘));if(in_array($_page,$whitelist)){returntrue;}(1分)

    答案解析

热门题库