如何保护客户端的反作弊[关闭](How to secure client-side anti-che

2019-08-03 22:22发布

First,

I want to indicate that I know that any information sent from the client cannot be trusted as it can be spoofed. I am interested in methods of security through obscurity to deter 99.9% of potential cheaters and ability to detect programs that do get around the security in real time.

Some ideas I had for this included verifying file and memory check-sums of both the game it is securing and also any potential cheat apps by allowing the client-side to scan on request from the server (via TCP), both for detecting memory injection cheats and or a cheats memory footprint. Therefore the bypass hack would have to listen for all TCP information being sent to it on SSL, and then unencrypt the message by disassembling the encryption/decryption function to understand what it wants. Similarly, the client itself may be self changing and allow for it to add/remove features as needed at random (but keep by the server) so that it would be hard for a cheat to learn how to bypass it. This may be pointless?

I only find this to be moderately difficult for the more experienced, so I am open to other methods that may be hard to bypass.

I am only interested in possible implementations and not how it's impossible to have a client-side anticheat, I just want to make it really really hard.

Added minecraft and java tag, and it's for Minecraft, and I know the community is large enough that someone is likely to beat my system, but I hope through the use of constant updates and changes that I can beat them through ingenuity and perseverance.

Edit: I found this post: How to prevent cheating in our (multiplayer) games? and I am adding his suggestions so not to duplicate things, as I am looking for more ideas than the obvious (and I am not sure if his aren't bypassable)

1) Open all other processes, and hook their WriteProcessMemory functions so that they can't write to the memory in your game's process. Done right this one step will block 90% of all cheats and cheat engines.

2) Do the same thing, hooking the various mouse and keyboard emulation functions. This will prevent a lot of aimbots and other types of automation bots.

3) Hook into the VirtualProtectEx/VirtualAllocEx/etc functions in your game's own process and monitor which modules are changing protection levels or allocating new memory chunks. You have to be crafty with this in order to prevent it from being too CPU intensive when your game does a lot of allocations, but it can be done.

4) Hook into the LoadLibrary functions and monitor any DLLs that are being loaded dynamically, to prevent DLL injection.

5) Use some lightweight polymorphic encoding on your game connections.

6) Use some anti-debugging techniques to prevent debuggers from attaching to your processes. Google anti-debugging and you should be able to find lots of stuff.

7) Use a custom proprietary PE packer to prevent useful disassembly of your game.

8) Hook into your OpenGL or Direct3D functions and methods that deal with transparency and alpha blending.

9) If using shaders, checksum your shaders and the shader constant values.

10) Use additional occlusion culling techniques on player characters to prevent them from being rendered at all when the line of sight to them is blocked by other geometry. It may or may not help with your performance also, but it will prevent many wallhacks.

Answer 1:

如果你希望你的客户尊重你,游戏中,你应该尊重你的客户,实现你所看到的游戏客户端机器可以被用来存储有价值的信息。

允许客户端来扫描由所述服务器在给定的随机存储器的任何部分

客户端本身可自行更换,并允许它来添加/根据需要随意删除功能

只是要小心,你不打开一个攻击向量到客户机。 读“随机给定的记忆任何部分”听起来很吓人。 你可以把它较少受到散列的内存(不小的)块,并检查已知值左右。

让服务器发送“随机”的代码很可能将让你的软件看起来像一个病毒/僵尸网络防病毒/安全工具。 它也使客户的潜在敞开漏洞。

更新:

1)打开所有其它进程,和钩其WriteProcessMemory的功能

如果你这样做,你必须在注入的代码中的错误,你可能会破坏你的客户的整个机器。 这似乎是积极的。 什么版本的Windows,你运行的? 用什么权限? 我敢肯定,一个黑客可以安排经营他从你没有权限挂钩(如在那里你在一个正常的用户进程运行的管理进程)的过程开发。 您还需要挂钩GetProcAddress原因是显而易见的。

4)钩到的LoadLibrary功能和监视正在动态加载任何DLL,以防止DLL注射。

这一次不是因为它的声音,因为你只需要做到这一点的局部过程那样糟糕。

6)使用一些反调试技术,以防止调试器附着在你的进程。

当然值得做的(如果你有时间),但它只是一个有经验的黑客减速带。 请记住,他可以随时启动跟踪你的代码并观察或绕过反调试。 (这需要时间,但一些饼干享受这一点。)

7)使用自定义专有的PE包装,以防止你的游戏有用的拆卸。

这又是一个会得到您的防病毒软件发现。



Answer 2:

我个人不认为它是有意义的观察内存等等。 我能想象,你需要当有人实现了protocoll并提出了一些废话至极也可以让你的服务器崩溃来处理它也。

但是,你是正确的,它可以检查这通常是通过使用例如像egoshooters wallhacks骗子坏软件的内存。

恕我直言,你需要检查是否从客户端的数据看起来有效,比上作弊反应。

关于您的更新:
请不要勾所有其他progamms这是一个有点疯狂,也可以让一个根工具包或类似的东西要检测你的PROGRAMM。



Answer 3:

我完全什么这里的其他人说同意 - 其中的一些(打开所有其他进程和挂钩WriteProcessMemory的,鼠标/键盘仿真功能)是疯狂和荒谬的 - 尤其是因为用户可以通过删除权限,以你的进程绕过这一点。 这样做肯定会从某些用户激发的愤怒。

但是,如果你真的想全力以赴,做疯狂的事情像恶意软件,为什么不写哪些补受保护的标志(对于Windows Vista和更高版本)内核驱动程序或补丁OpenProcess? 后者是一种更常用的方法(在AV软件和恶意软件可见); 事先是不常见的,但仍然是可行的 - 如果你可以加载KMD,你可以修补的标志和绕过微软的签名要求。



文章来源: How to secure client-side anti-cheat [closed]