Following are port numbers for different services:
You can find/verify ports used by postfix and dovecot using following commands:
netstat -tulpn | egrep 'master|dovecot'
Above command assumes you are using postfix (master) and dovecot. You can replace them with your packages or even port number like:
netstat -tulpn | egrep '25|465|587|110|143'
Please note that if you are using non standard ports, you may miss open-ports when running a command-like above.