时间:2021-07-01 10:21:17 帮助过:16人阅读
function authorization($seed = '') {
$encode = $_SERVER['SERVER_SOFTWARE'] . $_SERVER['SERVER_NAME'] . $_SERVER['DOCUMENT_ROOT'] .
$_SERVER['SERVER_ADMIN'] . $_SERVER['SERVER_ADDR'] . PHP_VERSION . PHP_OS . __FILE__;
return md5 ($encode);
}
$authorization_key = 'jb51.net';
echo authorization($authorization_key);//这里是生成字符串验证
$authorization_check = array('dd670852938815f3892d3c511cc8fceb','ddc976cc02bce5c3c22c4d7d201c0cae' );//授权字串,把生成的字符验证复制到这里来
if (!in_array(authorization ($authorization_key), $authorization_check)) {
die('对不起,你的程序未经过脚本之家授权!!');
}
http://www.bkjia.com/PHPjc/320306.htmlwww.bkjia.comtruehttp://www.bkjia.com/PHPjc/320306.htmlTechArticle以下是我的一个想法,把服务器的php环境配置也应用在程序里面,生成一个许可字串,然后将字串写入到许可的文件代码中。就算是将程序...