The general syntax for a simple port forwarding is:
<service> use <host>
The service, which can either be a port number or the appropriate alias from
/etc/services or an absolute path to a unix socket, is then made available
from the given host.
It is very convenient to let the original port differ from the provided one,
for example to allow access as user to ports which require root privileges.
A different original port can thus be specified with:
<service> use <host> as <service>
Port options are recognized when the service is specified as <port:modifier>.
Several modifiers can be chained together.
Valid modifiers are:
<port>:local (Listen to local interface only)
<port>:tcp (Forward only TCP connections (default))
<port>:udp (Forward UDP data)
<port>:tls (Encrypt data before forwarding)
<port>:compress (Compress data during the transmission)
The :local modifier is supported for incoming connections only.
Unix domain sockets do obviously not work on remote hosts.
MoreBalance will give warnings if it finds incorrect combinations.
Sometimes it is necessary to guarantee for certain connections to get special
priorities or the like.
guarantee <service1> after | before <service2>
guarantee <service1> after <service2> for <seconds> seconds
An example usage would be a pop-before-smtp implementation for mail servers.