前言

开站以来,各种嗅探就没有断过,后台还是要伪装一下增加一点安全性。

修改后台地址

  • 进入网站根目录
  • 删除 install 文件夹(里面是安装用的文件,留着没什么用)
  • 重命名 admin 文件夹为一个比较难猜的名字,比如 houtai12138
  • 打开 config.inc.php ,大概在20行,把 /admin/ 改成后台文件夹的名字
    修改前:
    /** 后台路径(相对路径) */
    define('__TYPECHO_ADMIN_DIR__', '/admin/');

    修改后( houtai12138 改成新的后台地址):

    /** 后台路径(相对路径) */
    define('__TYPECHO_ADMIN_DIR__', '/houtai12138/');

设置“蜜罐”

下载地址:链接
在线演示:链接

解压后把admin文件夹放到网站根目录即可,可以按需修改。

不要忘记修改标题和最后返回主页的链接地址
不要忘记修改标题和最后返回主页的链接地址
不要忘记修改标题和最后返回主页的链接地址

输入用户名为root,密码为passw0rd时会跳到百度搜索页,其他时候会弹个窗提示密码错误

index.php:

<!DOCTYPE HTML>
<html>
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="renderer" content="webkit">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <title>登录到Chr_小屋 - Chr_小屋 - Powered by Typecho</title>
    <meta name="robots" content="noindex, nofollow">
    <link rel="stylesheet" href="css/style.css">
    <script>
        <?php
        if (isset($_POST["name"]) && isset($_POST["password"])) {
            if ($_POST["name"] == "root") {
                if ($_POST["password"] == "passw0rd") {
                    echo ("window.location.replace('https://www.baidu.com/s?wd=%e7%99%bd%e6%97%a5%e6%a2%a6%e6%80%8e%e4%b9%88%e5%81%9a');");
                } else {
                    echo ("alert('密码错误');");
                }
            } else {
                echo ("alert('用户名不存在');");
            }
        }
        ?>
    </script>
</head>
<body class="body-100">
    <div class="typecho-login-wrap">
        <div class="typecho-login">
            <h1><a href="http://typecho.org" class="i-logo">Typecho</a></h1>
            <form action="index.php" method="post" name="login" role="form">
                <p>
                    <label for="name" class="sr-only">用户名</label>
                    <input type="text" id="name" name="name" placeholder="用户名" class="text-l w-100" autofocus />
                </p>
                <p>
                    <label for="password" class="sr-only">密码</label>
                    <input type="password" id="password" name="password" class="text-l w-100" placeholder="密码" />
                </p>
                <p class="submit">
                    <button type="submit" class="btn btn-l w-100 primary">登录</button>
                </p>
                <p>
                    <label for="remember"><input type="checkbox" name="remember" class="checkbox" value="1" id="remember" />下次自动登录</label>
                </p>
            </form>
            <p class="more-link">
                <a href="https://blog.chrxw.com/">返回首页</a>
            </p>
        </div>
    </div>
</body>
</html>
最后修改:2020 年 12 月 13 日
Null