首页 > 其他 > 详细

zf框架 文件安全性检查

时间:2015-06-24 10:45:37      阅读:120      评论:0      收藏:0      [点我收藏+]

protected static function _securityCheck($filename)
{
/**
* Security check
*/
if (preg_match(‘/[^a-z0-9\\/\\\\_.:-]/i‘, $filename)) {
require_once ‘Zend/Exception.php‘;
throw new Zend_Exception(‘Security check: Illegal character in filename‘);
}
}

zf框架 文件安全性检查

原文:http://www.cnblogs.com/b13272012771/p/4596930.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!