function userAudit($id, $userAudit, $expand)
 {
     if ($userAudit != 200 || CloudWind_getConfig('yundefend_shielduser') == 0) {
         return DEFEND_SUCCESS;
     }
     if (2 == CloudWind_getConfig('yundefend_shielduser')) {
         $userService = L::loadClass('UserService', 'user');
         /* @var $userService PW_UserService */
         $userService->delete($id);
     }
     if (1 == CloudWind_getConfig('yundefend_shielduser')) {
         $userService = L::loadClass('UserService', 'user');
         /* @var $userService PW_UserService */
         $userService->update($id, array('groupid' => 6));
         $userService->setUserStatus($id, PW_USERSTATUS_BANUSER, true);
         $banArray = array('uid' => $id, 'fid' => 0, 'type' => 2, 'startdate' => CloudWind_getConfig('g_timestamp'), 'days' => 0, 'admin' => '', 'reason' => '');
         $GLOBALS['db']->update("REPLACE INTO `pw_banuser` SET " . CLOUDWIND_SECURITY_SERVICE::sqlSingle($banArray), false);
     }
     return DEFEND_SUCCESS;
 }
예제 #2
0
 function _getUpdateSqlString($arr)
 {
     return CLOUDWIND_SECURITY_SERVICE::sqlSingle($arr);
 }