RPC ratelimiting

Godot Version

4.4

Question

I am planing to build layer 7 ddos protection for my godot rpc server. Is it possible to ratelimit rpc functions? So i want to detect if user exceeds some call rate per function. If there is no build in way i ofcourse can create manually counter to each rpc function, but then how can i detect invalid rpc calls? Like packages that are calling function that does not exist or packages that don’t even follow the right protocol.

You may be able to add rate limit to rpc calls by extending MultiplayerAPIExtension and applying the rate limit in the MultiplayerAPIExtension._rpc() callback. There’s an example on how to extend it in the documentation.

I’m not sure about this part.