概述
本插件提供了一种无需使用白名单即可控制 Minecraft 服务器访问权限的替代方案。
该插件可安装在 Velocity 代理或后端的 Paper 服务器上。如果在 Velocity 上使用,则需要一个登录服务器。如果在 Paper 上使用,则服务端和客户端版本必须为 1.21.7+。
这不是一个添加用户注册或网络上的其他认证插件所具备的各种功能的插件。这是一个简单的插件,用于限制对服务器的访问,而无需维护白名单或使用 Discord 集成等功能。
功能
- 密码认证:玩家必须输入密码才能访问服务器。
- 一次性登录:可选地允许玩家仅进行一次身份验证。
- 插件授予绕过权限:与 LuckPerms 集成以授予绕过权限。
- 超时踢出:如果玩家在指定的超时时间内未能提供正确的密码,将被踢出服务器。
- 自定义消息:针对踢出、无密码和错误密码的自定义消息。
配置
如果在 Velocity 上使用,你需要一个服务器作为登录服务器。任何 Minecraft 服务器都可以,但我推荐使用 NanoLimbo,因为它非常轻量级,且仅用于辅助处理登录请求。你还应在权限插件的默认所有人组中将权限节点 velocity.command.server 设置为 false,否则玩家将能够绕过该插件。
该插件使用 TOML 配置文件 (config.toml) 来管理其设置。以下是部分可配置选项,文件中包含注释:
core
loginServer: 玩家被重定向进行登录的服务器。[仅限 Velocity]hubServer: 主服务器。[仅限 Velocity]serverPassword: 登录所需的密码(可以多个)。oneTimeLogin: 启用/禁用一次性登录的布尔值。默认为true。
core.bypass
bypassNode: 用于绕过登录的权限节点。pluginGrantsBypass: 启用/禁用由插件授予绕过的布尔值。默认为true。disableLoginCommandOnBypass: 如果授予了绕过权限,则禁用登录命令的布尔值。默认为true。[仅限 Velocity]bypasserLoginExitMethod: 具有绕过权限的玩家转移到登录服务器时发生的情况。选项有auto、manual、deny-entry。请查看配置文件以获取更多信息。[仅限 Velocity]
core.bypass.methods
bypassMethod: 授予绕过权限的方法。选项有user或group。bypassGroup: 如果bypassMethod为group,则将玩家添加到的组。
core.kick
kickMessage: 当玩家被踢出时显示的消息。kickTimeout: 在踢出玩家之前的超时持续时间(秒)。
messages
noPassword: 当未提供密码时显示的消息。wrongPassword: 当提供了错误的密码时显示的消息。welcomeMessage: 当有人加入登录服务器时显示的消息。如果在 Velocity 上,它将是玩家在加入登录服务器时收到的消息。如果在 Paper 上,它将是对话框登录提示的标题。接受 MiniMessage 格式。参见 PaperMC 了解信息。
misc
loginCommandGrantedToEveryone: 将登录命令授予所有人的布尔值。默认为true。[仅限 Velocity]loginCommandNode: 登录命令的权限节点。默认为loginpassword.login。[仅限 Velocity]pluginEnabled: 启用/禁用插件的布尔值。默认为true。debugMode: 启用/禁用调试日志记录的布尔值。默认为false。configVersion: 配置文件版本。请勿更改。
安装
- LuckPerms 是可选的(但推荐)
- 如果安装在 Velocity 上,则需要一个作为登录服务器的实例。
- 建议在权限插件中否定所有玩家的权限节点
velocity.command.server,否则玩家可以通过直接转移到中心服务器来绕过该插件。
Velocity
- 下载插件 JAR 文件。
- 将 JAR 文件放入 Velocity 服务器的
plugins目录中。 - 启动服务器以生成默认配置文件。
- 编辑
plugins/LoginPassword目录中的config.toml文件以满足你的需求。 - 通过向
[servers]表添加登录服务器来配置velocity.toml。如果你想让ping-passthrough = "all"正常工作,请在try = []数组中仅保留中心服务器,不要将登录服务器添加到数组中。该插件将处理将玩家重定向到登录服务器的工作。 - 重启服务器或运行
velocity reload以重新加载所有插件并应用新的velocity.toml。 - 对于
config.toml的后续更改,使用loginpassword reload应用更改。
Paper
- 下载插件 JAR 文件。
- 将 JAR 文件放入 Paper 服务器的
plugins目录中。 - 启动服务器以生成默认配置文件。
- 编辑
plugins/LoginPassword目录中的config.toml文件以满足你的需求。 - 重启服务器或使用
/loginpassword reload重新加载以应用新配置。
用法
安装并配置完成后,当玩家连接到服务器时,插件会提示他们输入密码。根据配置,玩家可能只需要进行一次身份验证。管理员可以使用 LuckPerms 或其他权限插件来管理权限以授予或撤销绕过权限,或者使用命令。
命令
-
/login <密码>在登录服务器时用于登录的命令 [仅限 Velocity] -
/loginpassword(velocity) <子命令>- 必须由拥有权限节点
loginpassword.admin的玩家或从控制台执行。 reload重新加载配置文件和绕过列表。add <uuid|玩家>将玩家添加到绕过列表中
- 必须由拥有权限节点
-
remove <uuid|player>从绕过列表中移除玩家list列出绕过列表中的 UUID
-
toggle启用或禁用该插件
我建议你查看 NanoLimbo 的 settings.yml,看看是否需要修改默认加入消息。
贡献
欢迎提交 Issue 或 Pull Request。
许可协议
本项目采用 GNU Lesser General Public License v2.1 授权。详情请参阅 LICENSE 文件。
其他
Logo 源自 twemoji,CC-BY 4.0 协议。
Overview
This plugin is an alternative way to control access to a minecraft server, without using a whitelist.
This plugin can be installed either on your Velocity proxy or backend Paper server. If used on Velocity, a login server is required. If used on Paper, the server and client versions must be 1.21.7+
This is NOT a plugin that adds user registration or any of that other stuff you'll find by other authentication plugins on the web. This is a simple plugin to restrict access to your server, without having to maintain a whitelist or using discord integrations and whatnot.
Features
- Password Authentication: Players must enter a password to access the server.
- One-Time Login: Optionally allows players to authenticate only once.
- Plugin granted bypass permissions: Integrates with LuckPerms to grant bypass permissions.
- Kick on Timeout: Players who fail to provide the correct password within a specified timeout are kicked from the server.
- Customizable Messages: Custom messages for kick, no password, and wrong password.
Configuration
If used on Velocity, you will need a server to function as a login server. Any minecraft server will do, but I recommend NanoLimbo, as it is extremely lightweight, and will only exist to facilitate login requests, you should also set the permission node velocity.command.server to false in your permission plugins default everyone group, otherwise players will be able to bypass the plugin
The plugin uses a TOML configuration file (config.toml) to manage its settings. Below are some of the configurable options, comments are included in the file:
core
loginServer: The server where players are redirected for login. [Velocity Only]hubServer: The main server. [Velocity Only]serverPassword: The password(s) required for login. Can be multiple.oneTimeLogin: Boolean to enable/disable one-time login. Default istrue.
core.bypass
bypassNode: The permission node for bypassing login.pluginGrantsBypass: Boolean to enable/disable plugin-granted bypass. Default istrue.disableLoginCommandOnBypass: Boolean to disable login command if bypass is granted. Default istrue. [Velocity Only]bypasserLoginExitMethod: What happens if a player with bypass transfers to the login server. Options areauto,manual,deny-entry. Check config file for more info. [Velocity Only]
core.bypass.methods
bypassMethod: Method to grant bypass permissions. Options areuserorgroup.bypassGroup: The group to add the player to ifbypassMethodisgroup.
core.kick
kickMessage: Message displayed when a player is kicked.kickTimeout: Timeout duration before a player is kicked, in seconds.
messages
noPassword: Message displayed when no password is provided.wrongPassword: Message displayed when the wrong password is provided.welcomeMessage: Message to be displayed when someone joins the login server. If on Velocity, it will be a message sent to the player upon joing the login server. If on Paper, it will be the title of the dialog login prompt. Accepts MiniMessage formatting. See PaperMC for info.
misc
loginCommandGrantedToEveryone: Boolean to grant the login command to everyone. Default istrue. [Velocity Only]loginCommandNode: The permission node for the login command. Default isloginpassword.login. [Velocity Only]pluginEnabled: Boolean to enable/disable the plugin. Default istrue.debugMode: Boolean to enable/disable debug logging. Default isfalse.configVersion: Version of the config file. Do not touch.
Installation
- LuckPerms is optional (but recommended)
- A server to act as a login server is required if installed on Velocity.
- It is recommended to negate the permission node
velocity.command.serverfor all players in your permissions plugin, otherwise players will be able to bypass the plugin by directly transferring to the hub server.
Velocity
- Download the plugin JAR file.
- Place the JAR file in the
pluginsdirectory of your Velocity server. - Start the server to generate the default configuration file.
- Edit the
config.tomlfile in theplugins/LoginPassworddirectory to suit your needs. - Configure
velocity.tomlby adding the login server to[servers]table. If you wantping-passthrough = "all"to work correctly, have only the hub server in thetry = []array, do not add the login server to the array. The plugin will handle redirecting players to the login server. - Restart the server or run
velocity reloadto reload all plugins and apply the newvelocity.toml. - For future changes to
config.toml, apply the changes usingloginpassword reload
Paper
- Download the plugin JAR file.
- Place the JAR file in the
pluginsdirectory of your paper server. - Start the server to generate the default configuration file.
- Edit the
config.tomlfile in theplugins/LoginPassworddirectory to suit your needs. - Restart the server or reload using
/loginpassword reloadto apply the new configuration.
Usage
Once installed and configured, the plugin will prompt players to enter a password upon connecting to the server. Depending on the configuration, players may only need to authenticate once. Administrators can manage permissions using LuckPerms or another permissions plugin to grant or revoke bypass permissions, or use the commands.
Commands
/login <password>Command used to login when at the login server [Velocity Only]/loginpassword(velocity) <subcommand>- Must be run by a player with permission node
loginpassword.adminor from the console. reloadreload the config file and bypass list.add <uuid|player>add player to the bypass listremove <uuid|player>remove player from the bypass listlistlist uuids in the bypass listtoggleenable or disable the plugin
- Must be run by a player with permission node
I encourage you to look at NanoLimbo's settings.yml as well, to see if there are any changes you want to make to the default join messages that appear.
Contributing
Open an issue or a pull request if you want.
License
This project is licensed under the GNU Lesser General Public License v2.1. See the LICENSE file for details.
Misc
Logo borrowed from twemoji, CC-BY 4.0.
下载 loginPassword
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 loginPassword
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 loginPassword
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 loginPassword
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 loginPassword
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 loginPassword
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 loginPassword
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 loginPassword
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 loginPassword
下载 loginPassword
- 支持 Folia
- 内部更改
关于这个资源的讨论、问题反馈与使用心得
还没有讨论,来发第一帖吧
你是这个资源的作者?登录后可认领此资源。
相似资源
插件
PacketEvents 是一款专为 Minecraft Java 版打造的协议库,旨在简化数据包的处理与传输。
插件
ExyliaPlugins 的库。
插件
通过对话框或铁砧界面帮助你的 Anthme
插件
重新定义服务器上的生物运输方式。使用高度可定制的口袋道具,安全地捕获、存储和释放任何实体。
插件
为基于 Spigot/Paper/Folia 的服务器添加对 Vivecraft 的支持
插件
用于绘制游戏内地图或在浏览器中随探索实时进行地图绘制的实时地图。
评论 0
登录后参与评分
还没有评论,来抢沙发吧