Pryaxis / TShock

☕️⚡️TShock provides Terraria servers with server-side characters, anti-cheat, and community management tools.
GNU General Public License v3.0
2.41k stars 377 forks source link

Rewrite SendTileRrect handling #2936

Closed punchready closed 1 year ago

punchready commented 1 year ago

The old handler had a pretty significant flaw allowing attackers to basically bypass most checks, so I went to rewrite it completely. All categories of checks have been tested successfully, but I did not perform exhaustive checks for every potential action due to lack of time, so if needed someone could do that based on the list of operations in the code. While writing this it also became apparent again that tShock does not have a way to restrict wall placement like it does with tiles, which would matter during biome conversion handling.

punchready commented 1 year ago

Yeah I wanted to avoid making the diff unreadable, which at the very least requires a different file name which would also suck. I guess I can change the class name after everyone has had a chance to check it out while the diff is still clean.

QuiCM commented 1 year ago

Couple minor Qs, but overall I'm happy to trust that this works