games647 / FastLogin

Checks if a minecraft player has a valid paid account. If so, they can skip offline authentication automatically. (premium auto login)
https://www.spigotmc.org/resources/fastlogin.14153
MIT License
494 stars 121 forks source link

FastLogin flags linked floodgate account as premium #804

Open Wapitiii opened 2 years ago

Wapitiii commented 2 years ago

What happened?

When joining with an linked floodgate account it will flag the account as premium, so it isn't possible anymore to join via the offline linked java account. It requires that /unpremium needs to be executed before leaving the server with the linked floodgate account so that it is possible again to join with the offline linked java account.

What did you expect?

Be able to login.

Steps to reproduce

  1. Link the offline java account with an floodgate bedrock account.
  2. Login with the bedrock account (via geyser proxy) that has been linked with the offline java account.
  3. Logout of the server.
  4. Try to login with the offline linked java account.
  5. See in console "[FastLogin] Requesting premium login for registered player: {accountname}"

Plugin list

AdvancedLogin*, FastLogin, floodgate, Geyser-Spigot, LuckPerms, ProtocolSupport, SkinsRestorer

Configuration file

https://www.toptal.com/developers/hastebin/dewokoviwe.yaml

Server log

https://www.toptal.com/developers/hastebin/maheqiwiqe.md

Plugin version

1.11-SNAPSHOT-fc50c99

Platform

Spigot

Relevance

Smart123s commented 2 years ago

The hastebin links don't open for me for some reason.

Also, you have enable-own-linking set to true in Floodgate's config,yml, right? https://github.com/GeyserMC/Floodgate/blob/6e2c19f1186e177857c99f7ee9153695f7828c9e/core/src/main/resources/config.yml#L38

Because link.geysermc.org is premium only, the current implementation assumes that a linked bedrock player has a premium java player attached.

Related: https://github.com/games647/FastLogin/pull/709

ApliNi commented 1 year ago

Hi, I came here because I encountered this issue https://github.com/games647/FastLogin/issues/804.

Can we fix this by ignoring bedrock accounts? Like this: https://github.com/ApliNi/FastLogin/commit/c26709127b43da4021b4b2ed47662f843d7ea0db

After this modification, the bedrock account will not be saved to the database, nor will it overwrite the Premium field of the offline account. And the automatic login can be performed normally.

Smart123s commented 1 year ago

Hi, I came here because I encountered this issue https://github.com/games647/FastLogin/issues/804.

Can we fix this by ignoring bedrock accounts? Like this: https://github.com/ApliNi/FastLogin/commit/c26709127b43da4021b4b2ed47662f843d7ea0db

After this modification, the bedrock account will not be saved to the database, nor will it overwrite the Premium field of the offline account. And the automatic login can be performed normally.

https://github.com/games647/FastLogin/pull/709 adds a new column to the database called Floodgate. In its current state, (if no Floodgate prefix is set) it'll save each player on the platform they first joined. Having the same name with auto login on both bedrock and java will not be supported as it would be insecure.