docs: update FAQ with details on first login account and random password generation

This commit is contained in:
Soulter
2026-05-13 00:37:24 +08:00
parent 37d6159234
commit 7d72e3a9e7
2 changed files with 117 additions and 14 deletions

View File

@@ -6,17 +6,69 @@
Download `dist.zip` from the [release](https://github.com/AstrBotDevs/AstrBot/releases) page, extract it, and move it to `AstrBot/data`. If it still doesn't work, try restarting your computer (based on community feedback).
### First Login Account and Random Password
On first startup, the WebUI account is `astrbot` by default, and the default password is randomly generated (it is not a fixed hardcoded value). Check the startup logs and log in with the random initial password shown there:
```text
[00:27:40.590] [Core] [INFO] [dashboard.server:523]:
✨✨✨
AstrBot v4.24.3 WebUI is ready
➜ Local: http://localhost:6185
➜ Initial username: astrbot
➜ Initial password: UiYVpZxnW8k22IWqf0ru5pOy
➜ Change it after logging in
✨✨✨
Set dashboard.host in data/cmd_config.json to enable remote access.
```
The random initial password may be different each first startup, so please change it as soon as possible in WebUI settings after logging in.
### Forgot Dashboard Password
If you forgot your AstrBot dashboard password, you can modify the `"dashboard"` field in the `AstrBot/data/cmd_config.json` configuration file, where `"username"` is your username and `"password"` is your password encrypted with MD5.
If you forgot your AstrBot dashboard password, find the `"dashboard"` field in `AstrBot/data/cmd_config.json`, for example:
To modify your account credentials, follow these steps:
```json
"dashboard": {
"enable": true,
"username": "astrbot",
"password": "81e0c3dxxxxxxxxxxx78862e78",
"pbkdf2_password": "pbkdf2_sha256$600000$1xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
"password_storage_upgraded": true,
"password_change_required": true,
"jwt_secret": "5e1b0280bcxxxxxxxxxxxxxxxxf4a",
"host": "127.0.0.1",
"port": 6185,
"disable_access_log": true,
"ssl": {
"enable": false,
"cert_file": "",
"key_file": "",
"ca_certs": ""
}
},
```
1. Modify the `"username"` field, keeping the `""` quotation marks. If you don't want to change the username, skip this step
2. Visit the website: [Online MD5 Generator](https://www.metools.info/code/c26.html)
3. Enter your new password in the input text box
4. Select MD5 encryption (32-bit), make sure to choose the 32-bit option
5. Paste the converted string into the configuration file, keeping the `""` quotation marks
Delete the `username`, `password`, `pbkdf2_password`, `password_storage_upgraded`, `password_change_required`, and `jwt_secret` fields (with their values), then save.
The segment should look like:
```json
"dashboard": {
"enable": true,
"host": "127.0.0.1",
"port": 6185,
"disable_access_log": true,
"ssl": {
"enable": false,
"cert_file": "",
"key_file": "",
"ca_certs": ""
}
},
```
After restart, AstrBot will automatically generate a random password with the fixed username `astrbot`; check the startup logs.
## Bot Core Related

View File

@@ -6,17 +6,68 @@
在 [release](https://github.com/AstrBotDevs/AstrBot/releases) 页面下载 `dist.zip`,解压拖到 `AstrBot/data` 下。还不行请重启电脑(来自群里的反馈)
### 首次登录的默认账号和随机密码
首次启动时WebUI 的默认账号为 `astrbot`,默认密码会随机生成,不会写死为固定值。请在启动日志中查找以下内容并使用日志中的随机初始密码登录:
```text
[00:27:40.590] [Core] [INFO] [dashboard.server:523]:
✨✨✨
AstrBot v4.24.3 WebUI is ready
➜ Local: http://localhost:6185
➜ Initial username: astrbot
➜ Initial password: UiYVpZxnW8k22IWqf0ru5pOy
➜ Change it after logging in
✨✨✨
Set dashboard.host in data/cmd_config.json to enable remote access.
```
### 管理面板的密码忘记了
如果你忘记了 AstrBot 管理面板的密码,你可以在 `AstrBot/data/cmd_config.json` 配置文件中找到 `"dashboard"` 字段进行修改,其中 `"username"` 是你的用户名,`"password"` 是你的密码(经过 MD5 加密)。
如果你忘记了 AstrBot 管理面板的密码,你可以在 `AstrBot/data/cmd_config.json` 配置文件中找到 `"dashboard"` 字段,如下:
如果想要修改账号密码,你可以这样做:
```json
"dashboard": {
"enable": true,
"username": "astrbot",
"password": "81e0c3dxxxxxxxxxxx78862e78",
"pbkdf2_password": "pbkdf2_sha256$600000$1xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
"password_storage_upgraded": true,
"password_change_required": true,
"jwt_secret": "5e1b0280bcxxxxxxxxxxxxxxxxf4a",
"host": "127.0.0.1",
"port": 6185,
"disable_access_log": true,
"ssl": {
"enable": false,
"cert_file": "",
"key_file": "",
"ca_certs": ""
}
},
```
1. 修改 `"username"` 字段,注意保留 `""`;如果不想修改用户名,可以不修改
2. 进入网站:[在线 MD5 生成](https://www.metools.info/code/c26.html)
3. 在转换前文本框输入你的新密码
4. 选择 MD5 加密32 位),请确认选择 32 位选项
5. 将转换后的字符粘贴至配置文件,注意保留 `""`, 且字母使用小写
删除 `username`, `password`, `pbkdf2_password`, `password_storage_upgraded`, `password_change_required`, `jwt_secret` 五个字段(连同值一起),然后保存。上述片段修改类似如下:
```json
"dashboard": {
"enable": true,
"host": "127.0.0.1",
"port": 6185,
"disable_access_log": true,
"ssl": {
"enable": false,
"cert_file": "",
"key_file": "",
"ca_certs": ""
}
},
```
重启后 AstrBot 将会自动生成随机的密码以及固定的用户名 `astrbot`,请在日志查看。
## AstrBot 使用相关