preclassify packets as safe

This commit is contained in:
Manuel Frohn
2026-05-15 00:48:45 +02:00
parent 57c21122e6
commit 42808f40c0
@@ -383,17 +383,6 @@ public class TechHider {
// 7.1.48 Update Light: lighting can reveal hidden blocks/operations.
processors.put(ClientboundLightUpdatePacket.class, tossPacket);
// --- Player packets ---
// 7.1.67 Combat Death: entity/player ids and death message context.
processors.put(ClientboundPlayerCombatKillPacket.class, tossPacket);
// 7.1.68 Player Info Remove: other-player identity/state.
processors.put(ClientboundPlayerInfoRemovePacket.class, tossPacket);
// 7.1.69 Player Info Update: other-player identity/state.
processors.put(ClientboundPlayerInfoUpdatePacket.class, tossPacket);
// 7.1.70 Look At: target position/entity.
processors.put(ClientboundPlayerLookAtPacket.class, tossPacket);
// --- Others ---
// 7.1.37 Explosion: position, affected blocks, and knockback can reveal TNT/tech.
@@ -408,23 +397,34 @@ public class TechHider {
processors.put(ClientboundMoveVehiclePacket.class, tossPacket);
// 7.1.59 Open Sign Editor: block position.
processors.put(ClientboundOpenSignEditorPacket.class, tossPacket);
// 7.1.92 Set Camera: entity id.
processors.put(ClientboundSetCameraPacket.class, tossPacket);
// 7.1.108 Update Teams: player/team membership can be used as intel.
processors.put(ClientboundSetPlayerTeamPacket.class, tossPacket);
// 7.1.123 Pickup Item: item/entity ids and pickup activity.
processors.put(ClientboundTakeItemEntityPacket.class, tossPacket);
// 7.1.124 Synchronize Vehicle Position: entity/vehicle position.
processors.put(ClientboundEntityPositionSyncPacket.class, tossPacket);
// 7.1.133 Update Tags (play): registry/tag data can be added back after review.
processors.put(ClientboundUpdateTagsPacket.class, tossPacket);
// 7.1.134 Projectile Power: projectile/entity signal.
processors.put(ClientboundProjectilePowerPacket.class, tossPacket);
// 7.1.137 Waypoint: world/entity tracking signal.
processors.put(ClientboundTrackedWaypointPacket.class, tossPacket);
// --- Safe; should be added to bypass ---
// 7.1.133 Update Tags (play): registry/tag data can be added back after review.
processors.put(ClientboundUpdateTagsPacket.class, tossPacket);
// 7.1.70 Look At: target position/entity.
processors.put(ClientboundPlayerLookAtPacket.class, tossPacket);
// 7.1.68 Player Info Remove: other-player identity/state.
processors.put(ClientboundPlayerInfoRemovePacket.class, tossPacket);
// 7.1.69 Player Info Update: other-player identity/state.
processors.put(ClientboundPlayerInfoUpdatePacket.class, tossPacket);
// --- Safe enough (not enough relevant data) to leak critical information; review and add to bypass ---
// 7.1.123 Pickup Item: item/entity ids and pickup activity.
processors.put(ClientboundTakeItemEntityPacket.class, tossPacket);
// 7.1.92 Set Camera: entity id.
processors.put(ClientboundSetCameraPacket.class, tossPacket);
// 7.1.108 Update Teams: player/team membership can be used as intel.
processors.put(ClientboundSetPlayerTeamPacket.class, tossPacket);
// 7.1.67 Combat Death: entity/player ids and death message context.
processors.put(ClientboundPlayerCombatKillPacket.class, tossPacket);
this.packetProcessors = processors;
this.interceptor = new TinyProtocol(plugin) {