function injectChk($sql_str) { //防止注入
$check = eregi('select|insert|update|delete|\'|\/\*|\*|\.\.\/|\.\/|union|into|load_file|outfile', $sql_str);
if ($check) {
echo('非法字符串');
exit ();
} else {
return $sql_str;
}
}
阅读排行
- Java面试题全集(上) (1103417 )
- Wi-Fi 爆重大安全漏洞,Android、iOS、Windows 等所有无线设备都不安全了 (422637 )
- Jquery 使用Ajax获取后台返回的Json数据后,页面处理 (268967 )
- Java面试题全集(中) (237374 )
- 一个非常有用的函数——COALESCE (223395 )
- Java面试题全集(下) (221389 )
- Uncaught SyntaxError: Unexpected token ) (213821 )
- 如何用adb连接android手机?(我的亲自经历)------ 顺便说说unable to connect to 192.168.1.100:5555的原因和解决方法 (211040 )
- 如何利用C/C++逐行读取txt文件中的字符串(可以顺便实现文本文件的复制) (207918 )
- yum提示Another app is currently holding the yum lock; waiting for it to exit... (206193 )