PermGuard is a Minecraft plugin designed to enhance server security by temporarily revoking admin permissions upon joining the server. This helps to prevent unauthorized access and potential security breaches. When an admin with elevated permissions joins the server, their permissions are removed, and they are kicked from the server. The permissions can only be restored after the admin rejoins without the elevated permissions and manually re-grants them via the console using commands like lp user playernick permission set *
.
- Automatic Permission Revoke: Revokes specified permissions when an admin joins.
- Kick on Elevated Permissions: Kicks the admin and logs the event if elevated permissions are detected.
- Manual Permission Restoration: Admins must rejoin without elevated permissions and restore them manually via console commands.
- Customizable Kick Messages: You can personalize the message shown to admins when they are kicked.
- Logging: Logs all permission revocation events to both the console and a file for auditing.
- Reload Command: Allows reloading the configuration without restarting the server.
- Lightweight and Efficient: Designed to have minimal impact on server performance.
- Shutdown Protection: If the plugin is disabled (e.g., through Plugman), the server will automatically shut down to ensure no security gaps are left open.
- Auto-Update Check: On server start, the plugin checks for updates. If a new version is available, a notification is displayed in the console.
- Brute Force Attacks: By removing permissions upon login, it prevents unauthorized access even if someone gains temporary access to an admin account.
- Account Compromise: If an admin's account is compromised, the attacker won't be able to abuse their permissions as they will be revoked upon joining.
- Session Hijacking: Mitigates the risk of session hijacking by ensuring that permissions are not persistently available during a hijacked session.
- Social Engineering: Reduces the risk of admins being tricked into giving away their permissions.
- Unknown Vulnerabilities: Helps mitigate the risks associated with unknown vulnerabilities by limiting the potential damage an attacker can do, even if they find a way to bypass other security measures.
- Port Exploitation / BungeeCord Hacks: By revoking admin permissions on entry, PermGuard minimizes the potential for attackers to exploit server ports or use BungeeCord-related hacks to gain elevated privileges.
- AuthMe Bypass: Even if an attacker finds a way to bypass AuthMe authentication, they won't gain immediate access to admin permissions as PermGuard will revoke them upon entry.
- Zero-Day Exploits: Provides a safety net against zero-day exploits by ensuring that even if a vulnerability is exploited, the attacker will not have sustained access to admin permissions.
- Shutdown Protection: Ensures that if the plugin is disabled , the server shuts down to prevent any security gaps from being exploited.
- Least Privilege Principle (ISO/IEC 15408): Ensures that users have only the minimum permissions necessary to perform their tasks, reducing the risk of privilege abuse.
- Audit Logging (ISO/IEC 27001): Provides detailed logs of all permission-related activities, facilitating compliance audits and forensic analysis.
- ISO/IEC 27001 Compliance: PermGuard helps servers adhere to information security management best practices by enforcing strict permission controls and audit logging.
- CIS Controls: Aligns with the Center for Internet Security (CIS) Controls for effective cyber defense by implementing strong access control measures.
- Secure Access Control: By requiring manual permission restoration via the console, PermGuard ensures that only authorized personnel can grant elevated privileges.
- Download: Download the latest version of PermGuard from the Releases page.
- Install: Place the
.jar
file into your server'splugins
folder. - Restart: Restart your server to load the plugin.
Edit the config.yml
file in the plugin's folder to customize settings:
# PermGuard Configuration
# List of restricted permissions
restrictedPermissions:
# Wildcard permission (Should always be first in the list if used)
- permission: "*"
# Command to execute when detected (use %player% and %permission% as placeholders)
cmd: "lp user %player% permission unset %permission%"
# Whether to log this violation
log: true
# Message to show player when kicked (use %permission% as placeholder)
kickMessage: "Your %permission% permissions have been revoked. Please rejoin and restore them via console."
# Admin group permission
- permission: "group.admin"
cmd: "lp user %player% permission unset %permission%"
log: true
kickMessage: "Your admin permissions have been revoked. Please rejoin and restore them via console."
# Example if you use op instead of * in LuckPerms
#- permission: "*"
# cmd: "deop %player%"
# log: true
# kickMessage: "Your op permissions have been revoked. Please rejoin and restore them via console."
/permguard reload
- Reloads the plugin configuration (requirespermguard.reload
permission)
- Minecraft Versions: 1.16.5 to the latest release
- Server Software: Paper (1.16.5 and newer)
Also check out my other plugins for protecting your Minecraft server:
-
LeverLock
LeverLock - a plugin to prevent rapid lever interactions, which can cause lag or be exploited for unintended game mechanics. Works in conjunction with AntiRedstoneClock-Remastered, providing comprehensive protection from redstone-based lag and exploits. -
NoMoreTNTChainCrash
NoMoreTNTChainCrash is a Minecraft plugin designed to prevent server crashes and lag caused by excessive TNT explosions. It achieves this by removing TNT before automated chain explosions can occur, while still allowing players to manually detonate TNT as desired.
If you encounter any issues or have suggestions for improving the plugin, please create an issue in this repository.
This project is licensed under the MIT License - see the LICENSE file for details.
[Alex] - [https://github.com/alex2276564]
We appreciate your contribution to the project! If you like this plugin, please give it a star on GitHub.
Contributions, issues, and feature requests are welcome! Feel free to check the issues page.
- Fork the repository.
- Create a new branch (
git checkout -b feature/YourFeature
). - Commit your changes (
git commit -m 'Add some feature'
). - Push to the branch (
git push origin feature/YourFeature
). - Open a Pull Request.
Thank you for using PermGuard! We hope it enhances the security of your Minecraft server significantly, making unauthorized access and privilege abuse a thing of the past. 🎮🔒