Mojang session auth and version check; release 0.1.0-beta3 #11

Merged
selimaj-dev merged 1 commits from mojang-session-auth into master 2026-09-25 13:29:56 +00:00
Owner

Fixes #7. Pulls in saturnclientmc/common#3 (merged, 98da429), paired with saturnclientmc/server#4.

Summary

  • common bump to 98da429, common/master's merge commit:
    • The client authenticates through Mojang's session server (auth_challenge → Mojang join → auth_verify), so the Minecraft access token only goes to Mojang.
    • It checks GET /versions before each connect: supported → connect; deprecated → warn, then connect; neither → warn, don't connect.
  • Provider implementations, in all 8 versions/*/…/SaturnProviderImpl.java:
    • getModVersion() reads Saturn's version from Fabric's mod metadata (e.g. 0.1.0-beta3+1.21.11; the client drops the +… suffix).
    • showWarning(title, message) shows a 15 s SystemToast via SystemToast.create (multi-line) on the client thread. The API is identical from 1.21.4 to 1.21.11, so every version has the same code.
  • mod_version becomes 0.1.0-beta3, the first client on the new auth. It's the server's default supported version.

Rollout

This client can't authenticate against the server until saturnclientmc/server#4 is deployed. Current 0.1.0-beta2 clients stop authenticating once #4 is deployed. So:

  1. Merge this and saturnclientmc/server#4.
  2. Build the 0.1.0-beta3 jars (./gradlew buildAll) and publish them.
  3. Deploy server#4 at the same time. The default manifest is supported: [0.1.0-beta3].

Testing

  • ./gradlew compileJava passes for all 8 versions against common at 98da429.
  • 1.21.11 with a real account (DevAuth) against a local server running server#4:
    • supported: the full Mojang flow, and the server logged Authenticated Kr4ight.
    • deprecated: warned, then connected.
    • unsupported: warned, and made no WebSocket connection or retries.
    • The toast was queued in the running game for both warnings, with no exceptions or render-thread errors.
  • Not verified: how the toast looks (macOS kept the relaunched test client stuck in glfwInit, before mod code), the offline-account path, and 1.21.4–1.21.10 at runtime (compiled only; same provider code).

🤖 Generated with Claude Code

Fixes #7. Pulls in saturnclientmc/common#3 (merged, `98da429`), paired with saturnclientmc/server#4. ## Summary - **`common` bump** to `98da429`, `common/master`'s merge commit: - The client authenticates through Mojang's session server (`auth_challenge` → Mojang `join` → `auth_verify`), so the Minecraft access token only goes to Mojang. - It checks `GET /versions` before each connect: supported → connect; deprecated → warn, then connect; neither → warn, don't connect. - **Provider implementations**, in all 8 `versions/*/…/SaturnProviderImpl.java`: - `getModVersion()` reads Saturn's version from Fabric's mod metadata (e.g. `0.1.0-beta3+1.21.11`; the client drops the `+…` suffix). - `showWarning(title, message)` shows a 15 s `SystemToast` via `SystemToast.create` (multi-line) on the client thread. The API is identical from 1.21.4 to 1.21.11, so every version has the same code. - **`mod_version` becomes `0.1.0-beta3`**, the first client on the new auth. It's the server's default supported version. ## Rollout This client can't authenticate against the server until saturnclientmc/server#4 is deployed. Current `0.1.0-beta2` clients stop authenticating once #4 is deployed. So: 1. Merge this and saturnclientmc/server#4. 2. Build the `0.1.0-beta3` jars (`./gradlew buildAll`) and publish them. 3. Deploy server#4 at the same time. The default manifest is `supported: [0.1.0-beta3]`. ## Testing - `./gradlew compileJava` passes for all 8 versions against `common` at `98da429`. - 1.21.11 with a real account (DevAuth) against a local server running server#4: - **supported:** the full Mojang flow, and the server logged `Authenticated Kr4ight`. - **deprecated:** warned, then connected. - **unsupported:** warned, and made no WebSocket connection or retries. - The toast was queued in the running game for both warnings, with no exceptions or render-thread errors. - **Not verified:** how the toast looks (macOS kept the relaunched test client stuck in `glfwInit`, before mod code), the offline-account path, and 1.21.4–1.21.10 at runtime (compiled only; same provider code). 🤖 Generated with [Claude Code](https://claude.com/claude-code)
selimaj-dev added 1 commit 2026-09-25 13:27:29 +00:00
- Implement SaturnProvider.getModVersion() (Fabric mod metadata) and
  showWarning() (15 s SystemToast) in every version
- Bump mod_version to 0.1.0-beta3, the first version on the new
  Mojang session-server authentication
- Point common at its merge commit for the new auth flow and version check

Fixes #7

Co-Authored-By: Claude Opus 5.5 <[email protected]>
selimaj-dev merged commit a97e5703c9 into master 2026-09-25 13:29:56 +00:00
selimaj-dev deleted branch mojang-session-auth 2026-09-25 13:30:00 +00:00
Sign in to join this conversation.