/rg flag <region> require-2fa allow - Force 2FA in region
/rg flag <region> bypass-2fa allow - Skip 2FA in safe zones
/rg flag <region> 2fa-allow-movement deny - Freeze players here
Config:
Code (Text):
# Movement Settings
restrictions:
allow-movement: true # Allow movement before auth
spawn-restriction:
enabled: false # Special spawn rules
radius: 5 # Spawn protection radius
freeze-at-spawn: false # Freeze at spawn
teleport-to-spawn: false # TP on join
# Security
security:
max-attempts: 5 # Failed attempts before lockout
lockout-time: 300 # Seconds locked out
require-2fa: false # Force all players to use 2FA
kick-on-timeout: true # Kick if not authenticated
# Authentication
authentication:
timeout: 300 # Seconds before auth expires
issuer: "Your Server" # Shows in authenticator app
How It Works:
Player runs /2fa setup
Gets a map with QR code in their inventory
Scans QR with Google Authenticator (or Authy, Microsoft Authenticator)
Types /2fa verify <code> to complete setup
Map automatically disappears after successful setup
Next login: just type /2fa verify <code>
️ Security:
QR maps can't be dropped or stored in chests
Maps self-destruct when player quits
Wrong player holding map? It's destroyed
Secrets encrypted with AES-256
Blocks all actions until authenticated (damage, building, chat, etc.)
Important: First setup? The plugin creates an encryption key.
Back up your
plugins/Just2FA/data/ folder to keep player 2FA data safe during updates.