Remove minecraft repo

This commit is contained in:
TheMode 2021-05-15 07:57:28 +02:00
parent 3bd389fb57
commit dfad9f2947
3 changed files with 4 additions and 6 deletions

View File

@ -33,7 +33,6 @@ switch (OperatingSystem.current()) {
allprojects {
repositories {
mavenCentral()
maven { url 'https://libraries.minecraft.net' }
maven { url 'https://jitpack.io' }
maven {
name 'sponge'
@ -158,7 +157,7 @@ dependencies {
// https://search.maven.org/artifact/org.fusesource.jansi/jansi/2.3.2/jar
implementation 'org.fusesource.jansi:jansi:2.3.2'
// Guava 21.0+ required for Mixin, but Authlib imports 17.0
// Guava 21.0+ required for Mixin
api 'com.google.guava:guava:30.1-jre'
// Code modification

View File

@ -65,7 +65,7 @@ public class EncryptionResponsePacket implements ClientPreplayPacket {
InputStream gameProfileStream = new URL(
"https://sessionserver.mojang.com/session/minecraft/hasJoined?"
+ "username=" + loginUsername + "&"
+ "serverId=" + serverId
+ "serverId=" + serverId
// TODO: Add ability to add ip query tag. See: https://wiki.vg/Protocol_Encryption#Authentication
).openStream();
@ -95,11 +95,11 @@ public class EncryptionResponsePacket implements ClientPreplayPacket {
ByteArrayData.encodeByteArray(writer, verifyToken);
}
public SecretKey getSecretKey() {
private SecretKey getSecretKey() {
return MojangCrypt.decryptByteToSecretKey(MojangAuth.getKeyPair().getPrivate(), sharedSecret);
}
public byte[] getNonce() {
private byte[] getNonce() {
return MojangAuth.getKeyPair().getPrivate() == null ?
this.verifyToken : MojangCrypt.decryptUsingKey(MojangAuth.getKeyPair().getPrivate(), this.verifyToken);
}

View File

@ -27,7 +27,6 @@ public final class MojangUtils {
.softValues()
.build();
@Nullable
public static JsonObject fromUuid(@NotNull String uuid) {