Home  >  Article  >  Backend Development  >  php代码审计比较有意思的例子_PHP教程

php代码审计比较有意思的例子_PHP教程

WBOY
WBOYOriginal
2016-07-13 10:30:191045browse

代码审计比较有意思的例子
貌似是去年 ecshop支付漏洞
偶然出来的一个例子,感觉不错。分享下

复制代码 代码如下:

$a=addslashes($_GET['a']);
$b=addslashes($_GET['b']);
print_r($a.'
');
print_r($b.'
');
print_r(str_replace($a,'',$b));
//seay
?>

php代码审计比较有意思的例子_PHP教程

成功转义反斜杠(\)使得单引号报错。导致注入产生。

来源:http://www.moonsec.com/

www.bkjia.comtruehttp://www.bkjia.com/PHPjc/766108.htmlTechArticle代码审计比较有意思的例子 貌似是去年 ecshop支付漏洞 偶然出来的一个例子,感觉不错。分享下 复制代码 代码如下: ?php $a=addslashes($_GET['...
Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn