914 Commits

Author SHA1 Message Date
simoleo89 7ba0029ba8 fix(bots): preserve owner on pickup
Room owners can remove bots from their room, but picking up another user's bot must return it to the original owner instead of transferring ownership to the picker.

Tests: mvn -Dtest=BotPickupOwnershipContractTest test; mvn -DskipTests package
2026-06-14 20:51:19 +02:00
simoleo89 39c6e24097 fix(items): persist clothing grants before redeem
Redeeming clothing furniture now inserts the wardrobe grant before removing/deleting the voucher furniture. If the DB insert fails, the item remains in the room and the in-memory wardrobe is not updated.

Tests: mvn -Dtest=RedeemClothingContractTest test; mvn -DskipTests package
2026-06-14 20:51:19 +02:00
simoleo89 2b18ca2deb fix(housekeeping): allow core rank peer actions
Keep the housekeeping rank ceiling for normal staff, but treat the highest configured rank as the core rank so rank 7 can act on other rank 7 users without opening peer actions for lower staff ranks.

Tests: mvn '-Dtest=HousekeepingTargetRankGuardContractTest,HousekeepingMutationGuardTest,HousekeepingSetUserRankEventTest,HousekeepingTargetRankGuardContractTest' test
2026-06-14 20:24:51 +02:00
simoleo89 9ac50600f6 fix(housekeeping): enforce target rank ceiling 2026-06-14 20:24:50 +02:00
simoleo89 edddc551c5 fix(modtool): enforce sanction rank ceilings 2026-06-14 19:17:27 +02:00
simoleo89 1a03b8f3a9 fix(gui): require explicit dashboard autostart 2026-06-14 19:01:40 +02:00
simoleo89 d7fa02a453 fix(rcon): validate privileged payloads 2026-06-14 18:42:52 +02:00
simoleo89 994d539caf fix(rcon): rate limit remote command bursts 2026-06-14 18:31:58 +02:00
simoleo89 c6e43c6d55 fix(config): keep gui disabled by default 2026-06-14 18:18:20 +02:00
simoleo89 61972dafa4 fix(config): register gui enabled default 2026-06-14 18:15:29 +02:00
simoleo89 14a590235c fix(console): install jansi for forced ansi startup 2026-06-14 18:15:29 +02:00
simoleo89 39d21daeff chore(deps): add resilience and validation libraries 2026-06-14 17:56:20 +02:00
simoleo89 c9214bac07 fix(catalog): guard page mutations 2026-06-14 16:40:57 +02:00
simoleo89 fdcd3a7323 fix(furnieditor): validate item update payloads 2026-06-14 16:23:59 +02:00
simoleo89 7a7e38311d fix(guilds): validate badge packet parts 2026-06-14 15:51:43 +02:00
simoleo89 4359650621 fix(texts): add missing command descriptions 2026-06-14 15:51:10 +02:00
simoleo89 82c6f3f9ff fix(items): charge rentable space purchases
Deduct the computed rent cost when a user rents an InteractionRentableSpace. The previous flow only checked that the user had enough credits, then marked the space as rented without charging them, allowing free weekly rentals.

Honor ACC_INFINITE_CREDITS for staff accounts and add a contract test that keeps the charge before the rented state is assigned.
2026-06-13 18:24:16 +02:00
simoleo89 60ccc8c80b fix(items): require seed ownership for monsterplants
Reject monsterplant seed redemption when the caller does not own the placed seed. Without this guard, a user in the same room could trigger ToggleFloorItemEvent against another user's seed and have the server delete that item while creating the monsterplant pet for the attacker.

Add a contract test covering the ownership guard before createMonsterplant is reached.
2026-06-13 18:24:16 +02:00
simoleo89 eb41e3afb9 fix(rooms): scope self moderation to current room
Reject client-supplied room ids for self-moderation packets unless they match the caller's current room. This prevents users with saved rights or ownership in another room from muting, banning, or unbanning users remotely via crafted packets.

RoomUserBanEvent now also ignores invalid ban type values instead of letting valueOf throw through the message handler.

Add a contract test covering ban, mute, and unban current-room scoping.
2026-06-13 18:24:11 +02:00
simoleo89 a8e0534634 style(logging): colorize adaptive console logs
Route console log level and logger columns through custom Logback converters so terminals with ANSI support get colored severity badges and compact colored class names.

Keep the same habbo.console.style auto/ansi/plain behavior as the startup splash, including plain fallback for non-interactive output, NO_COLOR, and legacy Windows console paths.

The file appenders keep their existing verbose patterns unchanged, so debug/error log files remain plain and grep-friendly.

Cover the level formatter, logger formatter, override behavior, and Logback pattern wiring with tests.
2026-06-13 18:24:02 +02:00
simoleo89 98e366dd07 style(startup): add adaptive console colors
Add an auto-detected styled startup splash for terminals that support ANSI colors, including Windows Terminal, ANSICON, ConEmu ANSI, and common TERM-based consoles.

Keep the default and redirected-output path plain text so legacy CMD, logs, and service wrappers remain readable. The style can also be forced with -Dhabbo.console.style=ansi or disabled with -Dhabbo.console.style=plain.

Cover the styled splash, Windows Terminal detection, non-interactive fallback, and forced plain mode with startup console tests.
2026-06-13 18:24:02 +02:00
simoleo89 9edb984f56 style(startup): improve universal console layout
Keep the Morningstar ASCII logo while using a structured plain-text startup card that works in CMD, Windows Terminal, and other consoles without ANSI support.

Compact the Logback console pattern to use simple class names, clean separators, and a wider message column so startup logs do not wrap as aggressively. Simplify Infostand startup output to a one-line asset count while preserving category breakdown at DEBUG level.

Also normalize generic server start/stop messages so Game Server and RCON Server are labeled correctly instead of being glued to host:port output.
2026-06-13 18:24:02 +02:00
simoleo89 ea55258979 style(startup): use universal console splash
Replace the temporary ASCII-art banner with a structured startup splash that uses plain ASCII, aligned fields, and no ANSI or terminal-specific features. This keeps the emulator startup readable across CMD, PowerShell, Linux terminals, Docker logs, CI output, and copied log files. Add a contract test to keep the splash universal.
2026-06-13 18:24:02 +02:00
simoleo89 16d89cdb31 style(startup): customize emulator console banner
Add a clean ASCII startup banner for the emulator CMD window and use it instead of the legacy wide block logo. The new banner stays ASCII-only for Windows console compatibility and keeps the Morningstar identity visible before the startup logs.
2026-06-13 18:24:01 +02:00
simoleo89 ede7eb8284 style(startup): tidy console banner logs
Shorten the infostand background startup message into a compact asset summary and print the project/version/build details as a single ASCII startup card instead of several timestamped log lines. Add a small contract test for the compact infostand summary format.
2026-06-13 18:24:01 +02:00
simoleo89 216078f62c fix(messages): silence duplicate packet aliases
PacketNames reflects public static final packet constants and warns when two names share the same header. RequestCatalogIndexEvent is a legacy alias for the active Builders Club catalog index header, and InClientLinkComposer shares the NUX link payload/header. Keep those aliases available to existing code while removing them from the reflected packet-name set, and add a contract test so future public final packet names stay unique.
2026-06-13 18:23:57 +02:00
simoleo89 0f15371676 fix(marketplace): only pay out claimed offers after detach
MarketPlace.getCredits previously removed sold offers from memory and granted credits before knowing whether marketplace_items.user_id had been detached in the database. If that update failed, the same sold offer could be loaded as claimable again later. Make removeUser report success, keep the offer claimable on failure, and only grant credits after the database detach succeeds.
2026-06-13 18:23:37 +02:00
simoleo89 c25cb2a9b6 fix(trading): abort item exchange when persistence fails
RoomTrade previously caught SQLException during ownership updates but continued into the in-memory inventory and credit transfer path. That could desynchronize or duplicate trade results if the database batch failed while the live session still completed the exchange. Keep item owner mutations after the successful batch, return offered items on failed completion, and add a contract test that prevents SQL failures from falling through to the transfer path.
2026-06-13 18:23:33 +02:00
DuckieTM 87e1ef94f7 Merge pull request #169 from duckietm/main
Main to Dev
2026-06-12 15:56:21 +02:00
github-actions[bot] 510e0d082e 🆙 Bump version to 4.2.44 [skip ci] v4.2.44 2026-06-12 13:53:22 +00:00
DuckieTM e13c7fdbb6 Merge pull request #168 from hotellidev/multicolorfurnifix
Fix multicolor furni in furni editor
2026-06-12 15:52:23 +02:00
hotellidev 2a28fbd2e5 Fix multicolor furni in furni editor 2026-06-11 04:07:22 +03:00
github-actions[bot] cd60cba355 🆙 Bump version to 4.2.43 [skip ci] v4.2.43 2026-06-10 13:32:38 +00:00
DuckieTM e62f461962 Merge pull request #167 from duckietm/dev
㊙️ Security updates
2026-06-10 15:31:38 +02:00
duckietm 7f8c98e4f3 ㊙️ Security updates 2026-06-10 15:31:18 +02:00
github-actions[bot] d95e09e64f 🆙 Bump version to 4.2.42 [skip ci] v4.2.42 2026-06-10 13:10:40 +00:00
DuckieTM ebe0690e46 Merge pull request #166 from duckietm/dev
🆙 Fix multiheight
2026-06-10 15:09:31 +02:00
duckietm 0dda0ae0f7 🆙 Fix multiheight 2026-06-10 15:09:14 +02:00
github-actions[bot] 54ab6613f1 🆙 Bump version to 4.2.41 [skip ci] v4.2.41 2026-06-10 12:18:32 +00:00
DuckieTM 9fda766ba5 Merge pull request #165 from duckietm/dev
🆙 Fix Group Forum buy
2026-06-10 14:17:32 +02:00
duckietm 3da9325344 🆙 Fix Group Forum buy 2026-06-10 14:17:17 +02:00
github-actions[bot] 770739c256 🆙 Bump version to 4.2.40 [skip ci] v4.2.40 2026-06-10 08:16:33 +00:00
DuckieTM 3ec468993a Merge pull request #164 from duckietm/dev
Dev
2026-06-10 10:15:20 +02:00
duckietm 0e0f1cbb15 🆙 Navigator Group Filter 2026-06-10 10:14:49 +02:00
DuckieTM daeda761cd Merge pull request #163 from simoleo89/feat/security-concurrency-economy-hardening
Security, concurrency & economy hardening + dependency upgrades and modernization
2026-06-10 06:43:45 +02:00
DuckieTM 0906048a3a Merge pull request #162 from RemcoEpicnabbo/main
Handle '.' in vending_ids parsing
2026-06-10 06:43:31 +02:00
simoleo89 19cde45d3e fix(marketplace): avoid inventory desync on failed offer insert
Expose whether a marketplace offer was persisted before mutating inventory state, refuse sells whose database insert failed, and synchronize the sold timestamp into the online seller's in-memory offer when present. This keeps failed or racing marketplace operations from desynchronizing credits/items.
2026-06-09 22:02:53 +02:00
simoleo89 8161e3d7e5 fix(moderation): harden ban and modtool edge cases
Use executeUpdate with generated keys for offline ban inserts, return an empty result when an offline target cannot be loaded, and make ban commands handle empty results instead of indexing blindly. Modtool chatlog requests now guard missing users instead of dereferencing null.
2026-06-09 22:02:33 +02:00
simoleo89 5c0f2d2855 fix(session): separate forced disconnects from resume parking
Add a forced dispose path for bans, RCON disconnects, logout/account endpoints, plugin-cancelled login, duplicate login replacement, and late MAC-ban enforcement. Soft channel closes still park a session for reconnect, while security-driven closes now bypass session resume. Also null-guard client/channel disposal and cover the contract with focused tests.
2026-06-09 22:02:07 +02:00
simoleo89 d984461cc0 fix(login): don't reject login when the machine fingerprint arrives after the SSO ticket
The Nitro renderer sends the UniqueID (machine fingerprint) packet right AFTER the SSOTicket, so Habbo.connect() ran before the machineId was set and returned false on the empty machineId — silently disposing the client (WS closed with Netty's default "Bye"), so login never completed and no SecureLoginOK was sent.

- Habbo.connect(): only set machineID + run the MAC-ban check when the fingerprint is already present; never reject the login solely for a missing machineId (also drop a duplicated MAC/IP-ban block).

- MachineIDEvent: enforce the MAC ban when the fingerprint arrives after login, preserving the ban check that connect() now defers.
2026-06-09 20:50:12 +02:00