Platform Support
CocoAntiVPN is a true multi-platform plugin supporting all major Minecraft server and proxy software.
Supported Platformsโ
| Platform | Supported | Java Version | Notes |
|---|---|---|---|
| Bukkit | โ | Java 17+ | 1.20+ |
| Spigot | โ | Java 17+ | 1.20+ |
| Paper | โ | Java 17+ | 1.20+ (Recommended) |
| Folia | โ | Java 17+ | Full async support |
| BungeeCord | โ | Java 17+ | Proxy-level protection |
| Velocity | โ | Java 17+ | Modern proxy support |
Single Server Setupโ
For standalone servers (no proxy), install CocoAntiVPN directly on your server.
Bukkit/Spigot/Paperโ
- Download
CocoAntiVPN.jar - Place in
plugins/folder - Start server
- Edit
plugins/CocoAntiVPN/config.yml - Run
/antivpn reload
Foliaโ
CocoAntiVPN is Folia-supported with native async handling:
# plugin.yml
folia-supported: true
All VPN checks are synchronous with timeouts, making it safe for Folia's regionized multithreading.
Proxy Network Setupโ
For networks using BungeeCord or Velocity, install CocoAntiVPN on the proxy only.
Why Proxy-Level?โ
Installing on the proxy provides several advantages:
- โ Single Point of Control - One config for all servers
- โ Early Detection - Block before reaching any backend server
- โ Better Performance - Check once, not per-server
- โ Unified Bypass List - One bypass database for the network
- โ Shared Blacklist - Blocked IPs can't access any server
BungeeCord Installationโ
- Download
CocoAntiVPN.jar - Place in BungeeCord's
plugins/folder - Restart BungeeCord
- Edit
plugins/CocoAntiVPN/config.yml - Run
/antivpn reloadfrom console
Folder Structure:
bungee/
โโโ plugins/
โ โโโ CocoAntiVPN/
โ โโโ config.yml
โ โโโ data.db
Velocity Installationโ
- Download
CocoAntiVPN.jar - Place in Velocity's
plugins/folder - Restart Velocity
- Edit
plugins/cocoantivpn/config.yml - Run
/antivpn reloadfrom console
Folder Structure:
velocity/
โโโ plugins/
โ โโโ cocoantivpn/
โ โโโ config.yml
โ โโโ data.db
Velocity uses lowercase folder names (cocoantivpn), while BungeeCord uses the plugin name (CocoAntiVPN).
Architecture Detailsโ
Core Systemโ
CocoAntiVPN uses a shared core across all platforms:
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ AntiVPNCore โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโค
โ โข VPNChecker (API + Cache) โ
โ โข SmoothRateLimiter โ
โ โข DatabaseManager (SQLite) โ
โ โข PlatformAdapter (Interface) โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โฒ โฒ โฒ
โ โ โ
โโโโโโดโโโโ โโโโโโดโโโโ โโโโโโดโโโโ
โ Bukkit โ โ Bungee โ โVelocityโ
โโโโโโโโโโ โโโโโโโโโโ โโโโโโโโโโ
Platform Componentsโ
Each platform has specialized components:
| Component | Bukkit | BungeeCord | Velocity |
|---|---|---|---|
| Plugin | BukkitPlugin | BungeePlugin | VelocityPlugin |
| Command | AntiVPNCommand | BungeeCommand | VelocityCommand |
| Login Listener | AsyncPlayerPreLoginEvent | PreLoginEvent | PreLoginEvent |
| Ping Listener | BukkitPingListener | BungeePingListener | VelocityPingListener |
| Netty Injector | BukkitNettyInjector | BungeeNettyInjector | VelocityNettyInjector |
Databaseโ
SQLite database stores:
- Bypass List - Players who can skip VPN checks
- Blacklist - IPs that were detected using VPN
-- Bypass table
CREATE TABLE bypass (player TEXT PRIMARY KEY COLLATE NOCASE)
-- Blacklist table
CREATE TABLE blacklist (ip TEXT PRIMARY KEY, blocked_at INTEGER)
Performance Considerationsโ
Rate Limitingโ
The smooth rate limiter prevents API abuse:
max-logins-per-second: 7
Uses a token bucket algorithm for smooth rate limiting without bursts.
Cachingโ
VPN check results are cached with Caffeine:
cache-minutes: 10
Cache specifications:
- Maximum entries: 50,000
- Eviction: Time-based (configurable)
- High-performance Caffeine cache
API Timeoutsโ
VPN checks have built-in timeouts:
- Connect timeout: 3 seconds
- Request timeout: 2 seconds
- Total check timeout: 5 seconds
If the API is slow, players are allowed to join (fail-open).
Troubleshootingโ
Plugin Not Loadingโ
Check Java Version:
java -version
Must be Java 17 or higher.
Commands Not Workingโ
On Proxy:
- Use console or ensure permissions plugin is installed
- BungeeCord: Use LuckPerms BungeeCord version
- Velocity: Use LuckPerms Velocity version
Players Not Being Checkedโ
- Ensure
api-keyis set correctly - Check console for API errors
- Verify plugin is on proxy (for networks)
- Check if player is in bypass list
- Check if IP is timing out (5 second limit)
High Memory Usageโ
Reduce cache size by lowering cache-minutes:
cache-minutes: 5