Documentation
Everything needed to run Omni Guard end to end: the Minecraft connectors, the cloud backend, the dashboard and the API.
Overview
Omni Guard has four parts:
- Connector — a Velocity or Paper plugin. Sends logins to the backend, verifies the signed verdict, enforces it, and keeps a live channel open for policy updates.
- Backend — a Cloudflare Worker using D1 for data, KV for feed snapshots and a Durable Object per network for real-time fan-out.
- Dashboard — a React SPA served by the same Worker at
/panel. - Website — static pages served from the same Worker's asset bundle.
No part of this needs to run on your computer. Once deployed, the Worker and its storage live in Cloudflare's network and keep working while your PC is off.
Dashboard capabilities
The panel is organised around the operating workflow:
- Monitoring — network overview, live activity, explainable detections, searchable player profiles and analytics for trends, geography and infrastructure.
- Protection — network-wide blocklist, scoped allowlist, appeals, Account Shield, anti-bot controls, protection rules, country rules and emergency lockdown.
- Intelligence — provider health and capacity, cache behaviour, provider agreement policy, per-network provider switches, evasion-network matching and a detection lab that dry-runs the real engine without creating a player join.
- Network management — linked server state, team roles and audit history, Discord alerts, scoped API keys, licence seats and switching between separately isolated networks.
- Workspace — two-factor authentication, recovery codes, session revocation, configurable retention and address display, plus white-label network display name, accent colour and logo.
The owner-only Golden List sits deliberately outside the normal allowlist: protected people cannot be blocked by staff, automatic checks do not apply, and their address is replaced by a zero-information placeholder in operational views.
Requirements
- Java 21+ on the Minecraft host (required by Velocity 3.5 and Paper 1.21).
- Velocity 3.5+ or Paper 1.21.11 / 26.x.
- Node.js 22+ to build the backend, dashboard and website.
- A Cloudflare account on the free plan (for deployment).
- Optional: a domain, a SMTP/Resend key for email, a Discord application for OAuth.
Install on Velocity
- Build the connector:
cd java && ./gradlew build(Windows:gradlew.bat build). The jar appears injava/velocity/build/libs/. - Copy
Omni-Guard-Velocity-1.0.0.jarintoplugins/. - Restart the proxy. The console prints a link and a code.
- Open the link, sign in, and confirm. The server is linked; no key needs pasting.
If you prefer a key, create a plugins/omni-guard/config.yml:
key: "OG-XXXX-XXXX-XXXX-XXXX" api-url: "https://your-worker.workers.dev" server-name: "Main proxy" timeout-ms: 2500 language: "en"
Then run /omniguard key <license> or restart. The connector never opens an inbound
port; it calls the API over HTTPS and holds one outbound WebSocket.
Install on Paper
- Copy
Omni-Guard-Paper-1.0.0.jarintoplugins/. - Start once to generate
plugins/OmniGuard/omni-guard.yml. - Paste your licence, then restart or run
/omniguard key <license>.
key: "OG-XXXX-XXXX-XXXX-XXXX" api-url: "https://your-worker.workers.dev" server-name: "Survival" behind-proxy: false timeout-ms: 2500
Behind a proxy: install the connector on the proxy instead, or set
behind-proxy: true so Paper does not duplicate checks. Paper must receive the real player
address through modern forwarding; Omni Guard never trusts an address supplied by the player.
Linking & config
Linking proves that the server asking for a licence is the one you control. The connector generates a device code, prints a URL, and polls until you confirm it in the dashboard. On approval it receives:
- a server token (stored in memory, re-issued on each start);
- the pinned Ed25519 public key used to verify every verdict;
- the first signed policy snapshot.
Only the licence key and local topology settings are written to disk. Changing the signing key is reported loudly in the console and requires re-activation.
Commands
| Command | Permission | Purpose |
|---|---|---|
/omniguard status | omniguard.admin | Link, policy version and protection state |
/omniguard link | omniguard.admin | Print the pairing link again |
/omniguard key <license> | omniguard.admin | Set the licence manually |
/omniguard reload | omniguard.admin | Reload config, clear caches, resync policy |
/omniguard check <player> | omniguard.lookup | Dry-run a verdict for an online player |
/omniguard lookup <player|uuid|ip> | omniguard.lookup | Look up a player or address |
/omniguard alts <player> | omniguard.lookup | Accounts sharing a connection (no IPs shown) |
/omniguard block <player> [reason] | omniguard.manage | Network-wide block |
/omniguard unblock <player> | omniguard.manage | Lift a block |
/omniguard whitelist <player> [30m|12h|7d|perma] | omniguard.manage | Allow a player |
/omniguard stats | omniguard.admin | Local counters and cache size |
/omniguard debug | omniguard.admin | Full diagnostics dump |
Permissions
| Node | Default | Meaning |
|---|---|---|
omniguard.admin | op | Admin subcommands and alerts |
omniguard.manage | op | Block and allow in game |
omniguard.lookup | op | Lookups, checks and alts |
omniguard.alerts | op | Receive staff alerts |
omniguard.bypass | false | Skip every check |
omniguard.bypass.vpn | false | Skip VPN/proxy checks |
omniguard.bypass.proxy | false | Skip proxy checks |
omniguard.bypass.accountlimit | false | Skip the accounts-per-connection limit |
omniguard.bypass.antibot | false | Skip anti-bot throttling |
Bypass nodes are denied by default. Grant them individually; a wildcard gives away the whole product.
REST API
Create a key in Dashboard → API. Keys are shown once, stored hashed and scoped.
curl -H "Authorization: Bearer ogk_…" \ https://your-worker.workers.dev/api/v1/lookup?ip=1.1.1.1 curl -H "Authorization: Bearer ogk_…" \ "https://your-worker.workers.dev/api/v1/stats?range=7d"
| Method | Path | Scope |
|---|---|---|
| GET | /api/v1/lookup?ip= | lookup |
| GET | /api/v1/stats | stats |
| GET | /api/v1/players | players.read |
| GET | /api/v1/detections | detections.read |
| GET | /api/v1/servers | servers.read |
| GET | /api/v1/whitelist | whitelist.read |
| POST | /api/v1/whitelist | whitelist.write |
| DELETE | /api/v1/whitelist?id= | whitelist.write |
| POST | /api/v1/ban | ban.write |
| DELETE | /api/v1/ban?id= | ban.write |
| GET / POST | /api/v1/rules | rules.read / rules.write |
Requests are rate limited per key (default 120/min). Errors return
{"error":{"code","message"}} with a matching HTTP status.
Deploy the backend
The backend is a single Worker with static assets. You need a Cloudflare account; the free plan is enough for a community network.
cd backend npm install npx wrangler login # 1. Create the database and KV namespace npx wrangler d1 create afri-guard npx wrangler kv namespace create KV # 2. Put the ids from those commands into wrangler.toml # (d1_databases.database_id, kv_namespaces.id) # 3. Generate secrets and store them node ../tools/gen-keys.mjs --env npx wrangler secret put VERDICT_SIGNING_KEY npx wrangler secret put VERDICT_PUBLIC_KEY npx wrangler secret put PEPPER npx wrangler secret put TOTP_KEK # 4. Create the schema npx wrangler d1 migrations apply afri-guard --remote # 5. Deploy npm run deploy
The Worker serves the API at /api/*, the signed connector API at /v1/*, the
dashboard at /panel and the website at /. Set PUBLIC_SITE_URL in
wrangler.toml to the deployed URL so verification and reset links point to the right host.
Optional configuration
RESEND_API_KEYandEMAIL_FROM— send verification, reset and invite emails. Without them, messages are written to a development outbox (visible only whenDEV_MODE=true).DISCORD_CLIENT_ID/DISCORD_CLIENT_SECRET— Discord sign-in.IPINFO_TOKEN— IPinfo Lite country/ASN enrichment with attribution.PROXYCHECK_KEY— raises proxycheck.io from the keyless allowance to the free-account allowance.IP2LOCATION_IO_KEY,IPAPI_IS_KEY,VPNAPI_KEY,IPQUALITYSCORE_KEY,DBIP_KEY— optional keyed intelligence providers. Provider capabilities depend on plan.GETIPINTEL_CONTACT— monitored contact email for the conservative GetIPIntel dynamic-banlist mode.IPAPI_COM_ENABLED=true— explicitly enables the HTTP-only ip-api.com endpoint; only use it where its non-commercial terms apply.INTEL_PROVIDER_ATTEMPTS,INTEL_LOOKUP_TIMEOUT_MS,INTEL_PROVIDER_TIMEOUT_MS— provider failover and latency budget controls.INTEL_CACHE_TTL_SECONDS,INTEL_SECURITY_CACHE_TTL_SECONDS,INTEL_UNKNOWN_CACHE_TTL_SECONDS— adaptive intelligence-cache lifetimes.ABUSEIPDB_KEY— optional abuse reputation.PROXY_FEED_URL— newline-separated proxy addresses for public proxy detection.
Custom domain
In the Cloudflare dashboard, open Workers & Pages → your Worker → Settings → Domains &
Routes and add a custom domain. HTTPS and HSTS are applied automatically; the Worker also sets
CSP, frame and referrer policies on dashboard responses. Without a domain, the free
*.workers.dev hostname works.
Free-tier limits
These are the limits that matter for this architecture. Numbers were checked against Cloudflare's documentation in November 2026; always confirm on the pricing pages before a large launch.
| Service | Free plan | What it means here |
|---|---|---|
| Workers requests | 100,000 per day (resets 00:00 UTC) | Dashboard, API and verdict calls. A 200-player network typically uses a few thousand per day. |
| Workers static assets | Unlimited requests | Website and dashboard assets are free to serve. |
| D1 storage | 5 GB per account (10 GB per database) | Connection records dominate; retention is configurable per network (default 30 days). |
| D1 rows | 5 million read / 100,000 written per day | Each login writes a handful of rows. At ~10 rows per login this is roughly 10,000 logins per day. |
| KV | 100,000 reads / 1,000 writes per day, 1 GB | Only feed snapshots and OAuth state are stored. Writes happen when feeds refresh, not per login. |
| Durable Objects | Included on the free plan with daily request and duration limits | One object per network multiplexes dashboard and connector sockets; hibernation keeps idle cost near zero. |
| Cron triggers | Included | Feed refresh every 20 minutes, retention daily, weekly summaries. |
| Email (Resend) | 100 per day / 3,000 per month | Verification, reset and invites only. |
When you outgrow it: the Workers Paid plan removes the daily request cap and raises D1 write limits. The code does not change; only the plan does. If you expect very high login volume, enable the verdict cache (default 600 s) and keep the connector's timeout at 2–3 s.
Operations
- Health:
/api/public/statusreports API, database latency, feed age, connector check-ins and webhook delivery rate. The public status page polls it. - Diagnostics: the dashboard's server page shows link state, token count, policy
version and recent events. In game,
/omniguard debugshows the same. - Backups: export D1 with
wrangler d1 export afri-guard --remote --output backup.sql. - Key rotation: rotating a licence affects future activations only. Rotating the verdict signing key requires re-pairing or re-activating every connector.
- Feed refresh: every 20 minutes. A failed source is skipped and the previous dataset stays in place.
Data & privacy
- Player addresses are hashed with a per-network salt (HMAC-SHA256). Dashboard and alert display is masked by default; each network can explicitly choose masked, redacted or full address display. Golden List entries always use the hidden placeholder instead.
- Passwords are stretched in the browser (PBKDF2-SHA256, 310,000 iterations) and the server stores an HMAC of the verifier with a secret pepper. The plaintext password never leaves the device.
- TOTP secrets are encrypted with AES-GCM using a Worker secret.
- Retention defaults to 30 days and is enforced by a daily job; it is configurable per network between 1 and 365 days.
- Discord alerts contain the player, country, reason and the address in the network's configured display mode — never tokens or keys.
Troubleshooting
The console says “not linked”
Open the printed link and confirm the code. If it expired, run /omniguard link. Check that
api-url points at your deployment and that the host can reach it over HTTPS.
“Protection: DEGRADED”
The backend is unreachable or rejecting responses. Known blocks and the local rate limit still apply.
Run /omniguard debug; a signature error means the pinned key no longer matches and the
server should be re-activated.
Players behind a proxy look like 127.0.0.1
The connector is on the backend server instead of the proxy, or forwarding is not configured. Install
the Velocity build on the proxy, or set behind-proxy: true and enable modern forwarding.
Bedrock players are blocked
Check the username prefix rule: Floodgate names start with a dot by default. The dashboard's name validator has a separate Bedrock prefix setting.
Emails are not arriving
Without RESEND_API_KEY nothing is sent. In development, read the outbox at
/api/dev/outbox (only when DEV_MODE=true).