fix: send a command with no signable argument as chat_command - #1525
Open
u9g wants to merge 1 commit into
Open
Conversation
_signedChat chose chat_command_signed whenever the client had profile keys and a chat session, regardless of the command. The vanilla client picks the packet per command: ClientPacketListener.sendCommand sends the unsigned ServerboundChatCommandPacket when SignableCommand.of(...) .arguments() is empty, and only sends the signed packet when there is an argument to sign. Every argumentless command (/login, /list, and any command the server's command tree does not mark as a message argument) went out on the signed packet with an empty signature list. The packet now follows the signatures actually produced.
u9g
force-pushed
the
fix/unsigned-command-without-signable-args
branch
from
September 7, 2026 01:03
93043f8 to
1aca229
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Constraints on the serverbound command packet:
chat_command_signedis written only when the command produced at least one argument signature./login,/list, anything the server's command tree does not mark as a message argument) is written aschat_command, whether or not the client can sign.Vanilla reference:
ClientPacketListener.sendCommandsends the unsignedServerboundChatCommandPacketwhenSignableCommand.of(...).arguments()is empty.Tests:
/login hunter2and an argumentless/msgwritechat_commandwith an empty signature list. Both fail on master and pass with the change. They do not run in CI yet; #1526 makes this file run and #1527 fixes the pre-existing test in it.