ppy / osu-server-spectator

osu! spectator server
MIT License
64 stars 13 forks source link

Client versions need to be checked on connect #52

Open peppy opened 3 years ago

peppy commented 3 years ago

We need a way to stop older clients from connecting. This is already possible on score token retrieval (via checks osu-web side) but we don't have a flow in place for this server.

See https://github.com/ppy/osu/issues/11686 for an example of an issue caused by old versions connecting to the server.

bdach commented 6 months ago

Rough sketch of server-side changes: https://github.com/ppy/osu-server-spectator/compare/master...bdach:osu-server-spectator:client-version-check-wip?expand=1

Needs further client-side consideration though.

smoogipoo commented 6 months ago

Can you explain what client-side considerations are needed?

bdach commented 6 months ago

Well the issue there is how the client is supposed to respond to an invalid version being detected by the spectator server. What the spectator server will do is obvious - it will drop the connections from an old client and/or not honor any requests made by it. But the client?

I'd have to change the disconnection flow used currently to convey the reason for disconnection, then handle that on the client side properly - which is also triply annoying because we have three hubs and every single one of them will receive a disconnect event near-simultaneously so I'd have to do some client-side debouncing etc etc.