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

    Port restriction rule!

    Scheduled Pinned Locked Moved Firewalling
    79 Posts 3 Posters 5.0k 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.
    • A
      Antibiotic @stephenw10
      last edited by

      @stephenw10 Oh i did mistake with only TCP and change to any)))

      pfSense plus 24.11 on Topton mini PC
      CPU: Intel N100
      NIC: Intel i-226v 4 pcs
      RAM : 16 GB DDR5
      Disk: 128 GB NVMe
      Brgds, Archi

      1 Reply Last reply Reply Quote 0
      • A
        Antibiotic @stephenw10
        last edited by

        @stephenw10 But the rules order are correct, regarding the rest redirection rules? Will they work correctly?

        pfSense plus 24.11 on Topton mini PC
        CPU: Intel N100
        NIC: Intel i-226v 4 pcs
        RAM : 16 GB DDR5
        Disk: 128 GB NVMe
        Brgds, Archi

        1 Reply Last reply Reply Quote 0
        • A
          Antibiotic @stephenw10
          last edited by Antibiotic

          @stephenw10 Now can connect to Wireless router web gui form PC in other local subnet but still not able to see this hard disk on router connect over USB like samba sharing? Network discovery is ON for private network.

          pfSense plus 24.11 on Topton mini PC
          CPU: Intel N100
          NIC: Intel i-226v 4 pcs
          RAM : 16 GB DDR5
          Disk: 128 GB NVMe
          Brgds, Archi

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

            @Antibiotic how and the hell did Steve's quote turn into Russian? ;)

            I didn't look that deep at you rules - but that DOT redirect, ie dns over tls more than likely will not work.. Even if you have unbound listening for dot. Because any sane dot client should validate the cert is correct for the NS they are wanting to talk to via dot.

            Say your client is trying to talk to the quad9 via dot, it should validate that the cert is valid for dns.quad9.net, if not it should complain and not actually work. Unless you were using a cert it trusts that has cn/san for dns.quad9.net.. If it doesn't its a lame dot client, because one of the main features of dot or doh is validation that your talking to the NS you think your talking too via cert being correct and signed by CA you trust.

            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

            A 2 Replies Last reply Reply Quote 0
            • stephenw10S
              stephenw10 Netgate Administrator @Antibiotic
              last edited by

              @Antibiotic said in Port restriction rule!:

              not able to see this hard disk on router connect over USB like samba sharing? Network discovery is ON

              Device discovery like that typically only works inside the subnet of the device doing the discovery. So it will not 'discover' something in a different subnet.

              A 1 Reply Last reply Reply Quote 0
              • A
                Antibiotic @johnpoz
                last edited by

                @johnpoz I did how to recommend NetGate doc in DNS redirect section: "Clients using DNS over TLS or DNS over HTTPS could circumvent this protection. Redirecting or blocking port 853 may help with DNS over TLS, depending on the clients."

                pfSense plus 24.11 on Topton mini PC
                CPU: Intel N100
                NIC: Intel i-226v 4 pcs
                RAM : 16 GB DDR5
                Disk: 128 GB NVMe
                Brgds, Archi

                johnpozJ 1 Reply Last reply Reply Quote 0
                • A
                  Antibiotic @stephenw10
                  last edited by

                  @stephenw10 Than how to do this ?

                  pfSense plus 24.11 on Topton mini PC
                  CPU: Intel N100
                  NIC: Intel i-226v 4 pcs
                  RAM : 16 GB DDR5
                  Disk: 128 GB NVMe
                  Brgds, Archi

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

                    @Antibiotic said in Port restriction rule!:

                    depending on the clients."

                    Is the important part here.. If the dot client is sane, it wouldn't work - but sure guess there are some really shitty dot clients that don't actually validate..

                    Either way it helps with dot circumvent, because it the bad client will just work anyway, ie be redirect, or it will fail. I was just trying to point out that redirection of dot shouldn't work.

                    Dot is the less common use for clients, android might do dot vs doh? Dot is easy to block, just don't allow 853.. Doh is harder to block because it hides itself with all your other 443 traffic that has to be allowed for the internet to actually work.

                    Dot is more suited for NS that is forwarding to some other NS, and not actually the end 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.8, 24.11

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

                      Do not use discovery. Enter the IP addresss or hostname directly.

                      johnpozJ A 2 Replies Last reply Reply Quote 0
                      • A
                        Antibiotic @johnpoz
                        last edited by Antibiotic

                        @johnpoz I delete this rules regarding DOT and did by instructions in Blocking External Client DNS Queries regarding DOT)))

                        c206ff05-44ab-475a-97ee-13677353a043-image.png

                        pfSense plus 24.11 on Topton mini PC
                        CPU: Intel N100
                        NIC: Intel i-226v 4 pcs
                        RAM : 16 GB DDR5
                        Disk: 128 GB NVMe
                        Brgds, Archi

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

                          @stephenw10 I am still wondering how your quote ended up in Russian ;)

                          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

                          A 1 Reply Last reply Reply Quote 0
                          • A
                            Antibiotic @johnpoz
                            last edited by Antibiotic

                            @johnpoz Sorry not understand completely what you mean, but its OK because Russia come back to the global honest WORLD))) not a rules-based order

                            pfSense plus 24.11 on Topton mini PC
                            CPU: Intel N100
                            NIC: Intel i-226v 4 pcs
                            RAM : 16 GB DDR5
                            Disk: 128 GB NVMe
                            Brgds, Archi

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

                              @Antibiotic Steve's post was clearly in english, but then when you quoted it Russian ;) I was not aware that the forum software translated quotes to the posters language or whatever.. So clearly there was some copy paste on your part?

                              edit:
                              Your dot rule to lan subnets makes no sense.. Because you have a rule above it that allows any from lan to assume any local used network. So 853 would be allowed by that rule, there is no reason to allow 853 specifically. to lan subnets.

                              On a bit of side note, what is the point of * as source... How would there be any source ingress into this interface unless it was the subnet this interface is attached too?

                              The only time any for source makes any sense is if the interface is a transit network. The source IP should either be specific for IPs on this network that you want to have different rules for, or it should be set to the subnet the interface is attached to.

                              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

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

                                A browser plugin would do that. Or just Chrome with translate turned on.

                                1 Reply Last reply Reply Quote 0
                                • A
                                  Antibiotic @stephenw10
                                  last edited by Antibiotic

                                  @stephenw10 I tried but do something incorrectly

                                  Wireless router IP 192.168.20.11 and set

                                  do \192.168.20.11\HOME but error connection

                                  624d6c4b-bab3-48bd-972a-8cad3ecece0e-image.png

                                  pfSense plus 24.11 on Topton mini PC
                                  CPU: Intel N100
                                  NIC: Intel i-226v 4 pcs
                                  RAM : 16 GB DDR5
                                  Disk: 128 GB NVMe
                                  Brgds, Archi

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

                                    The file server may not allow connections from outside it's own subnet by default.

                                    A 1 Reply Last reply Reply Quote 0
                                    • A
                                      Antibiotic @johnpoz
                                      last edited by Antibiotic

                                      @johnpoz Re design))))

                                      0070e16d-23b5-4289-8b03-1973974b1971-image.png

                                      yes do copy past , Do not make copy past of translated world, write by English in forum

                                      pfSense plus 24.11 on Topton mini PC
                                      CPU: Intel N100
                                      NIC: Intel i-226v 4 pcs
                                      RAM : 16 GB DDR5
                                      Disk: 128 GB NVMe
                                      Brgds, Archi

                                      1 Reply Last reply Reply Quote 0
                                      • A
                                        Antibiotic @stephenw10
                                        last edited by Antibiotic

                                        @stephenw10 Yea but in AP mode i don't have any settings to allow this.

                                        pfSense plus 24.11 on Topton mini PC
                                        CPU: Intel N100
                                        NIC: Intel i-226v 4 pcs
                                        RAM : 16 GB DDR5
                                        Disk: 128 GB NVMe
                                        Brgds, Archi

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

                                          If it blocks connections from outside it's own subnet and there's no way to add rules to allow it then you would have to add NAT rules in pfSense. But things start to get ugly when you do that! So I would want to confirm that's really happening.

                                          A 1 Reply Last reply Reply Quote 0
                                          • A
                                            Antibiotic @stephenw10
                                            last edited by Antibiotic

                                            @stephenw If i set back to Wireless router mode than make to allow from outside it's own subnet. Set back to AP mode, will this work?

                                            pfSense plus 24.11 on Topton mini PC
                                            CPU: Intel N100
                                            NIC: Intel i-226v 4 pcs
                                            RAM : 16 GB DDR5
                                            Disk: 128 GB NVMe
                                            Brgds, Archi

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