NucleoidMC / Server-Translations

MIT License
42 stars 20 forks source link

1.4.15 & 1.4.16 kicks players that send signed messages (Chat preview was enabled) #39

Closed Ampflower closed 1 year ago

Ampflower commented 1 year ago

Steps to Reproduce

Workarounds

Guesses

Taking a guess of what may be going wrong: Server Translations API is for some reason hitting chat messages in flight, and chat signing on previews may allow for Server Translations to undeterministically alter the data in flight, and leave no fallback route, causing clients to be kicked on receiving the bad packet.

Logs

Dev Environment Logs ```java Picked up JAVA_TOOL_OPTIONS: -Dawt.useSystemAAFontSettings=on -Dswing.aatext=true -Dswing.defaultlaf=com.sun.java.swing.plaf.gtk.GTKLookAndFeel -Dswing.crossplatformlaf=com.sun.java.swing.plaf.gtk.GTKLookAndFeel [00:20:31] [main/INFO] (FabricLoader/GameProvider) Loading Minecraft 1.19.2 with Fabric Loader 0.14.9 [00:20:32] [main/WARN] (FabricLoader/Resolution) Warnings were found! - Mod 'DisFabric' (disfabric) 1.5.0+tg recommends version 1.4.14+1.19-rc2 or earlier of mod 'Server Translations API' (server_translations_api), but only the wrong version is present: 1.4.16+1.19! - You should install version 1.4.14+1.19-rc2 or earlier of mod 'Server Translations API' (server_translations_api) for the optimal experience. [00:20:32] [main/INFO] (FabricLoader) Loading 41 mods: - autoconfig1u 3.3.1 - cloth-basic-math 0.6.1 - cloth-config 7.0.72 - disfabric 1.5.0+tg - fabric-api 0.60.0+1.19.2 - fabric-api-base 0.4.11+e62f51a390 - fabric-api-lookup-api-v1 1.6.9+9ff28f4090 - fabric-biome-api-v1 9.0.17+aeb40ebe90 - fabric-command-api-v2 2.1.7+0c17ea9690 - fabric-content-registries-v0 3.2.3+aeb40ebe90 - fabric-convention-tags-v1 1.1.1+7cd20a1490 - fabric-crash-report-info-v1 0.2.5+aeb40ebe90 - fabric-data-generation-api-v1 5.1.8+a680b9b490 - fabric-dimensions-v1 2.1.30+aeb40ebe90 - fabric-entity-events-v1 1.4.18+9ff28f4090 - fabric-events-interaction-v0 0.4.28+aeb40ebe90 - fabric-game-rule-api-v1 1.0.21+aeb40ebe90 - fabric-item-api-v1 1.5.7+35a03c4390 - fabric-item-groups-v0 0.3.28+aeb40ebe90 - fabric-language-kotlin 1.8.2+kotlin.1.7.10 - fabric-lifecycle-events-v1 2.1.2+aeb40ebe90 - fabric-loot-api-v2 1.1.3+83a8659290 - fabric-message-api-v1 5.0.3+176380a290 - fabric-mining-level-api-v1 2.1.14+33fbc73890 - fabric-networking-api-v1 1.2.4+5eb68ef290 - fabric-object-builder-api-v1 4.0.11+aeb40ebe90 - fabric-particles-v1 1.0.10+aeb40ebe90 - fabric-registry-sync-v0 0.9.24+aeb40ebe90 - fabric-rendering-data-attachment-v1 0.3.14+aeb40ebe90 - fabric-rendering-fluids-v1 3.0.7+aeb40ebe90 - fabric-resource-conditions-api-v1 2.0.11+e62f51a390 - fabric-resource-loader-v0 0.6.1+aeb40ebe90 - fabric-screen-handler-api-v1 1.2.13+9ff28f4090 - fabric-transfer-api-v1 2.0.11+83a8659290 - fabric-transitive-access-wideners-v1 1.3.0+42d99c3290 - fabricloader 0.14.9 - java 17 - markdown_chat 1.3.0 - minecraft 1.19.2 - packet_tweaker 0.3.0+1.18.2 - server_translations_api 1.4.16+1.19 [00:20:32] [main/INFO] (FabricLoader/Mixin) SpongePowered MIXIN Subsystem Version=0.8.5 Source=file:/home/kjp12/.gradle/caches/modules-2/files-2.1/net.fabricmc/sponge-mixin/0.11.4+mixin.0.8.5/c1dc27696aa4006e492c2485c9ccbcb26045a971/sponge-mixin-0.11.4+mixin.0.8.5.jar Service=Knot/Fabric Env=SERVER [00:20:32] [main/INFO] (FabricLoader/Mixin) Loaded Fabric development mappings for mixin remapper! [00:20:32] [main/INFO] (FabricLoader/Mixin) Compatibility level set to JAVA_16 [00:20:32] [main/INFO] (FabricLoader/Mixin) Compatibility level set to JAVA_17 [00:20:32] [main/WARN] (FileUtil) Configuration conflict: there is more than one oshi.properties file on the classpath [00:20:32] [main/WARN] (FileUtil) Configuration conflict: there is more than one oshi.architecture.properties file on the classpath [00:20:33] [main/INFO] (Minecraft) Building unoptimized datafixer [00:20:38] [main/INFO] (JDA) Login Successful! [00:20:38] [JDA MainWS-WriteThread/INFO] (WebSocketClient) Connected to WebSocket [00:20:41] [JDA MainWS-ReadThread/INFO] (JDA) Finished Loading! [00:20:41] [main/INFO] (Minecraft) Environment: authHost='https://authserver.mojang.com', accountsHost='https://api.mojang.com', sessionHost='https://sessionserver.mojang.com', servicesHost='https://api.minecraftservices.com', name='PROD' [00:20:42] [main/INFO] (Minecraft) Loaded 7 recipes [00:20:42] [main/INFO] (Minecraft) Loaded 1179 advancements [00:20:42] [ForkJoinPool.commonPool-worker-1/INFO] (ServerTranslations) Loaded 5441 translation keys [00:20:42] [main/WARN] (Minecraft) Failed to parse level-type default, defaulting to minecraft:normal [00:20:42] [main/INFO] (BiomeModificationImpl) Applied 0 biome modifications to 0 of 63 new biomes in 1.235 ms [00:20:42] [Server thread/INFO] (Minecraft) Starting minecraft server version 1.19.2 [00:20:42] [Server thread/INFO] (Minecraft) Loading properties [00:20:42] [Server thread/INFO] (Minecraft) Default game type: SURVIVAL [00:20:42] [Server thread/INFO] (Minecraft) Generating keypair [00:20:42] [Server thread/INFO] (Minecraft) Starting Minecraft server on *:25565 [00:20:42] [Server thread/INFO] (Minecraft) Using epoll channel type [00:20:42] [Server thread/INFO] (Minecraft) Preparing level "world" [00:20:42] [Server thread/INFO] (Minecraft) Preparing start region for dimension minecraft:overworld [00:20:44] [Worker-Main-2/INFO] (Minecraft) Preparing spawn area: 0% [00:20:44] [Worker-Main-18/INFO] (Minecraft) Preparing spawn area: 0% [00:20:44] [Worker-Main-18/INFO] (Minecraft) Preparing spawn area: 0% [00:20:44] [Worker-Main-12/INFO] (Minecraft) Preparing spawn area: 31% [00:20:44] [Server thread/INFO] (Minecraft) Time elapsed: 1738 ms [00:20:44] [Server thread/INFO] (Minecraft) Done (1.852s)! For help, type "help" [00:21:20] [User Authenticator #1/INFO] (Minecraft) UUID of player _KJP12 is 82fe072f-b2d9-4005-b8a6-9284195a576e [00:21:20] [Server thread/INFO] (Minecraft) _KJP12[/[0:0:0:0:0:0:0:1%0]:38094] logged in with entity id 264 at (-3.626903965708226, 100.01250241936962, -4.857000250371238) [00:21:20] [Server thread/INFO] (Minecraft) _KJP12 joined the game [00:21:26] [Server thread/INFO] (Minecraft) [Not Secure] <_KJP12> a [00:21:50] [Server thread/INFO] (Minecraft) _KJP12 lost connection: Disconnected [00:21:50] [Server thread/INFO] (Minecraft) _KJP12 left the game [00:22:18] [User Authenticator #2/INFO] (Minecraft) UUID of player _KJP12 is 82fe072f-b2d9-4005-b8a6-9284195a576e [00:22:18] [Server thread/INFO] (Minecraft) _KJP12[/[0:0:0:0:0:0:0:1%0]:35288] logged in with entity id 338 at (-3.626903965708226, 100.01250241936962, -4.857000250371238) [00:22:18] [Server thread/INFO] (Minecraft) _KJP12 joined the game [00:22:23] [Server thread/INFO] (Minecraft) _KJP12 lost connection: Received chat packet with missing or invalid signature. [00:22:23] [Server thread/INFO] (Minecraft) _KJP12 left the game ```
Client logs (unfortunately, useless) ```java [23/08/2022 00:21:54 AM] Picked up JAVA_TOOL_OPTIONS: -Dawt.useSystemAAFontSettings=on -Dswing.aatext=true -Dswing.defaultlaf=com.sun.java.swing.plaf.gtk.GTKLookAndFeel -Dswing.crossplatformlaf=com.sun.java.swing.plaf.gtk.GTKLookAndFeel [23/08/2022 00:21:55 AM] [main/INFO] Loading Minecraft 1.19.2 with Fabric Loader 0.14.9 [23/08/2022 00:21:55 AM] - ddc 0.0.0+mc.1.18.2-build.local [23/08/2022 00:21:55 AM] - drip 0.0.0+mc.1.19-build.local [23/08/2022 00:21:55 AM] - fabricloader 0.14.9 [23/08/2022 00:21:55 AM] - java 17 [23/08/2022 00:21:55 AM] [main/INFO] Loading 5 mods: - minecraft 1.19.2 [23/08/2022 00:21:55 AM] [main/INFO] SpongePowered MIXIN Subsystem Version=0.8.5 Source=file:**USERSDIR**/libraries/net/fabricmc/sponge-mixin/0.11.4+mixin.0.8.5/sponge-mixin-0.11.4+mixin.0.8.5.jar Service=Knot/Fabric Env=CLIENT [23/08/2022 00:21:55 AM] [main/INFO] Compatibility level set to JAVA_17 [23/08/2022 00:21:55 AM] Completely ignored arguments: [] [23/08/2022 00:21:55 AM] [main/WARN] Configuration conflict: there is more than one oshi.properties file on the classpath [23/08/2022 00:21:55 AM] [main/WARN] Configuration conflict: there is more than one oshi.architecture.properties file on the classpath [23/08/2022 00:21:56 AM] [main/INFO] Building optimized datafixer [23/08/2022 00:21:58 AM] [Render thread/INFO] Environment: authHost='https://authserver.mojang.com', accountsHost='https://api.mojang.com', sessionHost='https://sessionserver.mojang.com', servicesHost='https://api.minecraftservices.com', name='PROD' [23/08/2022 00:21:59 AM] [Render thread/INFO] Setting user: **MINECRAFTUSERNAME** [23/08/2022 00:21:59 AM] [Render thread/INFO] Backend library: LWJGL version 3.3.1 SNAPSHOT [23/08/2022 00:22:00 AM] [ALSOFT] (EE) Failed to set real-time priority for thread: Operation not permitted (1) [23/08/2022 00:22:01 AM] at com.sun.jna.Native.open(Native Method) [23/08/2022 00:22:01 AM] at com.sun.jna.NativeLibrary.loadLibrary(NativeLibrary.java:277) [23/08/2022 00:22:01 AM] at com.sun.jna.NativeLibrary.getInstance(NativeLibrary.java:461) [23/08/2022 00:22:01 AM] at com.sun.jna.NativeLibrary.getInstance(NativeLibrary.java:403) [23/08/2022 00:22:01 AM] at com.mojang.text2speech.NarratorLinux.(NarratorLinux.java:18) [23/08/2022 00:22:01 AM] at com.mojang.text2speech.Narrator.getNarrator(Narrator.java:21) [23/08/2022 00:22:01 AM] at net.minecraft.class_333.(class_333.java:19) [23/08/2022 00:22:01 AM] at net.minecraft.class_310.(class_310.java:637) [23/08/2022 00:22:01 AM] at net.minecraft.client.main.Main.method_44604(Main.java:205) [23/08/2022 00:22:01 AM] at net.minecraft.client.main.Main.main(Main.java:51) [23/08/2022 00:22:01 AM] at net.fabricmc.loader.impl.game.minecraft.MinecraftGameProvider.launch(MinecraftGameProvider.java:461) [23/08/2022 00:22:01 AM] at net.fabricmc.loader.impl.launch.knot.Knot.launch(Knot.java:74) [23/08/2022 00:22:01 AM] at net.fabricmc.loader.impl.launch.knot.KnotClient.main(KnotClient.java:23) [23/08/2022 00:22:01 AM] [Render thread/WARN] ERROR : Couldn't load Narrator library [23/08/2022 00:22:01 AM] [Render thread/INFO] Reloading ResourceManager: Default [23/08/2022 00:22:03 AM] [Render thread/WARN] Missing sound for event: minecraft:item.goat_horn.play [23/08/2022 00:22:03 AM] [Render thread/WARN] Missing sound for event: minecraft:entity.goat.screaming.horn_break [23/08/2022 00:22:03 AM] [ALSOFT] (EE) Failed to set real-time priority for thread: Operation not permitted (1) [23/08/2022 00:22:03 AM] [Render thread/INFO] OpenAL initialized on device JACK Default [23/08/2022 00:22:03 AM] [Render thread/INFO] Sound engine started [23/08/2022 00:22:03 AM] [Render thread/INFO] Created: 1024x1024x4 minecraft:textures/atlas/blocks.png-atlas [23/08/2022 00:22:03 AM] [Render thread/INFO] Created: 256x128x4 minecraft:textures/atlas/signs.png-atlas [23/08/2022 00:22:03 AM] [Render thread/INFO] Created: 1024x512x4 minecraft:textures/atlas/banner_patterns.png-atlas [23/08/2022 00:22:03 AM] [Render thread/INFO] Created: 1024x512x4 minecraft:textures/atlas/shield_patterns.png-atlas [23/08/2022 00:22:03 AM] [Render thread/INFO] Created: 256x256x4 minecraft:textures/atlas/chest.png-atlas [23/08/2022 00:22:03 AM] [Render thread/INFO] Created: 512x256x4 minecraft:textures/atlas/beds.png-atlas [23/08/2022 00:22:03 AM] [Render thread/INFO] Created: 512x256x4 minecraft:textures/atlas/shulker_boxes.png-atlas [23/08/2022 00:22:04 AM] [Render thread/WARN] Shader rendertype_entity_translucent_emissive could not find sampler named Sampler2 in the specified shader program. [23/08/2022 00:22:04 AM] [Render thread/INFO] Created: 512x256x0 minecraft:textures/atlas/particles.png-atlas [23/08/2022 00:22:04 AM] [Render thread/INFO] Created: 256x256x0 minecraft:textures/atlas/paintings.png-atlas [23/08/2022 00:22:04 AM] [Render thread/INFO] Created: 256x128x0 minecraft:textures/atlas/mob_effects.png-atlas [23/08/2022 00:22:06 AM] [Worker-Bootstrap-11/INFO] 4283 Datafixer optimizations took 10048 milliseconds [23/08/2022 00:22:17 AM] [Render thread/INFO] Connecting to ::, 25565 [23/08/2022 00:22:19 AM] [Render thread/INFO] Loaded 27 advancements ```
Production server with Fabric API, Server Translations & Markdown Chat ```java Picked up JAVA_TOOL_OPTIONS: -Dawt.useSystemAAFontSettings=on -Dswing.aatext=true -Dswing.defaultlaf=com.sun.java.swing.plaf.gtk.GTKLookAndFeel -Dswing.crossplatformlaf=com.sun.java.swing.plaf.gtk.GTKLookAndFeel Starting net.fabricmc.loader.impl.game.minecraft.BundlerClassPathCapture [01:00:42] [main/INFO]: Loading Minecraft 1.19.2 with Fabric Loader 0.14.9 [01:00:42] [main/INFO]: Loading 47 mods: - fabric-api 0.60.0+1.19.2 - fabric-api-base 0.4.11+e62f51a390 via fabric-api - fabric-api-lookup-api-v1 1.6.9+9ff28f4090 via fabric-api - fabric-biome-api-v1 9.0.17+aeb40ebe90 via fabric-api - fabric-command-api-v1 1.2.11+f71b366f90 via fabric-api - fabric-command-api-v2 2.1.7+0c17ea9690 via fabric-api - fabric-commands-v0 0.2.28+df3654b390 via fabric-api - fabric-containers-v0 0.1.34+df3654b390 via fabric-api - fabric-content-registries-v0 3.2.3+aeb40ebe90 via fabric-api - fabric-convention-tags-v1 1.1.1+7cd20a1490 via fabric-api - fabric-crash-report-info-v1 0.2.5+aeb40ebe90 via fabric-api - fabric-data-generation-api-v1 5.1.8+a680b9b490 via fabric-api - fabric-dimensions-v1 2.1.30+aeb40ebe90 via fabric-api - fabric-entity-events-v1 1.4.18+9ff28f4090 via fabric-api - fabric-events-interaction-v0 0.4.28+aeb40ebe90 via fabric-api - fabric-events-lifecycle-v0 0.2.28+df3654b390 via fabric-api - fabric-game-rule-api-v1 1.0.21+aeb40ebe90 via fabric-api - fabric-item-api-v1 1.5.7+35a03c4390 via fabric-api - fabric-item-groups-v0 0.3.28+aeb40ebe90 via fabric-api - fabric-lifecycle-events-v1 2.1.2+aeb40ebe90 via fabric-api - fabric-loot-api-v2 1.1.3+83a8659290 via fabric-api - fabric-loot-tables-v1 1.1.6+9e7660c690 via fabric-api - fabric-message-api-v1 5.0.3+176380a290 via fabric-api - fabric-mining-level-api-v1 2.1.14+33fbc73890 via fabric-api - fabric-networking-api-v1 1.2.4+5eb68ef290 via fabric-api - fabric-networking-v0 0.3.21+df3654b390 via fabric-api - fabric-object-builder-api-v1 4.0.11+aeb40ebe90 via fabric-api - fabric-particles-v1 1.0.10+aeb40ebe90 via fabric-api - fabric-registry-sync-v0 0.9.24+aeb40ebe90 via fabric-api - fabric-rendering-data-attachment-v1 0.3.14+aeb40ebe90 via fabric-api - fabric-rendering-fluids-v1 3.0.7+aeb40ebe90 via fabric-api - fabric-resource-conditions-api-v1 2.0.11+e62f51a390 via fabric-api - fabric-resource-loader-v0 0.6.1+aeb40ebe90 via fabric-api - fabric-screen-handler-api-v1 1.2.13+9ff28f4090 via fabric-api - fabric-transfer-api-v1 2.0.11+83a8659290 via fabric-api - fabric-transitive-access-wideners-v1 1.3.0+42d99c3290 via fabric-api - fabricloader 0.14.9 - java 17 - markdown_chat 1.3.0 - minecraft 1.19.2 - org_commonmark_commonmark 0.18.1 via markdown_chat - org_commonmark_commonmark-ext-autolink 0.18.1 via markdown_chat - org_commonmark_commonmark-ext-gfm-strikethrough 0.18.1 via markdown_chat - org_nibor_autolink_autolink 0.10.0 via markdown_chat - packet_tweaker 0.3.0+1.18.2 via server_translations - server_translations 1.4.16+1.19 - server_translations_api 1.4.16+1.19 via server_translations [01:00:42] [main/INFO]: SpongePowered MIXIN Subsystem Version=0.8.5 Source=file:/home/kjp12/Downloads/random%20servers/1.19.2/libraries/net/fabricmc/sponge-mixin/0.11.4+mixin.0.8.5/sponge-mixin-0.11.4+mixin.0.8.5.jar Service=Knot/Fabric Env=SERVER [01:00:42] [main/INFO]: Compatibility level set to JAVA_16 [01:00:42] [main/INFO]: Compatibility level set to JAVA_17 [01:00:44] [main/INFO]: Building unoptimized datafixer [01:00:45] [main/INFO]: Initializing ServerTranslations. [01:00:48] [main/INFO]: Initialized ServerTranslations. [01:00:48] [main/INFO]: Language set to en_us: English (US) [01:00:48] [main/INFO]: Environment: authHost='https://authserver.mojang.com', accountsHost='https://api.mojang.com', sessionHost='https://sessionserver.mojang.com', servicesHost='https://api.minecraftservices.com', name='PROD' [01:00:52] [main/INFO]: Loaded 7 recipes [01:00:52] [main/INFO]: Loaded 1179 advancements [01:00:52] [ForkJoinPool.commonPool-worker-1/INFO]: Loaded 5456 translation keys [01:00:52] [main/INFO]: Applied 0 biome modifications to 0 of 63 new biomes in 962.9 μs [01:00:52] [Server thread/INFO]: Starting minecraft server version 1.19.2 [01:00:52] [Server thread/INFO]: Loading properties [01:00:52] [Server thread/INFO]: Default game type: SURVIVAL [01:00:52] [Server thread/INFO]: Generating keypair [01:00:52] [Server thread/INFO]: Starting Minecraft server on *:25565 [01:00:52] [Server thread/INFO]: Using epoll channel type [01:00:53] [Server thread/INFO]: Preparing level "world" [01:00:53] [Server thread/INFO]: Preparing start region for dimension minecraft:overworld [01:00:54] [Worker-Main-6/INFO]: Preparing spawn area: 0% [01:00:54] [Worker-Main-18/INFO]: Preparing spawn area: 0% [01:00:54] [Worker-Main-18/INFO]: Preparing spawn area: 0% [01:00:54] [Worker-Main-3/INFO]: Preparing spawn area: 64% [01:00:55] [Server thread/INFO]: Time elapsed: 1677 ms [01:00:55] [Server thread/INFO]: Done (2.011s)! For help, type "help" [01:00:57] [User Authenticator #1/INFO]: UUID of player _KJP12 is 82fe072f-b2d9-4005-b8a6-9284195a576e [01:00:57] [Server thread/INFO]: _KJP12[/[0:0:0:0:0:0:0:1%0]:40196] logged in with entity id 173 at (-48.5, 71.0, 233.5) [01:00:57] [Server thread/INFO]: _KJP12 joined the game [01:01:02] [Server thread/INFO]: <_KJP12> aaaa [01:01:04] [Server thread/INFO]: _KJP12 lost connection: Received chat packet with missing or invalid signature. [01:01:04] [Server thread/INFO]: _KJP12 left the game ```