Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login
    Introducing Netgate Nexus: Multi-Instance Management at Your Fingertips.

    Interface 1 allow any/any rule allowing traffic to Int2 deny any/any.

    Scheduled Pinned Locked Moved Firewalling
    7 Posts 4 Posters 2.3k 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.
    • 7 Offline
      78firebird
      last edited by

      Ver 2.3.1-p5

      Network 1 (Internet) has a rule allowing any/any.
      Network 2 (Admin) has a rule denying any/any only allowing local admin traffic.

      Network 1 PC is able to access a network 2 server with the network 1 allow rule.  Logging shows that the network 1 rule allow any/any is permitting traffic to network 2 overriding the deny any/any rule on network 2.

      Is this a bug or do I need to setup a deny rule on every interface blocking access to network 2?

      Thanks,
      Daniel.

      1 Reply Last reply Reply Quote 0
      • 7 Offline
        78firebird
        last edited by

        For testing:

        Network 1:

        • Block any/to network 2
        • allow any/any

        This configuration prevented access.

        Further testing:
        Network 1:

        • Block any/to network 2
        • Block Network 2/any

        Network 2:

        • Allow Network 2/ to Network 1.

        It looks like the local rules to the source network is overriding the rules to the second network.  This looks like it could get complicated for larger networks (which I am setting up converting from Ci$co routers).

        1 Reply Last reply Reply Quote 0
        • C Offline
          cmb
          last edited by

          Interface rules are only processed on the ingress interface. Just like a Cisco ASA.
          https://doc.pfsense.org/index.php/Firewall_Rule_Basics

          1 Reply Last reply Reply Quote 0
          • 7 Offline
            78firebird
            last edited by

            I understand that it is applied to inbound traffic of the Interface with Cisco, although each interface in a Cisco router is treated separately.

            I might be missing something, but what is the best way to configure multiple client networks with unrestricted access to the Internet while restricting access to each other?

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

              huh?  What do you mean complicated.  Rules are evaluated on the interface the traffic enters on top down, first rule wins no other rules are evaluated after a rule triggers.

              So not sure what you think overrode anything.

              If you don't want traffic from interface 1, or network 1 to go to network 2, then put in a block.  If you don't want network 2 to create traffic to network 1 then you would put a rule on network 2 interface stating that.

              If you want to get fancy/complicated then could use the floating rules which are evaluated first and can be in or out, and can be set for multiple interfaces at the same time.

              All the interfaces are treated separately in pfsense as well.  You need to put your rules on the interface the traffic will enter pfsense on.

              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 25.11.1 | Lab VMs 2.8.1, 25.11.1

              1 Reply Last reply Reply Quote 0
              • DerelictD Offline
                Derelict LAYER 8 Netgate
                last edited by

                You want to do something like this:

                https://forum.pfsense.org/index.php?topic=113842.msg632969#msg632969

                Chattanooga, Tennessee, USA
                A comprehensive network diagram is worth 10,000 words and 15 conference calls.
                DO NOT set a source address/port in a port forward or firewall rule unless you KNOW you need it!
                Do Not Chat For Help! NO_WAN_EGRESS(TM)

                1 Reply Last reply Reply Quote 0
                • 7 Offline
                  78firebird
                  last edited by

                  Thanks for the assistance.  I'll have to see how I broke it earlier to understand how later, but its working now with the following.

                  Network 1 (Internet)
                  Permit Any/Any

                  Network 2 (Admin/secured)
                  Permit Admin/Admin

                  Floating Rule
                  Block - Interface Network 2 - Direction Out - Proto Any - Source Any - Dest Network 2

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