Clearing title sends a malformed packet to 1.17.1 Clients
bendgk opened this issue · comments
Before submitting your issue, please check the following:
- ProtocolSupport version (/ps buildinfo)
[buildtime=2021.09.22 at 17:18:06 EDT, buildhost=unknown, buildnumber=unknown, buildgit=unknown] - Server version Paper 1.17.1 build 274
When executing the command /title @a clear
or /title @a reset
any 1.17.1 client crashes (1.16.5 and below will not crash)
The error the client receives is:
IndexOutOfBoundsException: readerIndex(1) + length(1) exceeds writerIndex(1): PooledUnsafeDirectByteBuf(ridx: 1, widx: 1, cap: 1)
Upon further inspection with Wireshark (compression and encryption disabled) it seems that the issue is with the clear title packet translation. In 1.17 the packet requires an extra boolean field which appears to be missing.
What was sent: [0x01, 0x10]
// last byte is 0 if title is cleared and 1 if title is reset
What should be send: [0x02, 0x10, 0x01]