Account Security
Phantasia supports optional two-step login and passkeys to protect your account with additional security. Turn them on to prevent unauthorized access, even if someone learns your password.
Supported Two-Step Methods
- Authenticator App (TOTP): Time-based one-time passwords from your phone or authenticator app
- Email Code: A code emailed to your verified address each time you log in
- Passkey: Approve each login with your passkey (Face ID, Touch ID, Windows Hello, your device PIN or a security key)
- One-Time Recovery Codes: Single-use backup codes in case you lose access to your authenticator
- Lost 2FA Device: Turn two-step login off yourself with your password and a code sent to your email
- Staff-Assisted Reset: Manual identity verification by game staff if needed
Enabling Two-Step Login
To enable two-step login on your account:
- Log in to the game
- Navigate to Account Options → Two-Step Login
- Choose Use Auth App (or Use Email Code) and follow the setup prompts
- Scan the QR code displayed in your client
- Or manually enter the Base32 key into your authenticator app
- Confirm a six-digit code from your authenticator to complete setup
- Store your recovery codes in a safe location
Authenticator Requirements
Your authenticator app must support:
- Time-based codes (TOTP protocol)
- Six-digit codes
- 30-second refresh period
Most modern authenticators meet these requirements, including:
- Google Authenticator
- Microsoft Authenticator
- Authy
- FreeOTP
Passkeys
A passkey lets you log in with your fingerprint, face, device PIN or a security key (Face ID, Touch ID, Windows Hello and security keys all work), with no password or code to type. To add one, go to Account Options → Two-Step Login → Passkeys and choose Add Passkey. Then choose Passkey Login on the first screen. Without your passkey device, log in with your password and your usual two-step code as always.
On the Forums
Signed in to the forums, open Security under your name (Account Security) to see everywhere your account is signed in to the forums: the device, whether it is on the same network as you, and when it was last active. Sign out any of them, or Sign out everywhere else. When the forums are signed in to from a device your account hasn't used before, a raven from The Gatekeeper tells you (and an email, if your account has a verified one); you can turn these off under Notices on your forum profile. After your two-step code on the forums you can tick Remember this device for 30 days, so that device needs only your password for a month; a new password, or Sign out everywhere else, forgets it.
Recovery Codes
Recovery codes are shown once during setup and should be stored safely. Each recovery code can be used once if you:
- Lose access to your authenticator device
- Change phones or authenticator apps
- Need to reset your account
Lost them, or used most of them? Choose New Recovery Codes under Account Options → Two-Step Login. If you've lost both your authenticator and your recovery codes, choose Can't Login? → Lost 2FA Device on the first screen to turn two-step login off with your password and a code sent to your verified email.
Important: If you lose your recovery codes and no longer have access to your authenticator, and have no verified email on your account, you may need staff-assisted recovery through manual identity verification.
Staff-Assisted Resets
If you lose access to both your authenticator and recovery codes, the game staff can assist with account recovery. This process requires:
- Proof of account ownership through our standard identity verification procedure
- Communication with game staff
A senior Wizard can reset it after confirming the account holder's identity. A successful reset:
- Immediately disables the authenticator
- Invalidates every recovery code
- Requires re-enrollment of two-step login
All reset actions are logged in the plain-text log/mfa audit file for security tracking.
Disabling Two-Step Login
To disable two-step login:
- Log in with your two-step code when prompted
- Navigate to Account Options → Two-Step Login
- Choose Disable Two-Step
Your authenticator and recovery codes will no longer be required for login.
Password Security
When you create or change your password in Phantasia:
- New passwords: Use Argon2id hashing with per-password random salt for maximum security
- Existing passwords: Automatically upgraded to Argon2id after successful login
- Legacy support: Older MD5 and SHA-256 passwords are upgraded automatically and transparently
Before upgrading your server, we recommend backing up your database. Rolling back after a password-system migration requires restoring both the database backup and the previous server binary.
Encryption Key Management
The server uses a stable 32-byte encryption key to protect two-step login data. This key must be configured in the server
environment as PHANTASIA_TOTP_KEY. If you're running a private server:
- Generate a key with:
openssl rand -hex 32 - Set the 64-character hexadecimal value as
PHANTASIA_TOTP_KEY - Keep this key private and back it up securely
- Use the same key across server restarts and instances
- Important: Losing or changing this key prevents authenticator verification for enrolled accounts. Recovery codes and manual staff resets remain available.