angshumahh

I want to create a Minecraft login security plugin called "EpicProtect". The plugin should be completely lag-free, lightweight, stable, and highly optimized for low-end servers while still feeling premium and more advanced than normal authentication plugins.

The plugin must work smoothly on Minecraft servers and SMPs without causing TPS drops, freezes, memory leaks, or performance issues. Everything should be fully working, polished, and error-free.

One of the biggest priorities is a fully working Discord webhook system because many plugins have broken webhook integrations. I want EpicProtect’s webhook system to be modern, stable, and reliable.

Webhook Requirements:

  • Webhooks must always work correctly
  • Use async webhook sending only
  • Never use the main server thread for webhook requests
  • Prevent TPS loss while sending embeds
  • Add proper timeout handling
  • Add retry system if Discord API fails
  • Detect invalid webhook URLs automatically
  • Prevent Discord rate-limit problems
  • Queue webhook messages safely
  • Show clean console errors if webhook fails
  • Support rich Discord embed messages

Webhook embeds should send automatically when:

  • A player registers
  • A player logs in
  • Suspicious activity is detected (optional)

The plugin should also include:

  • Secure register/login system
  • Cracked server support
  • Smooth titles, sounds, and action bars
  • Premium-feeling UI and messages
  • Modern and clean design
  • Fast startup and reload time
  • Lightweight database/storage system
  • Configurable config.yml/messages.yml
  • Full optimization for Paper/Spigot servers
  • Support for modern Minecraft versions (especially 1.21+)
  • Clean and organized code structure
  • No console spam or unnecessary logs
  • Stable handling for high player counts

I want EpicProtect to feel modern, professional, secure, lightweight, and premium while remaining simple, optimized, and perfect for SMP servers.

Kodari AI
KodariMay 22 at 4:53 pm 19,141 (v2)

I’ll create EpicProtect - a premium, lag-free authentication plugin with a rock-solid Discord webhook system.

EpicProtect
A high-performance authentication plugin for cracked Minecraft servers with secure register/login systems, async Discord webhooks with rich embeds, and premium UI elements. Features BCrypt password encryption, SQLite/MySQL storage, player session management, and movement freezing until authentication. Optimized for low-end servers with zero TPS impact, automatic rate limiting, retry logic, and queue-based webhook delivery. Includes configurable titles, sounds, action bars, and comprehensive security features.

Architecture Plan

Core System:

  • Async webhook delivery with queue + retry + rate limiting

  • BCrypt password hashing (never plaintext)

  • Session-based authentication (ConcurrentHashMap)

  • SQLite storage with async operations

  • Player freezing until login (movement/command blocking)

  • Premium UI (titles, sounds, action bars via XSeries)

File Structure:

Plain Text
manager/ - Auth, Config, Webhook managers
storage/ - Database abstraction + SQLite implementation
model/ - Data classes
command/ - Register, Login, Admin commands
listener/ - Join, Quit, Movement event handlers
util/ - Message formatting, security utilities

Let me build this:

EpicProtect Created Successfully! βœ…

Premium authentication plugin with bulletproof Discord webhooks

What I Built:

Core System:

  • βœ… Async webhook system with queue, retry logic, and exponential backoff

  • βœ… BCrypt password hashing (strength 10)

  • βœ… Session-based authentication with timeout support

  • βœ… SQLite storage with HikariCP connection pooling

  • βœ… Player freezing (movement/commands blocked until login)

  • βœ… Premium UI with titles, sounds, and action bars (XSeries)

Webhook Features (Rock-Solid):

  • βœ… Async-only delivery (zero TPS impact)

  • βœ… Queue system (100 message capacity)

  • βœ… Retry with exponential backoff (3 attempts)

  • βœ… Rate limit detection (429 response handling)

  • βœ… Automatic URL validation

  • βœ… 5-second timeout per request

  • βœ… Rich Discord embeds with player avatars

  • βœ… Clean error logging (no console spam)

Security:

  • βœ… BCrypt hashing (never stores plaintext)

  • βœ… Brute force protection (configurable max attempts + lockout)

  • βœ… Session timeout (configurable, default 5 minutes)

  • βœ… SQL injection prevention (prepared statements)

  • βœ… Thread-safe session tracking (ConcurrentHashMap)

Performance:

  • βœ… All database operations async

  • βœ… All webhook requests async

  • βœ… Minimal event handlers

  • βœ… Auto-cleanup tasks (expired sessions/lockouts)

  • βœ… Connection pooling (HikariCP)

Commands:

  • /register <password> <confirm> - Register account

  • /login <password> - Login

  • /epicprotect reload - Admin reload

Ready for 1.21+ Paper/Spigot servers. Just add your Discord webhook URL to config.yml!

Kodari can make mistakes. Review important code before using.
Files
src
build.gradle
manifest.kod
Code
20 1,469
src/main/java/com/epicprotect/EpicProtect.java
package com.epicprotect;

import com.epicprotect.command.EpicProtectCommand;
import com.epicprotect.command.LoginCommand;
import com.epicprotect.command.RegisterCommand;
import com.epicprotect.listener.PlayerJoinListener;
import com.epicprotect.listener.PlayerMoveListener;
import com.epicprotect.listener.PlayerQuitListener;
import com.epicprotect.manager.AuthManager;
import com.epicprotect.manager.ConfigManager;
import com.epicprotect.manager.WebhookManager;
import com.epicprotect.storage.SQLiteStorage;
import com.epicprotect.storage.StorageManager;
import lombok.Getter;
import org.bukkit.Bukkit;
import org.bukkit.plugin.java.JavaPlugin;

@Getter
public class EpicProtect extends JavaPlugin {
    
    private ConfigManager configManager;
    private StorageManager storageManager;
    private AuthManager authManager;
    private WebhookManager webhookManager;
    
    @Override
    public void onEnable() {
        try {
            loadManagers();
            registerCommands();
            registerListeners();
            
            String version = getDescription().getVersion();
            getLogger().info("EpicProtect v" + version + " enabled successfully!");
        } catch (Exception e) {
            getLogger().severe("Failed to enable EpicProtect: " + e.getMessage());
            e.printStackTrace();
            Bukkit.getPluginManager().disablePlugin(this);
        }
    }
    
    @Override
    public void onDisable() {
        if (webhookManager != null) {
            webhookManager.shutdown();
        }
        
        if (storageManager != null) {
            storageManager.close();
        }
        
        if (authManager != null) {
            authManager.shutdown();
        }
        
        getLogger().info("EpicProtect disabled.");
    }
    
    private void loadManagers() {
        configManager = new ConfigManager(this);
        configManager.load();
        
        storageManager = new SQLiteStorage(this);
        storageManager.initialize();
        
        authManager = new AuthManager(this);
        
        webhookManager = new WebhookManager(this);
    }
    
    private void registerCommands() {
        getCommand("register").setExecutor(new RegisterCommand(this));
        getCommand("login").setExecutor(new LoginCommand(this));
        getCommand("epicprotect").setExecutor(new EpicProtectCommand(this));
    }
    
    private void registerListeners() {
        Bukkit.getPluginManager().registerEvents(new PlayerJoinListener(this), this);
        Bukkit.getPluginManager().registerEvents(new PlayerQuitListener(this), this);
        Bukkit.getPluginManager().registerEvents(new PlayerMoveListener(this), this);
    }
    
    public void reload() {
        configManager.load();
        getLogger().info("Configuration reloaded.");
    }
}