discuz 修改member.php,member_getpasswd.php这是什么文件。发现被修改过。

/**

*      [Discuz!] (C)2001-2099 Comsenz Inc.

*      This is NOT a freeware, use is subject to license terms

*

*      $Id: member_getpasswd.php 35030 2014-10-23 07:43:23Z laoguozhang $

*/

if(!defined('IN_DISCUZ')) {

exit('Access Denied');

}

define('NOROBOT', TRUE);

if($_GET['uid'] && $_GET['id'] && $_GET['sign'] === make_getpws_sign($_GET['uid'], $_GET['id'])) {

$discuz_action = 141;

$member = getuserbyuid($_GET['uid'], 1);

$table_ext = isset($member['_inarchive']) ? '_archive' : '';

$member = array_merge(C::t('common_member_field_forum'.$table_ext)->fetch($_GET['uid']), $member);

list($dateline, $operation, $idstring) = explode("\t", $member['authstr']);

if($dateline < TIMESTAMP - 86400 * 3 || $operation != 1 || $idstring != $_GET['id']) {

showmessage('getpasswd_illegal', NULL);

}

if(!submitcheck('getpwsubmit') || $_GET['newpasswd1'] != $_GET['newpasswd2']) {

$hashid = $_GET['id'];

$uid = $_GET['uid'];

include template('member/getpasswd');

} else {

if($_GET['newpasswd1'] != addslashes($_GET['newpasswd1'])) {

showmessage('profile_passwd_illegal');

}

if($_G['setting']['pwlength']) {

if(strlen($_GET['newpasswd1']) < $_G['setting']['pwlength']) {

showmessage('profile_password_tooshort', '', array('pwlength' => $_G['setting']['pwlength']));

}

}

if($_G['setting']['strongpw']) {

$strongpw_str = array();

if(in_array(1, $_G['setting']['strongpw']) && !preg_match("/\d+/", $_GET['newpasswd1'])) {

$strongpw_str[] = lang('member/template', 'strongpw_1');

}

if(in_array(2, $_G['setting']['strongpw']) && !preg_match("/[a-z]+/", $_GET['newpasswd1'])) {

$strongpw_str[] = lang('member/template', 'strongpw_2');

}

if(in_array(3, $_G['setting']['strongpw']) && !preg_match("/[A-Z]+/", $_GET['newpasswd1'])) {

$strongpw_str[] = lang('member/template', 'strongpw_3');

}

if(in_array(4, $_G['setting']['strongpw']) && !preg_match("/[^a-zA-z0-9]+/", $_GET['newpasswd1'])) {

$strongpw_str[] = lang('member/template', 'strongpw_4');

}

if($strongpw_str) {

showmessage(lang('member/template', 'password_weak').implode(',', $strongpw_str));

}

}

loaducenter();

uc_user_edit(addslashes($member['username']), $_GET['newpasswd1'], $_GET['newpasswd1'], addslashes($member['email']), 1, 0);

$password = md5(random(10));

if(isset($member['_inarchive'])) {

C::t('common_member_archive')->move_to_master($member['uid']);

}

C::t('common_member')->update($_GET['uid'], array('password' => $password));

C::t('common_member_field_forum')->update($_GET['uid'], array('authstr' => ''));

showmessage('getpasswd_succeed', 'index.php', array(), array('login' => 1));

}

} else {

showmessage('parameters_error');

}

?>

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值