A more general question How do bots communicate in the Zeus botnet? doesn't really address my question.
I'm trying to understand how a bot can communicate with command and control (CC) machine. On a technical level, I know bots use sockets (for example), but I really have no idea how the CC can send commands to a bot/computer which is probably inside a LAN private network. Lots of computers are in a LAN behind a box, or a router. So for communication behind a port with a server you must to use NAT I think.
Can anyone explain how this works?