Skip to content

Validate legacy standalone login envelopes - #1554

Merged
BenCodez merged 1 commit into
masterfrom
security/validate-legacy-login-envelopes
Aug 18, 2026
Merged

Validate legacy standalone login envelopes#1554
BenCodez merged 1 commit into
masterfrom
security/validate-legacy-login-envelopes

Conversation

@BenCodez

@BenCodez BenCodez commented Aug 18, 2026

Copy link
Copy Markdown
Owner

Summary

  • Validate every legacy login against an authority independent of the envelope.
  • On player-facing proxies, require the player to be online on the claimed/current backend and require the envelope UUID to match the proxy's live UUID in online mode.
  • On dedicated voting proxies, require an exact modern presence match for the claimed player, UUID, and destination server.
  • Continue requiring standalone MQTT, Redis, MySQL, and socket envelopes to name a configured backend.
  • Preserve the existing generation-fenced extended-presence path unchanged.

Security impact

This closes the validated Codex Security finding “Legacy login envelopes bypass presence validation”:
https://chatgpt.com/codex/cloud/security/findings/67ce1cfbc0c08191842d0918ce0c9cb8?sev=critical%2Chigh

Legacy envelopes can no longer select a destination or cached-vote UUID merely by supplying those values. Player-facing proxies derive authority from their native live session. Dedicated proxies fail closed unless modern presence independently confirms the destination.

Review follow-up

The modern-source to legacy-destination race is handled without a delayed pending claim: the player-facing proxy's current route takes precedence over stale backend presence, so a legitimate transfer is accepted immediately once the proxy shows the destination. A queued spoofed destination cannot become valid merely because the old source later logs out.

Regression coverage

  • PLUGINMESSAGING uses the proxy-authoritative server and UUID.
  • PLUGINMESSAGING rejects a mismatched UUID.
  • Standalone legacy login accepts a configured server matching the live proxy route.
  • Unknown configured-server claims are rejected.
  • A modern-source to legacy-destination transfer succeeds while tracker state still names the old source.
  • A claimed server that differs from the live proxy route is rejected.
  • Player-name/UUID mismatches are rejected.
  • Dedicated proxies reject unconfirmed destinations and unknown identities, while accepting exact confirmed presence.
  • Existing extended generation-fenced presence behavior remains unchanged.

Validation

AI disclosure: This pull request was created with assistance from ChatGPT.

Copy link
Copy Markdown
Owner Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: a352ac5477

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread VotingPlugin/src/main/java/com/bencodez/votingplugin/proxy/VotingPluginProxy.java Outdated

Copy link
Copy Markdown
Owner Author

@codex address that feedback

Copy link
Copy Markdown
Owner Author

Additional security requirement for the P1 fix: do not accept a queued legacy claim solely because the old tracked source later disappears. An internal publisher could pre-seed a spoofed destination and wait for logout. On re-evaluation, require independent destination authority: on a normal player-facing proxy, the proxy's current player server and actual UUID must match the claim; on a dedicated voting proxy, require confirmed destination presence (otherwise leave the cached work pending). A competing or unconfirmed legacy claim must never become valid just from absence of the source.

@chatgpt-codex-connector

Copy link
Copy Markdown

Summary

Testing

  • git diff --check
  • git status --short --branch
  • ⚠️ mvn -B -f VotingPlugin/pom.xml -Dtest=VotingPluginProxyTest,BackendPlayerPresenceTrackerTest test (Maven Central returned HTTP 403 while resolving maven-resources-plugin:3.3.1)
  • ⚠️ mvn -o -B -f VotingPlugin/pom.xml -Dtest=VotingPluginProxyTest,BackendPlayerPresenceTrackerTest test (the required Maven plugin was not available in the local cache)

View task →

@github-actions
github-actions Bot force-pushed the security/validate-legacy-login-envelopes branch from fcbe0e6 to a807ed4 Compare August 18, 2026 00:36
AI disclosure: This commit was created with assistance from ChatGPT.
@BenCodez
BenCodez force-pushed the security/validate-legacy-login-envelopes branch from a807ed4 to 7dadd1d Compare August 18, 2026 00:38

Copy link
Copy Markdown
Owner Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Keep it up!

Reviewed commit: 7dadd1d812

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@BenCodez
BenCodez merged commit 8596eb1 into master Aug 18, 2026
4 checks passed
@BenCodez
BenCodez deleted the security/validate-legacy-login-envelopes branch August 18, 2026 00:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant