How can I block countries from connecting

I’ll try this

Do we only allow 9987 port with this command? It may take time to allow individual teamspeak ports. How can I make country access to all ports with a single command?