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

    Can't get pfBlockerNG to block pornhub.com

    pfBlockerNG
    13
    56
    21.8k
    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.
    • F
      fullauto
      last edited by

      New pfBlockerNG user. Latest version. Got things mostly working. Using Shallalist and UT1 Summary to block Adult and Porn and Gambling categories. 1bet.com gets blocked but pornhub.com does not. And the crazy thing is that I can ping pornhub.com and it resolves to 10.10.10.1!!!! WTF? How is that possible?

      It's the same as the DNSBL Webserver Configuration Virtual IP Address. Not really sure what that's for. Yes, noob here.

      porthub.wine resolves to 104. 21.28.246.

      Help :(

      S noplanN A JonathanLeeJ 4 Replies Last reply Reply Quote 1
      • S
        SteveITS Galactic Empire @fullauto
        last edited by SteveITS

        @fullauto What does dig or nslookup say? It could be getting cached by your OS. (in Windows, ipconfig /flushdns)

        Pre-2.7.2/23.09: Only install packages for your version, or risk breaking it. Select your branch in System/Update/Update Settings.
        When upgrading, allow 10-15 minutes to restart, or more depending on packages and device speed.
        Upvote 👍 helpful posts!

        1 Reply Last reply Reply Quote 0
        • noplanN
          noplan @fullauto
          last edited by

          @fullauto

          Dnsbl wildcard block enabled?
          Like *pornhub.com

          State killed from your device before each test?
          The nasty thing is sometimes only a reboot of both devices pfS and test device helps to get a clear look

          BrNP

          1 Reply Last reply Reply Quote 1
          • N
            NOCling
            last edited by

            Have a look at DoH on client side if you block only the DNS resolution it will not work.

            Netgate 6100 & Netgate 2100

            noplanN 1 Reply Last reply Reply Quote 0
            • Cool_CoronaC
              Cool_Corona
              last edited by

              Its a shame.... its a good site with a lot of valuable info.

              noplanN 1 Reply Last reply Reply Quote 2
              • noplanN
                noplan @Cool_Corona
                last edited by

                @cool_corona
                Yeah and I guess it's running on nginx

                1 Reply Last reply Reply Quote 0
                • noplanN
                  noplan @NOCling
                  last edited by

                  @nocling

                  Yeah that might kill the idea of blocking a request

                  1 Reply Last reply Reply Quote 0
                  • N
                    NOCling
                    last edited by

                    @noplan
                    No, do it right!

                    Use pfBlocker to block DoH Server, Block Apple DNS.
                    Use a NAT Roule to mode DNS to your pfSense.
                    Block DNSSEC for clients.

                    Netgate 6100 & Netgate 2100

                    noplanN 1 Reply Last reply Reply Quote 1
                    • noplanN
                      noplan @NOCling
                      last edited by

                      @nocling

                      OK still to early for me here in the alps

                      Not getting the part with the NAT rule...

                      BrNP

                      1 Reply Last reply Reply Quote 0
                      • M
                        michmoor LAYER 8 Rebel Alliance
                        last edited by michmoor

                        i do that easily. I have Wildcard Blocking (TLD) enabled.
                        I create my own blacklist and I put pornhub.com
                        Reload all and that's it...Blocked.
                        I do no blocking of DoH or DoT. As long as the clients are pointing to the firewall for DNS you are good. Additional you can use NAT reflection to make sure any DNS query outside of port 53 get redirected to the firewall.

                        The other method would be to grab a Steven Blacklist for Porn and use that but the way I prefer to handle things and the way I have things configured is that I block all porn and I have a custom black list where I add additional sites.
                        I also have custom Unbound configuration where I select certain /32s or /24s that are exempt from the DNSBL.

                        Firewall: NetGate,Palo Alto-VM,Juniper SRX
                        Routing: Juniper, Arista, Cisco
                        Switching: Juniper, Arista, Cisco
                        Wireless: Unifi, Aruba IAP
                        JNCIP,CCNP Enterprise

                        1 Reply Last reply Reply Quote 1
                        • 1
                          1OF1000Quadrillion
                          last edited by 1OF1000Quadrillion

                          Try blocking it using the ASN.
                          Create a custom feed under IP->IPv4 use the ASN

                          AS29789
                          ASN found by pinging pornhub.com and doing an IP lookup on https://iplocation.io/
                          scroll to the middle'ish of th results to find the AS number.

                          don't forget to assign the alias to a firewall rule.

                          M 1 Reply Last reply Reply Quote 0
                          • M
                            michmoor LAYER 8 Rebel Alliance @1OF1000Quadrillion
                            last edited by

                            @1of1000quadrillion said in Can't get pfBlockerNG to block pornhub.com:

                            AS29789

                            ASN blocking is dangerous. Unless its an ASN wholly owned by the public entity (facebook,google,nextlix) then you are just blackholing lots of sites. Blast radius is way to much with that technique.

                            Firewall: NetGate,Palo Alto-VM,Juniper SRX
                            Routing: Juniper, Arista, Cisco
                            Switching: Juniper, Arista, Cisco
                            Wireless: Unifi, Aruba IAP
                            JNCIP,CCNP Enterprise

                            noplanN 1 Reply Last reply Reply Quote 0
                            • noplanN
                              noplan @michmoor
                              last edited by

                              @michmoor

                              OH yeah we burned some serious amount of hours playing and undoing this dangerous Config

                              Yeep nat reflection also on the default start / setting here
                              Next on the list the list from @NOCling

                              1 Reply Last reply Reply Quote 0
                              • A
                                axsdenied @fullauto
                                last edited by

                                @fullauto I suspect a DNS leak. I've seen this behavior as I didn't lock DNS to my specific server.

                                If you're using Windows with Edge, Edge actually has a feature that was allowing it to resolve URL's that shouldn't have worked, based on my DNS config. I.e. they resolved fine in command line (no flush needed) but not in Edge.

                                1 Reply Last reply Reply Quote 0
                                • JonathanLeeJ
                                  JonathanLee @fullauto
                                  last edited by JonathanLee

                                  @fullauto

                                  Have you tried regular expressions for the URL?

                                  Screen Shot 2022-03-25 at 7.37.04 AM.png

                                  (Image: Most of my blocks are for learning purposes and for my research with my degree)

                                  I don't like prankdial, hotjar, rubygems, docker, and some other ones that seemed to cause me some issues. I am sure a lot of mine do not need to be blocked, but how can you learn if you don't test stuff out? Here is an example.

                                  I always have had issues with Doubleclick.net they caused me so many issues with devices and human interaction with mouse and keyboards, I found all my items work better with them blocked. Notice ^.URL.com.$ try that.

                                  Also check your Target rules if they are whitelisted it will override items by order like ACLs.

                                  Screen Shot 2022-03-25 at 7.39.50 AM.png

                                  Also enable encrypted DNS

                                  Screen Shot 2022-03-25 at 7.48.32 AM.png

                                  If the DNS is encrypted and using SSL it can't be hijacked, I would cry if they hijacked the update servers.

                                  Make sure to upvote

                                  JonathanLeeJ 1 Reply Last reply Reply Quote 0
                                  • JonathanLeeJ
                                    JonathanLee @JonathanLee
                                    last edited by JonathanLee

                                    @jonathanlee

                                    Screen Shot 2022-03-25 at 7.51.58 AM.png

                                    You can see it blocking all the variations of doubleclick.net now, it does not matter what differences are in the URL if the main part is the same it blocks it forever.

                                    Make sure to upvote

                                    1 Reply Last reply Reply Quote 0
                                    • LPD7L
                                      LPD7
                                      last edited by

                                      I have read through this thread but still unclear as to what the resolution would be. I too would like to block sites such as facebook, tik-tok, etc and thought I had it licked by creating a custom list in DNSBL but the sites are not getting blocked. I have squid installed but not running as I had some issues in the past where it locked up the system which I think were related to bad memory which I have resolved. I am new to this and still getting my feet wet so would like to get clarity on how to accomplish this. I am sure this has been talked about quite a bit so if there is a thread or instruction that covers the topic feel free to post the link and I will give it a shot. Thank you.

                                      Intelligence is not a substitute for common sense.
                                      Intel i5-3427 * 1.80GHz * 8GB Memory * 100GB HDD
                                      Putting legacy equipment into service and out of landfills.

                                      S 1 Reply Last reply Reply Quote 1
                                      • S
                                        SteveITS Galactic Empire @LPD7
                                        last edited by

                                        @lpd7 Can you provide details? nslookup results, etc. Are you blocking DoH? If not most browsers will bypass the configured DNS servers. Did you run an update in pfBlocker after changing settings?

                                        Pre-2.7.2/23.09: Only install packages for your version, or risk breaking it. Select your branch in System/Update/Update Settings.
                                        When upgrading, allow 10-15 minutes to restart, or more depending on packages and device speed.
                                        Upvote 👍 helpful posts!

                                        LPD7L 1 Reply Last reply Reply Quote 0
                                        • LPD7L
                                          LPD7 @SteveITS
                                          last edited by

                                          @steveits said in Can't get pfBlockerNG to block pornhub.com:

                                          @lpd7 Can you provide details? nslookup results, etc. Are you blocking DoH? If not most browsers will bypass the configured DNS servers. Did you run an update in pfBlocker after changing settings?

                                          New to pFS and pFB so bear with me as I track down the info and educate myself as well.

                                          Not sure which nslookup results you want to see so please elaborate, happy to provide.

                                          Yes blocking DoH
                                          2e10d220-ce71-424b-97d5-284d745c74e7-image.png

                                          and selected all options in the blocking list
                                          db7df275-d95b-45d7-85e2-3f1dc0811298-image.png

                                          I usually run Cron after making changes but ran the Update twice just to make sure.

                                          Intelligence is not a substitute for common sense.
                                          Intel i5-3427 * 1.80GHz * 8GB Memory * 100GB HDD
                                          Putting legacy equipment into service and out of landfills.

                                          JonathanLeeJ S 3 Replies Last reply Reply Quote 0
                                          • JonathanLeeJ
                                            JonathanLee @LPD7
                                            last edited by JonathanLee

                                            @lpd7

                                            I don't know if this helps, I use Squidguard as it is designed for use with Squid Proxy. Here is some photos of it in action.

                                            I feel this system should be simplified for parents and have scripts created to make this install with ease. You must have static addresses to make this work correctly. So it should have a quick install where you manually connect each device so it can auto populate the static addresses.

                                            After it should create your certificates for you and let you install them.

                                            After it should walk you threw how to set up WPAD this is a must for auto proxy use.

                                            https://docs.netgate.com/pfsense/en/latest/recipes/http-client-proxy-wpad.html

                                            Screen Shot 2022-06-02 at 1.19.05 PM.png

                                            Just edit a path to the file and save it. This is needed for use with windows and other devices to find the proxy automatically.

                                            Next you need your websites you want blocked. Example of how it works for me.

                                            Screen Shot 2022-06-02 at 1.06.30 PM.png

                                            (Image: Url Blocker working under Squidguard Table)

                                            Screen Shot 2022-06-02 at 1.06.45 PM.png

                                            (Image: Once package is installed use SquidGuard Proxy Filter)

                                            Screen Shot 2022-06-02 at 1.06.14 PM.png

                                            (Image: What happens when the URL is tested)

                                            Screen Shot 2022-06-02 at 1.07.28 PM.png

                                            (Image: Target Categories)

                                            Screen Shot 2022-06-02 at 1.08.01 PM.png

                                            (Make a Profile and attach the IP addresses of the system you want blocked for adult websites, you must also have a dummy profile for it to work that takes the place of position one)

                                            A nice how to guide I have found to get this system to work.

                                            Configure pfSense as HTTPS \ SSL Proxy filter using Squid and SquidGuard! (n.d.). Retrieved June 2, 2022, from https://forum.it-monkey.net/index.php?topic=23.0

                                            Make sure you let the loopback and local subnets use the proxy

                                            Screen Shot 2022-06-02 at 1.14.51 PM.png

                                            This all works with the HTTP get requests and headers. So no harm done. It is so simple however I worked in IT for over 15 combined years. Yes this needs to be simple for the average Parent and it can be done. There is some great guides for this version, and I for one use it and it blocks what you want blocked. You can even set up timers for no access in the middle of the night.

                                            Do not forget you must set up your access control lists. This is the packet filter that uses ports and IP addresses also.

                                            This is mine.

                                            Screen Shot 2022-06-02 at 1.22.25 PM.png

                                            Screen Shot 2022-06-02 at 1.23.34 PM.png
                                            (image: ACLS)

                                            Screen Shot 2022-06-02 at 1.24.18 PM.png
                                            (image: NAT Port Forwards for DNS and NTP so the firewall handles all requests)

                                            Make sure to upvote

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