mirror of
https://github.com/GeyserMC/MCProtocolLib.git
synced 2024-12-04 12:51:09 -05:00
Removed client token from MinecraftProtocol
This commit is contained in:
parent
e1db422a34
commit
95ba884563
1 changed files with 15 additions and 8 deletions
|
@ -191,12 +191,6 @@ public class MinecraftProtocol extends PacketProtocol {
|
|||
@Getter
|
||||
private GameProfile profile = null;
|
||||
|
||||
/**
|
||||
* Authentication client token.
|
||||
*/
|
||||
@Getter
|
||||
private String clientToken = "";
|
||||
|
||||
/**
|
||||
* Authentication access token.
|
||||
*/
|
||||
|
@ -240,6 +234,7 @@ public class MinecraftProtocol extends PacketProtocol {
|
|||
* @param password Password to log in with.
|
||||
* @throws RequestException If the log in request fails.
|
||||
*/
|
||||
@Deprecated
|
||||
public MinecraftProtocol(String username, String password) throws RequestException {
|
||||
this(createAuthServiceForPasswordLogin(username, password));
|
||||
}
|
||||
|
@ -251,6 +246,7 @@ public class MinecraftProtocol extends PacketProtocol {
|
|||
* @param accessToken Access token to log in with.
|
||||
* @throws RequestException If the log in request fails.
|
||||
*/
|
||||
@Deprecated
|
||||
public MinecraftProtocol(String username, String clientToken, String accessToken) throws RequestException {
|
||||
this(createAuthServiceForTokenLogin(username, clientToken, accessToken));
|
||||
}
|
||||
|
@ -261,7 +257,7 @@ public class MinecraftProtocol extends PacketProtocol {
|
|||
* @param authService {@link AuthenticationService} to copy from.
|
||||
*/
|
||||
public MinecraftProtocol(AuthenticationService authService) {
|
||||
this(authService.getSelectedProfile(), authService.getClientToken(), authService.getAccessToken());
|
||||
this(authService.getSelectedProfile(), authService.getAccessToken());
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -270,10 +266,21 @@ public class MinecraftProtocol extends PacketProtocol {
|
|||
* @param clientToken Client token to use.
|
||||
* @param accessToken Access token to use.
|
||||
*/
|
||||
@Deprecated
|
||||
public MinecraftProtocol(GameProfile profile, String clientToken, String accessToken) {
|
||||
this(SubProtocol.LOGIN);
|
||||
this.profile = profile;
|
||||
this.clientToken = clientToken;
|
||||
this.accessToken = accessToken;
|
||||
}
|
||||
|
||||
/**
|
||||
* Constructs a new MinecraftProtocol from authentication information.
|
||||
* @param profile GameProfile to use.
|
||||
* @param accessToken Access token to use.
|
||||
*/
|
||||
public MinecraftProtocol(GameProfile profile, String accessToken) {
|
||||
this(SubProtocol.LOGIN);
|
||||
this.profile = profile;
|
||||
this.accessToken = accessToken;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue