Skip to content

Fix handshake error with Geyser ping passthrough on Velocity#120

Open
MasonooN wants to merge 2 commits into
TCPShield:masterfrom
cPvPWorld:master
Open

Fix handshake error with Geyser ping passthrough on Velocity#120
MasonooN wants to merge 2 commits into
TCPShield:masterfrom
cPvPWorld:master

Conversation

@MasonooN

Copy link
Copy Markdown

Summary

Fixes spurious handshake/manipulation errors on Velocity when Geyser's ping
passthrough is enabled. Geyser pings arrive as a GeyserInboundConnection,
which isn't a real player connection the plugin can manipulate, but the
handler previously treated any unrecognized connection as LEGACY and tried
to disconnect/manipulate it, throwing errors.

Changes

  • Add an UNKNOWN connection type in VelocityPlayer. Connections are now
    only classified as LEGACY when they actually match
    HandshakeSessionHandler$LegacyInboundConnection; anything unrecognized
    (e.g. Geyser's ping passthrough connection) is marked UNKNOWN instead of
    being misidentified as legacy.
  • Skip UNKNOWN connections in VelocityHandshakeHandler.handleEvent(),
    they're ignored silently rather than disconnected or manipulated.
  • Add the CodeMC Maven repository to build.gradle so net.md-5:bungeecord-api
    resolves (the Spigot snapshot repo now blocks automated builds).
  • Minor: velocity-plugin.json reformatted by the build's updateVersion task.

Testing

  • Builds successfully (gradle build, JDK 21).
  • Verify on a Velocity proxy with Geyser ping passthrough enabled that the
    handshake errors no longer appear and normal Java/Bedrock connections still work.

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