Discuz!官方免费开源建站系统

 找回密码
 立即注册

QQ登录

只需一步,快速开始

搜索

修复论坛首页,恢复正常访问的解决方法

[复制链接]
monkeye 发表于 2009-1-8 13:13:04 | 显示全部楼层 |阅读模式
此事件并非由于 discuz 程序自身的漏洞造成,所以您无需进行任何修补。

关于此事情的说明,请见
https://discuz.dismall.com/thread-1184256-1-1.html

本帖附件提供的文件,可以解决您遇到的问题,如果您的论坛首页出现相关字样才需要修复,否则不需要。

修复方法1:

如您的论坛出现“Hacked by ring04h, just for fun!”

请下载本贴附件,上传到论坛根目录执行即可。


=====================================================


方法2:

直接访问 admincp.php 程序,进入论坛后台以后

进入全局--优化设置--搜索引擎优化,删除掉相关代码即可

本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有账号?立即注册

x

评分

6

查看全部评分

兵之善 发表于 2009-1-8 13:14:32 | 显示全部楼层
头部信息里撤除的已经好了,还需要这个吗?
回复

使用道具 举报

long3353416 发表于 2009-1-8 13:14:51 | 显示全部楼层
提示: 作者被禁止或删除 内容自动屏蔽
回复

使用道具 举报

爱德华八世 发表于 2009-1-8 13:14:59 | 显示全部楼层
ding~~~~~~~~~~~~~~
回复

使用道具 举报

和山论坛 发表于 2009-1-8 13:15:03 | 显示全部楼层
本帖最后由 和山论坛 于 2009-1-8 13:18 编辑

补丁出来了~~~~~~~~~~~~~~~




  1. <?php
  2. define('IN_DISCUZ', TRUE);
  3. define('DISCUZ_ROOT', './');
  4. $PHP_SELF = htmlspecialchars($_SERVER['PHP_SELF'] ? $_SERVER['PHP_SELF'] : $_SERVER['SCRIPT_NAME']);
  5. $boardurl = htmlspecialchars('http://'.$_SERVER['HTTP_HOST'].preg_replace("/\/+(api|archiver|wap)?\/*$/i", '', substr($PHP_SELF, 0, strrpos($PHP_SELF, '/'))).'/');
  6. require_once DISCUZ_ROOT.'./config.inc.php';
  7. require_once DISCUZ_ROOT.'./include/db_mysql.class.php';
  8. $db = new dbstuff;
  9. $db->connect($dbhost, $dbuser, $dbpw, $dbname, $pconnect, true, $dbcharset);
  10. $db->query("UPDATE {$tablepre}settings SET value='' WHERE variable='seohead'");
  11. dir_clear('./forumdata/cache');
  12. function dir_clear($dir) {
  13. if($directory = dir($dir)) {
  14.   while($entry = $directory->read()) {
  15.    $filename = $dir.'/'.$entry;
  16.    if(is_file($filename)) {
  17.     @unlink($filename);
  18.    }
  19.   }
  20.   @touch($dir.'/index.htm');
  21.   $directory->close();
  22. }
  23. }
  24. header('location: '.$boardurl);


复制代码



猴子啊

这个治标不治本呢。。。。。

漏洞在哪里呢?
回复

使用道具 举报

dongzu8 发表于 2009-1-8 13:15:06 | 显示全部楼层
本帖最后由 dongzu8 于 2009-1-8 14:37 编辑

沙发,很紧张,但是呢我那米问题,关注热点,能带来ip
回复

使用道具 举报

sonman 发表于 2009-1-8 13:15:13 | 显示全部楼层
同楼上问
回复

使用道具 举报

万联数据 发表于 2009-1-8 13:15:15 | 显示全部楼层
留下了,这个有用,呵呵
回复

使用道具 举报

爱德华八世 发表于 2009-1-8 13:15:21 | 显示全部楼层
头部信息里撤除的已经好了,还需要这个吗?
兵之善 发表于 2009-1-8 13:14



同问
回复

使用道具 举报

232425005 发表于 2009-1-8 13:15:30 | 显示全部楼层
手动去掉还需要吗?
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

手机版|小黑屋|Discuz! 官方站 ( 皖ICP备16010102号 )star

GMT+8, 2024-5-1 08:27 , Processed in 0.106262 second(s), 20 queries , Gzip On.

Powered by Discuz! X3.4

Copyright © 2001-2023, Tencent Cloud.

快速回复 返回顶部 返回列表