3
0
Mirror von https://github.com/PaperMC/Velocity.git synchronisiert 2024-11-16 21:10:30 +01:00

Fix decoding of unsigned messages on 1.19.1 (#814)

Dieser Commit ist enthalten in:
JNNGL 2022-08-04 02:20:25 +11:00 committet von GitHub
Ursprung 8344082b1a
Commit 62bd58d356
Es konnte kein GPG-Schlüssel zu dieser Signatur gefunden werden
GPG-Schlüssel-ID: 4AEE18F83AFDEB23

Datei anzeigen

@ -99,7 +99,8 @@ public class PlayerChat implements MinecraftPacket {
salt = Longs.toByteArray(saltLong);
signature = signatureBytes;
expiry = Instant.ofEpochMilli(expiresAt);
} else if (saltLong == 0L && signatureBytes.length == 0) {
} else if ((protocolVersion.compareTo(ProtocolVersion.MINECRAFT_1_19_1) >= 0
|| saltLong == 0L) && signatureBytes.length == 0) {
unsigned = true;
} else {
throw EncryptionUtils.INVALID_SIGNATURE;