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

    OPT1 needs LAN DNS access

    Scheduled Pinned Locked Moved General pfSense Questions
    109 Posts 5 Posters 19.6k Views 6 Watching
    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.
    • ? Offline
      A Former User @johnpoz
      last edited by

      @johnpoz, Every day I have to provide support to people who ignore the default settings. simply because your system works fine.

      @stephenw10 good to know that 2 admins defend the default settings.

      1 Reply Last reply Reply Quote 0
      • L Offline
        lewis
        last edited by

        The LAN side is the only side that should have access to the firewall.
        The additional networks should not which is why I still had that the anti-lockout unchecked. I did that based on reading up about anti-lockout and it seemed to be the right way/option.

        ? johnpozJ 2 Replies Last reply Reply Quote 0
        • ? Offline
          A Former User @lewis
          last edited by

          @lewis, first remove the default rule, and then configure the blocking rule on each interface! If you have questions, how do you let me know? I'm here to help.

          1 Reply Last reply Reply Quote 0
          • stephenw10S Offline
            stephenw10 Netgate Administrator
            last edited by

            Those rules on the LAN interface only filter traffic from clients on the LAN. They have no influence on traffic from clients on OPT1 or OPT2.

            So if your goal is to prevent clients on OPT1/2 accessing the firewall then you need to check the rules on those interfaces.

            Those rules on LAN are fine.

            Steve

            1 Reply Last reply Reply Quote 0
            • johnpozJ Offline
              johnpoz LAYER 8 Global Moderator @lewis
              last edited by johnpoz

              @lewis said in OPT1 needs LAN DNS access:

              I still had that the anti-lockout unchecked.

              What - dude only devices on the LAN network would have the antilock rule, not other interfaces have that. And if you create a new interface or vlan are ZERO rules on that interface.. You can not access anything from that network until your create rules.

              The only thing that would work is dhcp, if you enable that hidden rules are created so it will work.. But that is all until you actually create rules.

              How about you actually show us the rules you have placed on these other interfaces.

              edit: Here is an example locked down vlan/network - its have very limited access ping, dns, ntp and nothing else other than interface, can not access the firewall gu, can not access anything on any other vlan/network locally. etc..

              lockeddown.jpg

              It can ping pfsense IP on that interface - for connectivity validation, etc. They can be adjust how you see fit.. But we really need to see the rules you have on these network.. What is on the lan has zero do with anything.

              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.8, 24.11

              1 Reply Last reply Reply Quote 0
              • L Offline
                lewis
                last edited by

                Maybe we are getting out of sync.
                The only place that anti-lockout option is enable (or unchecked) is on the LAN.
                Meaning, in system, advanced, the anti-lockout is not checked.

                I tested from the other networks and they cannot reach the firewall which is what I wanted so I'm not following what the problem is. I did this based on some pfsense document I found which talked about anti-lockout.

                Some information suggested using this method, others suggested creating an alias and using that as a rule so it's kind of confusing to know which is the right way.

                ? johnpozJ 2 Replies Last reply Reply Quote 0
                • ? Offline
                  A Former User @lewis
                  last edited by

                  @lewis said in OPT1 needs LAN DNS access:

                  I tested from the other networks and they cannot reach the firewall which is what I wanted so I'm not following what the problem is.

                  Don't worry, friend, don't drown in a glass of water, just do a tracert and set the route your team takes to get there.

                  1 Reply Last reply Reply Quote 0
                  • johnpozJ Offline
                    johnpoz LAYER 8 Global Moderator @lewis
                    last edited by johnpoz

                    @lewis said in OPT1 needs LAN DNS access:

                    The only place that anti-lockout option is enable (or unchecked) is on the LAN.

                    Ok that is correct, because it is not possible to enable that or disable that on any other interface.. Its a LAN thing only.. So yeah might be some confusion there that you were removing the antilock out for some reason.

                    Some information suggested using this method

                    It is possible if you wanted to restrict devices that were on your lan from getting to the web gui, to turn off the antilock out and set your own rules. But to be honest if you were going to be locking down your network, I wouldn't be putting anything on the "LAN" that shouldn't be there, ie admin only sort of thing.. Turning off the antilock rule should be carefully considered..

                    There was recently a thread where they were locked out and had to refer them here
                    https://docs.netgate.com/pfsense/en/latest/troubleshooting/locked-out.html

                    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.8, 24.11

                    1 Reply Last reply Reply Quote 0
                    • L Offline
                      lewis
                      last edited by

                      I want to understand what is being said and it's not clear to me.

                      From the OPT1 (10.0.0.1/24) and OPT2 (192.168.254.1/24) network, I cannot reach or even see anything on the 192.168.1.1 network using nmap.

                      From clients on each network, I get a reply from devices on the same network as expected but none see anything on other networks.

                      Of course, I need to block the firewall from any clients on each of those networks. The only network that should have access to the firewall is LAN.

                      stephenw10S 1 Reply Last reply Reply Quote 0
                      • stephenw10S Offline
                        stephenw10 Netgate Administrator @lewis
                        last edited by

                        And that is correct. The rules you had on LAN were fine. If the rules you have on OPT1 and OPT2 are as they were previously in this thread that's also fine.
                        If not then post the rules you have now for all 3 interfaces and we can review them.

                        Steve

                        1 Reply Last reply Reply Quote 0
                        • L Offline
                          lewis
                          last edited by lewis

                          To be safe, here they are. DNS servers are on the LAN, hence the rules.

                          1.jpg
                          2.jpg
                          3.jpg

                          1 Reply Last reply Reply Quote 0
                          • L Offline
                            lewis
                            last edited by

                            I think all I really need to do now is to add a rule on each network to not allow clients to access the gateway/firewall right?

                            johnpozJ 1 Reply Last reply Reply Quote 0
                            • johnpozJ Offline
                              johnpoz LAYER 8 Global Moderator @lewis
                              last edited by

                              @lewis said in OPT1 needs LAN DNS access:

                              each network to not allow clients to access the gateway/firewall right?

                              Your rfc1918 rule would do that, other than the wan IP which I would assume is public. This is good use of the "this firewall" alias. Which would include any IPs on the firewall, even if they change.

                              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.8, 24.11

                              1 Reply Last reply Reply Quote 1
                              • L Offline
                                lewis
                                last edited by

                                Correct, none of the clients on each network can see the pfsense firewall.
                                Or I should say, using nmap from a client, I can see the gateway of the network which is the pfsense device but no ports show up which is good.

                                However, I have a bit of a different situation on another network. I set up OPT2 recently for my new AP and the wireless clients can see ports 22, 53, 80 and 443 on the AP.

                                It's not yet clear to me if I should block that from the AP (running openwrt now) or using pfsense.
                                What is interesting to me is like our DHCP talk, it would be nice to have just one place (pfsense) to monitor/maintain all access rules.

                                I will have to block access to clients using the AP rules but am curious to know if there might be a way to do it from pfsense instead. Meaning, some rules on pfsense that would block other clients on the same network from being able to see those ports while also allowing the LAN to have access to the AP.

                                johnpozJ 1 Reply Last reply Reply Quote 0
                                • johnpozJ Offline
                                  johnpoz LAYER 8 Global Moderator @lewis
                                  last edited by

                                  @lewis said in OPT1 needs LAN DNS access:

                                  I set up OPT2 recently for my new AP and the wireless clients can see ports 22, 53, 80 and 443 on the AP.

                                  Pfsense has no control over devices talking to other devices on the same network.. If you fire up some device, even an AP on a network and it has services listening on ports pfsense would have no way to stop a client on the same network from seeing those. That would have to be done on the device.

                                  With something like an AP, the management IP should be on a network that is not available to wireless clients for example..

                                  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.8, 24.11

                                  L 1 Reply Last reply Reply Quote 0
                                  • L Offline
                                    lewis @johnpoz
                                    last edited by

                                    @johnpoz

                                    Got it. I thought there might be a way to block clients on the network itself.
                                    I'll block access on the AP then and allow the single LAN IP that should have access.

                                    johnpozJ 1 Reply Last reply Reply Quote 0
                                    • johnpozJ Offline
                                      johnpoz LAYER 8 Global Moderator @lewis
                                      last edited by johnpoz

                                      @lewis said in OPT1 needs LAN DNS access:

                                      I thought there might be a way to block clients on the network itself.

                                      Nope - not how it works.. When a device want to talk to an IP that is on the same network as its IP via its mask, it just arps and then sends the traffic directly to that mac.

                                      Traffic is only ever sent to the router (pfsense) when the IP the client wants to talk to is not on the clients own network. When a devices want to talk to say IP 1.2.3.4, which is not part of its local network. It will arp for the gateway mac if not already in its cache. And then send the traffic to the mac of the gateway with the destination IP of 1.2.3.4, pfsense will see this traffic and based on its routing send the traffic on either out another interface that is attached to the network that IP is on, or to its default gateway. That is if the firewall rules allow the traffic.

                                      edit: The only possible way pfsense could be involved in traffic on the same network talking to each other is there was a bridge setup in pfsense, then pfsense could filter traffic between devices on opposite sides of the bridge. But if devices were all on the same side of the bridge then pfsense would not see the traffic to be able to filter.

                                      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.8, 24.11

                                      J 1 Reply Last reply Reply Quote 1
                                      • J Offline
                                        jsmiddleton4 @johnpoz
                                        last edited by

                                        Very informative thread.....

                                        1 Reply Last reply Reply Quote 1
                                        • L Offline
                                          lewis
                                          last edited by lewis

                                          Figured I should add to this rather than start a new thread but happy to start a new one if needed.

                                          The last thing we did was to fix the OPT2 gateway so I could reach the AP from the LAN. All good since then.

                                          However, something weird happened today and I realized something is still not right.

                                          I am trying to reach a LAN IP from the OPT2 network so I created a rules that should allow this. But it didn't work. OPT2 devices cannot reach the IP on the LAN.

                                          While testing this, I noticed that none of the clients on the AP could even nmap the DNS port for the DNS servers they are allowed to use.
                                          2022-01-18_111012.jpg

                                          If I disable the DNS rules, clients definitely lose DNS services as expected. If I re-enable the rules, clients get DNS again.

                                          So, why aren't clients able to access the garage device since there is a rule that should allow them to?

                                          johnpozJ 1 Reply Last reply Reply Quote 0
                                          • johnpozJ Offline
                                            johnpoz LAYER 8 Global Moderator @lewis
                                            last edited by johnpoz

                                            @lewis said in OPT1 needs LAN DNS access:

                                            So, why aren't clients able to access the garage device since there is a rule that should allow them to?

                                            I don't see that rule even evaluated, see the states 0/0.. You sure its 80, and not https (443) etc. or some other port, rtsp uses 554 for example.

                                            Also Cam device, you sure that device has a gateway setup up pointing to pfsense.. if not then you wouldn't be able to access it from another network without doing source natting.

                                            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.8, 24.11

                                            L 1 Reply Last reply Reply Quote 0
                                            • First post
                                              Last post
                                            Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.