pfsense 2.4.4, haproxy, split dns problem when trying to access server from lan side

  • I have searched the forums, came a cross a few posts that had similar but not the same problem and have not been able to solve my problem (yet). so now, hopefully someone can point me in a better direction.

    I have pfsense with haproxy set up to redirect traffic coming in on port 80 to port 443 and from there haproxy will check for SNI and forward it to the right backend. backend is a hosting server and hosts websites and mail, it sits on LAN1. When accessing both https and mail (smtp, imap) from external WAN side, everything works fine. But when I am working from inside on LAN2, accessing the websites is no problem, haproxy catches the traffic going out and redirects it back to the server in LAN1. But when I try to access the mailserver, it doens't work, which makes sense, because i don't have NAT relfection turned on or anything of the sorts. Normally I would solve this problem with a split DNS entry (running on the DNS resolver), but as soon as i use a split dns entry for, mail and access to other port work, but access to http or https stop working. It resolves to the internal LAN1 ip, but does not get any reaction from the server.

    Any help solving this problem woul dbe greatly appreciated.


  • I "solved" it by setting a split dns entry for the server pointing it to a local ip in subnet b. but also adding a port forward in nat to forward all traffic coming from subnet a with destination the local ip of the server in subnet b and destination port 80 and 443 to be forwarded to the external ip. this way all http(s) traffic will go through haproxy and everything works as expected. it's a bit of a hack, would have preferred to solve this more elegantly. now i will have to create these kind of port forwards for each server that hosts http(s) content.

  • LAYER 8 Netgate

Log in to reply