Suppose you wanna have HighID and open KAD network connection for eMule on a computer in a LAN, and the gateway is running iptables. Just add the rules below to your existing iptables rules and you are done.
# this example is based on the assumption that # eth0 is WAN interface and eth1 is LAN interface, # 192.168.0.2 is the ip address of a computer in LAN, # 4262 is the tcp port for ed2k network, # 4272 is the udp port for kad network. -A PREROUTING -i eth0 -p tcp -m tcp --dport 4262 -j DNAT --to-destination 192.168.0.2:4262 -A PREROUTING -i eth0 -p udp -m udp --dport 4272 -j DNAT --to-destination 192.168.0.2:4272 -A FORWARD -d 192.168.0.2/32 -i eth0 -o eth1 -p tcp --dport 4262 -j ACCEPT -A FORWARD -d 192.168.0.2/32 -i eth0 -o eth1 -p udp --dport 4272 -j ACCEPT