diff --git a/src/client/component/network.cpp b/src/client/component/network.cpp index a895d9b..294ce58 100644 --- a/src/client/component/network.cpp +++ b/src/client/component/network.cpp @@ -97,6 +97,11 @@ namespace network // Rather than try and let the player in, just tell them they are a duplicate player and reject connection game::NET_OutOfBandPrint(game::NS_SERVER, from, "error\nYou are already connected to the server."); } + + void* memmove_stub(void* dest, const void* src, std::size_t count) + { + return std::memmove(dest, src, std::min(count, 1262)); + } } void on(const std::string& command, const callback& callback) @@ -275,6 +280,9 @@ namespace network // ignore built in "print" oob command for security reasons utils::hook::set(0x14020A723, 0xEB); + + // patch buffer overflow + utils::hook::call(0x1403DA8A4, memmove_stub); // NET_GetDeferredClientPacket } } };