• Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Search
  • Register
  • Login
Netgate Discussion Forum
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Search
  • Register
  • Login

vlan rule problem with haproxy

Scheduled Pinned Locked Moved L2/Switching/VLANs
6 Posts 2 Posters 759 Views
Loading More Posts
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • M
    mourad13
    last edited by Aug 2, 2020, 5:14 PM

    Hello,

    I have a pfsense with 2 network interfaces (WAN, LAN).
    On the LAN, I have configured several VLANs.
    I also installed HaProxy on the pfsense.

    In one of my VLANs, I created a VM and installed grafana which listens on port 3000.
    At the level of HAPROXY, everything works and when I enter my domain name, I arrive on the Grafana interface.

    Now I am trying to apply a rule to limit access to a few IPs, but none of the rules I create are working. I still have access to the interface.

    The only thing that could have blocked it was a floatting rule. But I am unable to authorize IP.

    Does the fact that HaProxy is on the Pfsense cause a problem?

    1 Reply Last reply Reply Quote 0
    • J
      johnpoz LAYER 8 Global Moderator
      last edited by johnpoz Aug 2, 2020, 5:37 PM Aug 2, 2020, 5:37 PM

      So your access this from other vlan or your lan, not the wan? Why are you using haproxy for internal access?

      Why not just resolve whatever fqdn to your local IP?

      Your going to have to give a some details if you want to block what your actually accessing and from where? What IP? Where is the client?

      An intelligent man is sometimes forced to be drunk to spend time with his fools
      If you get confused: Listen to the Music Play
      Please don't Chat/PM me for help, unless mod related
      SG-4860 24.11 | Lab VMs 2.7.2, 24.11

      1 Reply Last reply Reply Quote 0
      • M
        mourad13
        last edited by Aug 2, 2020, 6:00 PM

        Hello,

        here is a diagram of what I want to do

        alt text

        I take some capture of my rules and I post this to you

        1 Reply Last reply Reply Quote 0
        • M
          mourad13
          last edited by Aug 2, 2020, 6:15 PM

          Here are the rules on the WAN interface:
          alt text

          That of the OPT40 interface (VLAN40):
          alt text

          And HaProxy frontends:
          alt text

          1 Reply Last reply Reply Quote 0
          • J
            johnpoz LAYER 8 Global Moderator
            last edited by johnpoz Aug 2, 2020, 10:40 PM Aug 2, 2020, 10:38 PM

            Well where is your acl in your frontend limiting access to your source IP?

            Not suer what that rule on vlan40 is expected to do? They are not access that IP are they? There is no hits on that rule, they would be accessing your haproxy wan IP..

            An intelligent man is sometimes forced to be drunk to spend time with his fools
            If you get confused: Listen to the Music Play
            Please don't Chat/PM me for help, unless mod related
            SG-4860 24.11 | Lab VMs 2.7.2, 24.11

            1 Reply Last reply Reply Quote 1
            • M
              mourad13
              last edited by Aug 12, 2020, 9:41 AM

              Hello,

              Sorry to answer that now.
              With ACLs, cala works. I don't know HaProxy well yet (I was doing this with Nginx), I thought we had to do this with PfSense rules.

              Thank you so much.

              1 Reply Last reply Reply Quote 0
              • First post
                Last post
              Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.
                This community forum collects and processes your personal information.
                consent.not_received