Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

If a client supports both IPv4 and IPv6 multicast announcements, the same server will show twice #5

Open
Gunni opened this issue Jan 2, 2024 · 1 comment
Labels
enhancement New feature or request

Comments

@Gunni
Copy link
Contributor

Gunni commented Jan 2, 2024

image-2024-01-02-01-45-00-535

@Gunni Gunni changed the title If a client supports both IPv4 and IPv6 multicast announcements, it will see a server listed for both If a client supports both IPv4 and IPv6 multicast announcements, the same server will show twice Jan 2, 2024
@Gunni
Copy link
Contributor Author

Gunni commented Jan 2, 2024

Proposed fix: Looking at how parseMotd and parseAddress work in LanServerPinger.java using MCP-Reborn then it should be fine to add an extra field to the current payload because the parsers just look for [MOTD] and [/MOTD], and [AD] and [/AD] and then uses string indexing to grab the string between them.

Adding a random uuid that stays the same for both IP versions will ensure that clients can trivially see they are the same server as a random uuid collision is very unlikely.

Now just adding that won't change anything, but it gives client makers/modders the ability to distinguish servers that are the same so that they can deduplicate them.

TODO: Make a client part to this mod and implement the above.

Gunni added a commit that referenced this issue Jan 2, 2024
Gunni added a commit that referenced this issue Jan 2, 2024
@Gunni Gunni added the enhancement New feature or request label Jan 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant