24 Commits

Author SHA1 Message Date
aea0b7b016 Delete skins.js 2026-01-23 22:58:02 +01:00
11f930c3d8 Update skins.js 2026-01-23 22:56:37 +01:00
b82c06165a Update skins.js 2026-01-23 22:54:54 +01:00
48ea9f708b Expand skin upload schema and simplify texture storage
Updated the skin upload schema to accept both JSON and multipart/form-data content types, and to allow requests without a URL. Simplified the texture storage path in userService.js by removing subdirectory partitioning based on hash.
2026-01-23 22:52:00 +01:00
9469822ef9 Update [hash].js 2026-01-18 23:10:13 +01:00
99598f2b7a Update [hash].js 2026-01-18 23:06:40 +01:00
85ba96cb6f Update [hash].js 2026-01-18 23:05:59 +01:00
ac6eca3f31 Update [hash].js 2026-01-18 23:03:05 +01:00
53e58bdb30 Log header validation result in server.js
Added a console.log statement to output the result of header validation in the request handler. Also fixed a minor formatting issue in the cape texture schema file.
2026-01-18 23:00:59 +01:00
adddbadbf3 Update [hash].js 2026-01-18 22:58:43 +01:00
b15595ecb1 Update [hash].js 2026-01-18 22:54:03 +01:00
fab7066ee3 Update [hash].js 2026-01-18 21:38:39 +01:00
86490ebd2d Update [hash].js 2026-01-18 21:35:55 +01:00
0e0f176e50 Update login.js 2026-01-18 21:01:46 +01:00
86349bcf4f Add admin login and password change endpoints
Introduces POST /login and PATCH /password routes for admin authentication and password management. Adds corresponding schema validation for login and password change, enforces stricter password requirements, and updates adminService with JWT-based profile retrieval and improved token handling.
2026-01-18 19:38:24 +01:00
f1a482c58f Moved cosmectics schemas to valid location 2026-01-18 18:27:12 +01:00
c5b6f6c107 Add Discord OAuth2 account linking and login support
Introduces Discord OAuth2 integration for account association and login, including new routes for linking, unlinking, and authenticating via Discord. Adds supporting services, repositories, and schema validation for the OAuth2 flow. Refactors database schema and queries for consistency, and updates dependencies to include required OAuth2 libraries.
2026-01-11 21:03:12 +01:00
439094013d Add admin API, permissions, and player management routes
Introduces admin database tables, repository, and service for managing administrators and permissions. Adds new admin routes for banning players, managing cosmetics (capes), changing player passwords and usernames, and handling player textures. Updates user and session services to support admin actions and permission checks. Adds related schema validation for new endpoints.
2026-01-05 04:44:56 +01:00
da8ab9d488 Refactor API and schema paths, fix key usage and profile data
Renamed 'mojangapi' directories to 'api' for both routes and schemas to standardize API structure. Updated serverService to use the correct public key (profilePropertyKeys) for server metadata. Fixed sessionsService to return full skin and cape data arrays instead of just the first element.
2025-12-30 13:41:19 +01:00
3cd42103e5 Add legacy authentication and session routes
Introduces legacy endpoints for login, joinserver, and checkserver, along with their input validation schemas. Updates sessionsService with joinLegacyServer to support legacy session handling. This enables compatibility with legacy clients requiring these authentication flows.
2025-12-28 23:19:38 +01:00
5cfadfd7ac Add validation schemas and improve texture handling
Introduces zod-based validation schemas for Minecraft and Mojang API endpoints. Refactors texture route to support hash-based file serving and removes the old static texture route. Updates database schema for player properties and adds an event to clean expired certificates. Improves ValidationError formatting, adjusts skin/cape URL construction, and adds SSRF protection for skin uploads.
2025-12-28 09:02:10 +01:00
3d0f5c54af Add session join schema and enhance error serialization
Introduces a Zod schema for the Minecraft session join endpoint, validating accessToken, selectedProfile, and serverId. Updates ValidationError to support serialization via YggdrasilError and SessionError for improved error formatting.
2025-12-24 04:54:53 +01:00
2519d8078a Refactor logger usage and add userRepository module
Replaces custom logger instantiation with a shared logger import across modules and routes. Moves player property and privilege management from authRepository to a new userRepository, expanding userRepository with additional user management functions (ban, unban, preferences, privileges, bans). Updates service and route files to use userRepository where appropriate. Adds new session join route and schema, and utility for UUID formatting.
2025-12-24 04:22:43 +01:00
0b1662d8ca Initial project structure and core modules
Add environment example, update .gitignore, and switch license to AGPL v3. Introduce error handling classes, ESLint config, and main modules for database, logging, certificate management, and utility functions. Add authentication routes, schemas, and service layer for a modular REST API. Update README and set up repository structure for further development.
2025-12-23 15:59:43 +01:00