Azuriom CMS Authentication

Overview

Azuriom is an open-source CMS designed for Minecraft servers, providing:

  • User authentication and management

  • Two-factor authentication (2FA/TOTP)

  • Role-based permissions

  • Server economy integration (credits/money)

  • Custom launcher authentication

The AzuriomAuth provider integrates with the Azuriom REST API for secure server authentication.

Prerequisites

Azuriom Instance

You need:

  • A running Azuriom instance (https://azuriom.com)

  • Base URL of the instance (e.g., https://your-server.com)

  • User account created on the Azuriom website

API Endpoints

The authenticator uses these endpoints:

  • POST /api/auth/authenticate - Login

  • POST /api/auth/verify - Token verification

  • POST /api/auth/logout - Logout

Quick Start

Authentication Flow

Basic Authentication

spinner

With Two-Factor Authentication

spinner

Two-Factor Authentication

Handling 2FA

Interactive 2FA Flow

Token Verification

Verify if a token is still valid:

Logout

Invalidate an access token:

Error Handling

UserProfile Output

Example Output

Role Management

Server Economy Integration

Event System Integration

API Error Responses

Success Response

Error Response

Error Reasons:

  • invalid_credentialsAuthError::InvalidCredentials

  • requires_2faAuthError::TwoFactorRequired

  • invalid_2faAuthError::Invalid2FACode

  • email_not_verifiedAuthError::EmailNotVerified

  • bannedAuthError::AccountBanned

Best Practices

Secure Credential Storage

Token Caching

Retry Logic

Testing

Troubleshooting

Issue: Connection refused

Cause: Azuriom instance is not reachable

Solution:

Issue: Invalid response format

Cause: Azuriom API version mismatch

Solution: Ensure Azuriom is up-to-date with latest API version

Issue: 2FA code always invalid

Cause: Time synchronization issue

Solution: Check system clock is synchronized with NTP server

Performance

Typical authentication duration: 100-500ms

Breakdown:

  • Network roundtrip: 50-200ms

  • Server-side validation: 20-100ms

  • Database lookup: 10-50ms

  • Response parsing: 1-5ms

With 2FA: 200-1000ms (two requests)

Security Considerations

  • HTTPS Required: Always use HTTPS for Azuriom URLs

  • Password Hashing: Passwords are hashed server-side (bcrypt)

  • 2FA Recommended: Enable 2FA for enhanced security

  • Token Expiration: Tokens expire after 24 hours (configurable server-side)

  • Rate Limiting: Azuriom may rate-limit authentication requests

Last updated