mojira.dev
MC-43984

Normal players can use player selectors

With enough players online, entering a command like the following kicks all players because @a gets expanded to a list of all online players.

/me @a @a @a @a @a @a @a @a @a @a @a @a ...

This is what it looks like from the logfile.

derp lost connection: TranslatableComponent{key='disconnect.genericReason', args=[Internal Exception: io.netty.handler.codec.EncoderException: java.io.IOException: String too big (was 33145 bytes encoded, max 32767)

At this point my server has become unplayable with more than 10 people online. This issue is well-known and spreading. I expect waves of players doing this to every vanilla server.

Linked issues

MC-40319 @a, @p and similar modifiers can be used in /tell command Resolved MC-44000 io.netty.handler.codec.EncoderException: java.io.IOException: String too big (was 61545 bytes encoded, max 32767) Resolved MC-44007 Spammers can crash any Vanilla server with a few keystroke from chat window Resolved MC-44102 Normal players can use @a, @p, @r selectors Resolved MC-44157 Command-Modifiers and conditions like @p or r= can be abused Resolved

Comments 13

Please fix this soon. Running an open vanilla server is impossible with this bug. Fixing it should be as simple as disabling selectors in /me.

I've heard that MC-44000 may be a duplicate of this but I don't have access and cannot confirm this myself.

Setting that ticket to public since most of the duplicates are public too.

Tested in 14w11b. Can still use /tell @a without being op. Using various selectors, it is possible to locate other players, for example:

@a[x=0,z=0,r=1000]
@p[x=1000,z=-2000,r=100]

Using trigonometry, a player can obtain the exact cords of a player in 3 whispers.

Reopened because of /tell

3 more comments

Issue persists in 14w21b. It's much worse now because non-op users can now cause the server to halt:

/tell @a[r=2000000,c=1] test
/tell @a[r=20000000,c=1] test
/tell @a[r=200000000,c=1] test

The higher r= is, the more likely the server will completely halt. Why are selectors even allowed by non-op players in the first place?

Still present in 14w27b. There is another way to track players by not sending a whisper and not including a message. It will output an error for every player that is in the area you are whispering. The commands used are: /w @a[x=0,z=0,r=10000] and /w @a[name=Player,x=0,z=0,r=10000]

On my Realms I did /say @e and it gave me the error:
internal Exception: io.netty.handler.codec.DecoderException: java.lang.IndexOutOfBoundsException: readerIndex(1) + length(1) exceeds writerIndex(1): UnpooledHeapByteBuf(ridx: 1, widx: 1, cap: 1)

Re-resolving as fixed (in the version it was originally fixed in) in favor of creating a clone issue, MC-121739.

Rebecca König

Nathan Adams

Unconfirmed

chat, kick, selector

Minecraft 1.7.4, Minecraft 14w02a, Minecraft 14w02c, Minecraft 14w03a, Minecraft 1.7.5, Minecraft 14w11b, Minecraft 14w21b, Minecraft 14w27b

Minecraft 14w04a, Minecraft 14w28a

Retrieved