How is your firewall to decide what public source IP to give your packets from 192.168.1.16 for the NAT on their way back to the client?
root@game:~# curl ifconfig.me109.190.103.26
Give your internal host the same number of IP addresses as the number of 1:1 NAT rules you have configured for it and each service/daemon listening to that address will do the right thing and so will the firewall
root@moon:~# mtr -s 100 -r -c 100 109.190.103.26Start: 2023-01-08T12:43:02+0100HOST: moon.fihosting.net Loss% Snt Last Avg Best Wrst StDev 1.|-- 172.31.1.1 0.0% 100 4.3 3.6 2.4 5.8 0.9 2.|-- 20870.your-cloud.host 0.0% 100 0.2 0.3 0.2 0.6 0.1 3.|-- ??? 100.0 100 0.0 0.0 0.0 0.0 0.0 4.|-- static.73.143.12.49.clien 0.0% 100 1.3 2.3 0.8 27.3 4.2 5.|-- spine14.cloud1.nbg1.hetzn 0.0% 100 0.9 4.0 0.8 58.5 9.6 6.|-- static.213-133-112-81.cli 0.0% 100 0.5 1.7 0.3 24.9 2.9 7.|-- core5.fra.hetzner.com 0.0% 100 3.7 4.8 3.5 43.3 4.8 8.|-- core9.fra.hetzner.com 0.0% 100 3.8 3.9 3.7 6.0 0.2 9.|-- fra-1-a9.de.eu 0.0% 100 3.8 3.9 3.7 4.2 0.1 10.|-- ??? 100.0 100 0.0 0.0 0.0 0.0 0.0 11.|-- ??? 100.0 100 0.0 0.0 0.0 0.0 0.0 12.|-- ??? 100.0 100 0.0 0.0 0.0 0.0 0.0 13.|-- be101.sbg-g2-nc5.fr.eu 0.0% 100 6.7 8.4 6.6 65.9 7.5 14.|-- be103.par-gsw-sbb1-nc5.fr 0.0% 100 12.6 12.7 12.5 15.1 0.3 15.|-- be104-202.par-gsw-pb1-nc5 0.0% 100 13.4 41.0 12.7 335.4 57.1 16.|-- th2-dsl1-a1.fr.eu 0.0% 100 12.4 12.5 12.3 12.9 0.1 17.|-- 145.239.153.164 0.0% 100 12.4 12.4 12.3 16.2 0.4 18.|-- game.terageek.org 0.0% 100 28.3 28.0 27.5 28.8 0.3
It's an honor to find your answer in person! You can't imagine how many forum posts I've found from you doing research. Unfortunately, I didn't find or understand the exact piece of info that I needed. Thank you for your involvement!
I'm unsure what you mean. By "Internal host", you mean "192.168.1.16" ?
I'm blushing My reputation is far more due to persistence than better insight.
Think of it this way - in "normal" 1:1 scenarios there would be a separate internal host for each service published on the WAN side of the firewall - web, email, files, chat, etc. Each would have its own internal LAN IP and a 1:1 NAT to ensure that the return packets to the client have the same WAN IP that the client sent their request to.You want to consolidate all these separate servers/services on one internal host (game), which is perfectly fine. That host will need to emulate the many hosts to the firewall by having a separate LAN IP for each 1:1 NAT and by extension, each service.The tricky part is then to configure game with multiple IP's. For Linux you would use something like 'ip a add 192.168.1.17/24 dev eth0' but that depends on your distro. You may also need to configure each daemon to bind to a separate IP, especially if they listen on the same port.You don't need to do much on OPNsense at all. It can (and should) be blissfully unaware of all the internal config work. From the firewall perspective there are just multiple services that need 1:1 NAT.If you have a few spare hosts, try the multiple 1:1 NAT's with them first to get a feel for the procedure. Something like VirtualBox or Docker can help but they also introduce more complexity Bart...
I want to map additional public IPs (all ports) to only one local IP, one per (virtual) server. That way it's like every single server has its own IP. game.ficellocube.fr would have 192.168.1.17 and be reachable and answer through 109.190.103.27.And selfhost.lrob.net would have 192.168.1.254 and be reachable through 109.190.103.28