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

    PfBlockerNG v2.0 w/DNSBL

    Scheduled Pinned Locked Moved pfBlockerNG
    1.1k Posts 192 Posters 1.7m 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.
    • BBcan177B
      BBcan177 Moderator
      last edited by

      @D0X:

      But now when browsing I continuously get Safari telling me the certificate is invalid (as shown in the attached picture, it is in Dutch but I think you'll get it).

      Safari seems to be the only browser that has this issue. Doesn't seem to occur with Chrome/FF/IE/Edge etc…

      Are these cert popups happening when you browse to that blocked Domain directly, or when its blocking that Domain as part of the webpage?  Two checks to ensure DNBSL is working as expected... Ping the DNSBL VIP and get a proper response ... Browse to the DNSBL VIP and get the 1x1 pix...

      If the popups are from a few common Domains, try to whitelist those and see if that improves it.

      Also, in the IPv4 tab, you cannot enter any EasyList Feeds... the IPv4 tab is for IP based listed only.

      DNSBL is designed to block the DNS resolution to Advert/Malicious Domains. As such only a portion of the EasyList/Privacy Feeds can be used (Where the feeds lists the actual ADvert Domain). Browser-Addons like ADBlock/UBlock manipulate the elements that are displayed on the page. So they can block certain elements from a particular Domain, while DNSBL can only block the entire Domain.

      Only two EasyList feeds can be used with DNSBL and they are hardcoded in the EasyList Tab. There are several other DNSBL Feeds listed at the start of this thread that can fill in the gap to block the balance of the Domains from serving any ADs.  Plus its achieved at Network level, without any add-ons manipulating or potentially opening security holes in the browser.

      It would really be nice if Safari fixed this issue with their software... Not much I can do to fix that without killing the package logging feature and just NXDOMAIN the DNS requests.

      "Experience is something you don't get until just after you need it."

      Website: http://pfBlockerNG.com
      Twitter: @BBcan177  #pfBlockerNG
      Reddit: https://www.reddit.com/r/pfBlockerNG/new/

      1 Reply Last reply Reply Quote 0
      • D
        D0X
        last edited by

        Safari seems to be the only browser that has this issue. Doesn't seem to occur with Chrome/FF/IE/Edge etc…

        Are these cert popups happening when you browse to that blocked Domain directly, or when its blocking that Domain as part of the webpage?  Two checks to ensure DNBSL is working as expected... Ping the DNSBL VIP and get a proper response ... Browse to the DNSBL VIP and get the 1x1 pix...

        Should the VIP be one inside the LAN subnet or outside, tried both. Only inside the subnet I am getting the 1x1 pix, both don't respond to pings.

        If the popups are from a few common Domains, try to whitelist those and see if that improves it.

        googleads.g.doubleclick.net seems to be the main culprit. Isn't there any other way to block this certificate?

        Also, in the IPv4 tab, you cannot enter any EasyList Feeds… the IPv4 tab is for IP based listed only.

        Check, only using DNSBL now.

        It would really be nice if Safari fixed this issue with their software… Not much I can do to fix that without killing the package logging feature and just NXDOMAIN the DNS requests.

        1 Reply Last reply Reply Quote 0
        • BBcan177B
          BBcan177 Moderator
          last edited by

          @D0X:

          Should the VIP be one inside the LAN subnet or outside, tried both. Only inside the subnet I am getting the 1x1 pix, both don't respond to pings.

          Typically you set the DNSBL VIP to "LAN", and if you are in a Multi-LAN network, you can enable the option in the DNSBL Tab to create a Floating Permit rule to allow all of your LAN Subnets to hit the DNSBL VIP address. You will get unexpected behaviour until your fix the Ping/Browse to the VIP.  Also ensure that your LAN devices only have pfSense as its DNS Server.

          "Experience is something you don't get until just after you need it."

          Website: http://pfBlockerNG.com
          Twitter: @BBcan177  #pfBlockerNG
          Reddit: https://www.reddit.com/r/pfBlockerNG/new/

          1 Reply Last reply Reply Quote 0
          • D
            D0X
            last edited by

            @BBcan177:

            @D0X:

            Should the VIP be one inside the LAN subnet or outside, tried both. Only inside the subnet I am getting the 1x1 pix, both don't respond to pings.

            Typically you set the DNSBL VIP to "LAN", and if you are in a Multi-LAN network, you can enable the option in the DNSBL Tab to create a Floating Permit rule to allow all of your LAN Subnets to hit the DNSBL VIP address. You will get unexpected behaviour until your fix the Ping/Browse to the VIP.  Also ensure that your LAN devices only have pfSense as its DNS Server.

            Thanks for your support so far, but for now I've given up on pfblockerng. Not that the package is flawed, but Safari on OSX and IOS is driving me nuts.

            1 Reply Last reply Reply Quote 0
            • BBcan177B
              BBcan177 Moderator
              last edited by

              @D0X:

              Thanks for your support so far, but for now I've given up on pfblockerng. Not that the package is flawed, but Safari on OSX and IOS is driving me nuts.

              NP…. Should you decide to pick it backup at some point, try to see why the Ping/Browse to the DNSBL VIP wasn't working. That will cause issues on its own.... also since it was one Domain that was predominantly causing issues,  you could also Whitelist it...

              "Experience is something you don't get until just after you need it."

              Website: http://pfBlockerNG.com
              Twitter: @BBcan177  #pfBlockerNG
              Reddit: https://www.reddit.com/r/pfBlockerNG/new/

              1 Reply Last reply Reply Quote 0
              • QinnQ
                Qinn
                last edited by

                Hi there is it possible to save and restore the pfBlockerNG settings at a certain phase, so when you mess up you can return to a previous setup?

                Hardeware: Intel(R) Celeron(R) J4125 CPU @ 2.00GHz 102 GB mSATA SSD (ZFS)
                Firmware: Latest-stable-pfSense CE (amd64)
                Packages: pfBlockerNG devel-beta (beta tester) - Avahi - Notes - Ntopng - PIMD/udpbroadcastrelay - Service Watchdog - System Patches

                1 Reply Last reply Reply Quote 0
                • RonpfSR
                  RonpfS
                  last edited by

                  @Qinn:

                  Hi there is it possible to save and restore the pfBlockerNG settings at a certain phase, so when you mess up you can return to a previous setup?

                  Every change in pfBlockerNG is saved in the config file.

                  You can save the config with Diagnostics/Backup & Restore/Backup & Restore and do a restore of the config at a later time.

                  2.4.5-RELEASE-p1 (amd64)
                  Intel Core2 Quad CPU Q8400 @ 2.66GHz 8GB
                  Backup 0.5_5, Bandwidthd 0.7.4_4, Cron 0.3.7_5, pfBlockerNG-devel 3.0.0_16, Status_Traffic_Totals 2.3.1_1, System_Patches 1.2_5

                  1 Reply Last reply Reply Quote 0
                  • W
                    wiz561
                    last edited by

                    I just updated the pfBlockerNG package and I'm now receiving these errors when I reboot…

                    There were error(s) loading the rules: /tmp/rules.debug:47: cannot define table pfB_Europe_v6: Cannot allocate memory - The line in question reads [47]: table <pfB_Europe_v6> persist file "/var/db/aliastables/pfB_Europe_v6.txt" @ 2016-07-31 12:37:54
                    There were error(s) loading the rules: /tmp/rules.debug:47: cannot define table pfB_Europe_v6: Cannot allocate memory - The line in question reads [47]: table <pfB_Europe_v6> persist file "/var/db/aliastables/pfB_Europe_v6.txt" @ 2016-07-31 12:39:58
                    There were error(s) loading the rules: /tmp/rules.debug:47: cannot define table pfB_Europe_v6: Cannot allocate memory - The line in question reads [47]: table <pfB_Europe_v6> persist file "/var/db/aliastables/pfB_Europe_v6.txt" @ 2016-07-31 12:40:37
                    
                    

                    I'm running pfBlockerNG 2.1.1_2 with PfSense 2.3.2-RELEASE (amd64).  I have 2gb of memory and 34% in use with a 2gb swap and 0% in use (for the swap).

                    I'm assuming it's not a memory issue and possibly something else.  I was wondering if anybody else had this issue and what a possible fix may be.

                    Thanks!

                    1 Reply Last reply Reply Quote 0
                    • RonpfSR
                      RonpfS
                      last edited by

                      @wiz561:

                      I just updated the pfBlockerNG package and I'm now receiving these errors when I reboot…

                      There were error(s) loading the rules: /tmp/rules.debug:47: cannot define table pfB_Europe_v6: Cannot allocate memory - The line in question reads [47]: table <pfB_Europe_v6> persist file "/var/db/aliastables/pfB_Europe_v6.txt" @ 2016-07-31 12:37:54
                      There were error(s) loading the rules: /tmp/rules.debug:47: cannot define table pfB_Europe_v6: Cannot allocate memory - The line in question reads [47]: table <pfB_Europe_v6> persist file "/var/db/aliastables/pfB_Europe_v6.txt" @ 2016-07-31 12:39:58
                      There were error(s) loading the rules: /tmp/rules.debug:47: cannot define table pfB_Europe_v6: Cannot allocate memory - The line in question reads [47]: table <pfB_Europe_v6> persist file "/var/db/aliastables/pfB_Europe_v6.txt" @ 2016-07-31 12:40:37
                      
                      

                      I'm running pfBlockerNG 2.1.1_2 with PfSense 2.3.2-RELEASE (amd64).  I have 2gb of memory and 34% in use with a 2gb swap and 0% in use (for the swap).

                      I'm assuming it's not a memory issue and possibly something else.  I was wondering if anybody else had this issue and what a possible fix may be.

                      Thanks!

                      Did you ran a Force Reload IP since the reboot?
                      Look at /var/db/aliastables/pfB_Europe_v6.txt, it should have only IP in it.

                      2.4.5-RELEASE-p1 (amd64)
                      Intel Core2 Quad CPU Q8400 @ 2.66GHz 8GB
                      Backup 0.5_5, Bandwidthd 0.7.4_4, Cron 0.3.7_5, pfBlockerNG-devel 3.0.0_16, Status_Traffic_Totals 2.3.1_1, System_Patches 1.2_5

                      1 Reply Last reply Reply Quote 0
                      • W
                        wiz561
                        last edited by

                        @RonpfS:

                        @wiz561:

                        I just updated the pfBlockerNG package and I'm now receiving these errors when I reboot…

                        There were error(s) loading the rules: /tmp/rules.debug:47: cannot define table pfB_Europe_v6: Cannot allocate memory - The line in question reads [47]: table <pfB_Europe_v6> persist file "/var/db/aliastables/pfB_Europe_v6.txt" @ 2016-07-31 12:37:54
                        There were error(s) loading the rules: /tmp/rules.debug:47: cannot define table pfB_Europe_v6: Cannot allocate memory - The line in question reads [47]: table <pfB_Europe_v6> persist file "/var/db/aliastables/pfB_Europe_v6.txt" @ 2016-07-31 12:39:58
                        There were error(s) loading the rules: /tmp/rules.debug:47: cannot define table pfB_Europe_v6: Cannot allocate memory - The line in question reads [47]: table <pfB_Europe_v6> persist file "/var/db/aliastables/pfB_Europe_v6.txt" @ 2016-07-31 12:40:37
                        
                        

                        I'm running pfBlockerNG 2.1.1_2 with PfSense 2.3.2-RELEASE (amd64).  I have 2gb of memory and 34% in use with a 2gb swap and 0% in use (for the swap).

                        I'm assuming it's not a memory issue and possibly something else.  I was wondering if anybody else had this issue and what a possible fix may be.

                        Thanks!

                        Did you ran a Force Reload IP since the reboot?
                        Look at /var/db/aliastables/pfB_Europe_v6.txt, it should have only IP in it.

                        Thanks for the response.  Yes, I ran through the force reload (all of them) and (update, cron, reload), and nothing.  I even tried to move the pfB_Europe_v6.txt file to .old and I'm still getting that error message.

                        1 Reply Last reply Reply Quote 0
                        • RonpfSR
                          RonpfS
                          last edited by

                          https://forum.pfsense.org/index.php?topic=115357.msg643944#msg643944

                          @BBcan177:

                          @lpallard:

                          There were error(s) loading the rules: /tmp/rules.debug:37: cannot define table pfB_Europe_v6: Cannot allocate memory - The line in question reads [37]: table <pfB_Europe_v6> persist file "/var/db/aliastables/pfB_Europe_v6.txt" @ 2016-07-31 14:55:00
                          There were error(s) loading the rules: /tmp/rules.debug:37: cannot define table pfB_Europe_v6: Cannot allocate memory - The line in question reads [37]: table <pfB_Europe_v6> persist file "/var/db/aliastables/pfB_Europe_v6.txt" @ 2016-07-31 14:55:11
                          There were error(s) loading the rules: /tap/rules.debug:37: cannot define table pfB_Europe_v6: Cannot allocate memory - The line in question reads [37]: table <pfB_Europe_v6> persist file "/var/db/aliastables/pfB_Europe_v6.txt" @ 2016-07-31 14:55:20 
                          

                          These all seem to be related to the MaxMind IPv6 database. Looks like you will need to bump the pfSense max aliastable entries limit from 2M to 4M. If you enable aggregation in the general tab, it should condense the CIDRs and reduce the overall IP count. This changed due to using the new MaxMind Geolite2 database which seems to have smaller subsets of the data listed causing more IP entries to be added.

                          2.4.5-RELEASE-p1 (amd64)
                          Intel Core2 Quad CPU Q8400 @ 2.66GHz 8GB
                          Backup 0.5_5, Bandwidthd 0.7.4_4, Cron 0.3.7_5, pfBlockerNG-devel 3.0.0_16, Status_Traffic_Totals 2.3.1_1, System_Patches 1.2_5

                          1 Reply Last reply Reply Quote 0
                          • W
                            wiz561
                            last edited by

                            @RonpfS:

                            https://forum.pfsense.org/index.php?topic=115357.msg643944#msg643944

                            @BBcan177:

                            @lpallard:

                            There were error(s) loading the rules: /tmp/rules.debug:37: cannot define table pfB_Europe_v6: Cannot allocate memory - The line in question reads [37]: table <pfB_Europe_v6> persist file "/var/db/aliastables/pfB_Europe_v6.txt" @ 2016-07-31 14:55:00
                            There were error(s) loading the rules: /tmp/rules.debug:37: cannot define table pfB_Europe_v6: Cannot allocate memory - The line in question reads [37]: table <pfB_Europe_v6> persist file "/var/db/aliastables/pfB_Europe_v6.txt" @ 2016-07-31 14:55:11
                            There were error(s) loading the rules: /tap/rules.debug:37: cannot define table pfB_Europe_v6: Cannot allocate memory - The line in question reads [37]: table <pfB_Europe_v6> persist file "/var/db/aliastables/pfB_Europe_v6.txt" @ 2016-07-31 14:55:20 
                            

                            These all seem to be related to the MaxMind IPv6 database. Looks like you will need to bump the pfSense max aliastable entries limit from 2M to 4M. If you enable aggregation in the general tab, it should condense the CIDRs and reduce the overall IP count. This changed due to using the new MaxMind Geolite2 database which seems to have smaller subsets of the data listed causing more IP entries to be added.

                            Thanks for the response.  Are you saying that I should change the…

                            Firewall Maximum Table Entries: 2000000

                            to

                            Firewall Maximum Table Entries: 4000000

                            I just wanted to make sure I'm changing the right thing.  Also, when the cron jobs were running, I saw something with some large numbers of maybe the 200000 and I was at something like 150000...  Sorry I didn't make note of it.

                            Thanks!

                            1 Reply Last reply Reply Quote 0
                            • RonpfSR
                              RonpfS
                              last edited by

                              @wiz561:

                              Thanks for the response.  Are you saying that I should change the…

                              Firewall Maximum Table Entries: 2000000

                              to

                              Firewall Maximum Table Entries: 4000000

                              I just wanted to make sure I'm changing the right thing.

                              This looks like it  ;)
                              Firewall Maximum Table Entries : Maximum number of table entries for systems such as aliases, sshlockout, snort, etc, combined.

                              @wiz561:

                              Also, when the cron jobs were running, I saw something with some large numbers of maybe the 200000 and I was at something like 150000…  Sorry I didn't make note of it.

                              Thanks!

                              You can review the log file by going to the Firewall/pfBlockerNG/Log Browser tab

                              2.4.5-RELEASE-p1 (amd64)
                              Intel Core2 Quad CPU Q8400 @ 2.66GHz 8GB
                              Backup 0.5_5, Bandwidthd 0.7.4_4, Cron 0.3.7_5, pfBlockerNG-devel 3.0.0_16, Status_Traffic_Totals 2.3.1_1, System_Patches 1.2_5

                              1 Reply Last reply Reply Quote 0
                              • W
                                wiz561
                                last edited by

                                @RonpfS:

                                @wiz561:

                                Thanks for the response.  Are you saying that I should change the…

                                Firewall Maximum Table Entries: 2000000

                                to

                                Firewall Maximum Table Entries: 4000000

                                I just wanted to make sure I'm changing the right thing.

                                This looks like it  ;)
                                Firewall Maximum Table Entries : Maximum number of table entries for systems such as aliases, sshlockout, snort, etc, combined.

                                @wiz561:

                                Also, when the cron jobs were running, I saw something with some large numbers of maybe the 200000 and I was at something like 150000…  Sorry I didn't make note of it.

                                Thanks!

                                You can review the log file by going to the Firewall/pfBlockerNG/Log Browser tab

                                Thanks.  I saw that 20000 number get changed to 40000-something so I think it's working.  Hopefully this will fix it!

                                I've been having some issues lately so I'm hoping that maybe this clears up some of the problems.  I think it's snort related, as the problems ceased when I stopped snort for a few days.

                                1 Reply Last reply Reply Quote 0
                                • QinnQ
                                  Qinn
                                  last edited by

                                  @RonpfS:

                                  @Qinn:

                                  Hi there is it possible to save and restore the pfBlockerNG settings at a certain phase, so when you mess up you can return to a previous setup?

                                  Every change in pfBlockerNG is saved in the config file.

                                  You can save the config with Diagnostics/Backup & Restore/Backup & Restore and do a restore of the config at a later time.

                                  Thanks for the reply, but I was hoping for a separate config file, as far as I can see there is none.

                                  Hardeware: Intel(R) Celeron(R) J4125 CPU @ 2.00GHz 102 GB mSATA SSD (ZFS)
                                  Firmware: Latest-stable-pfSense CE (amd64)
                                  Packages: pfBlockerNG devel-beta (beta tester) - Avahi - Notes - Ntopng - PIMD/udpbroadcastrelay - Service Watchdog - System Patches

                                  1 Reply Last reply Reply Quote 0
                                  • P
                                    PF64
                                    last edited by

                                    @wiz561:

                                    I just updated the pfBlockerNG package and I'm now receiving these errors when I reboot…

                                    There were error(s) loading the rules: /tmp/rules.debug:47: cannot define table pfB_Europe_v6: Cannot allocate memory - The line in question reads [47]: table <pfB_Europe_v6> persist file "/var/db/aliastables/pfB_Europe_v6.txt" @ 2016-07-31 12:37:54
                                    There were error(s) loading the rules: /tmp/rules.debug:47: cannot define table pfB_Europe_v6: Cannot allocate memory - The line in question reads [47]: table <pfB_Europe_v6> persist file "/var/db/aliastables/pfB_Europe_v6.txt" @ 2016-07-31 12:39:58
                                    There were error(s) loading the rules: /tmp/rules.debug:47: cannot define table pfB_Europe_v6: Cannot allocate memory - The line in question reads [47]: table <pfB_Europe_v6> persist file "/var/db/aliastables/pfB_Europe_v6.txt" @ 2016-07-31 12:40:37
                                    
                                    

                                    I'm running pfBlockerNG 2.1.1_2 with PfSense 2.3.2-RELEASE (amd64).  I have 2gb of memory and 34% in use with a 2gb swap and 0% in use (for the swap).

                                    I'm assuming it's not a memory issue and possibly something else.  I was wondering if anybody else had this issue and what a possible fix may be.

                                    Thanks!

                                    I have a huge issue with the last update as well. It eats memory like a banshee in a matter of minutes! I have 16Gb and it fills it to the brim then gives me the same errors, can't load rules.

                                    1 Reply Last reply Reply Quote 0
                                    • F
                                      f34rinc
                                      last edited by

                                      @PF64:

                                      I have a huge issue with the last update as well. It eats memory like a banshee in a matter of minutes!

                                      Are you using the new DNSBL TLD feature?

                                      1 Reply Last reply Reply Quote 0
                                      • RonpfSR
                                        RonpfS
                                        last edited by

                                        Did you raise the Firewall Maximum Table Entries?
                                        How many IPs are blocked ? Did you enabled De-Duplication? CIDR Aggregation? Suppression?

                                        If you are using DNSBL, how many domains does it reports after a Force Reload?
                                        Suppressing a Domain in the Alert Tab will consume memory.

                                        What do you see in the log file during Update ?
                                        Provide more info on you setup so we can pinpoint the issue.

                                        2.4.5-RELEASE-p1 (amd64)
                                        Intel Core2 Quad CPU Q8400 @ 2.66GHz 8GB
                                        Backup 0.5_5, Bandwidthd 0.7.4_4, Cron 0.3.7_5, pfBlockerNG-devel 3.0.0_16, Status_Traffic_Totals 2.3.1_1, System_Patches 1.2_5

                                        1 Reply Last reply Reply Quote 0
                                        • P
                                          Panja
                                          last edited by

                                          I used DNSBL before but have disabled it at the moment.
                                          Is it correct I can still ping the virtual IP address (default: 10.10.10.1) even after disabling DNSBL?

                                          [UPDATE]
                                          I uninstalled pfBlockerNG and unticked the box that says "keep settings".
                                          After that I re-installed pfBlockerNG and configured everything without enabling DNSBL.
                                          The virtual IP assigned to DNSBL is not pingable now. I "fixed" the problem myself.  8)

                                          1 Reply Last reply Reply Quote 0
                                          • QinnQ
                                            Qinn
                                            last edited by

                                            Got a crash report running on 2.3.2-RELEASE (i386) with pfBlockerNG 2.1.1_2 with only DNSBL setup according to advise #18 (https://forum.pfsense.org/index.php?topic=102470.15), btw having enabled Alexa with 1K set.

                                            Thanks for any help/advise cheers Qinn

                                            Crash report begins.  Anonymous machine information:

                                            i386
                                            10.3-RELEASE-p5
                                            FreeBSD 10.3-RELEASE-p5 #0 7307492(RELENG_2_3_2): Tue Jul 19 14:11:41 CDT 2016    root@ce23-i386-builder:/builder/pfsense-232/tmp/obj/builder/pfsense-232/tmp/FreeBSD-src/sys/pfSense_wrap_vga

                                            Crash report details:

                                            PHP Errors:
                                            [03-Aug-2016 05:06:13] PHP Fatal error:  Allowed memory size of 134217728 bytes exhausted (tried to allocate 20 bytes) in /usr/local/www/pfblockerng/pfblockerng.php on line 728
                                            [03-Aug-2016 05:06:13] PHP Stack trace:
                                            [03-Aug-2016 05:06:13] PHP  1. {main}() /usr/local/www/pfblockerng/pfblockerng.php:0
                                            [03-Aug-2016 05:06:13] PHP  2. pfblockerng_get_countries() /usr/local/www/pfblockerng/pfblockerng.php:105
                                            [03-Aug-2016 05:06:13] PHP  3. explode() /usr/local/www/pfblockerng/pfblockerng.php:728

                                            Filename: /var/crash/minfree
                                            2048

                                            Hardeware: Intel(R) Celeron(R) J4125 CPU @ 2.00GHz 102 GB mSATA SSD (ZFS)
                                            Firmware: Latest-stable-pfSense CE (amd64)
                                            Packages: pfBlockerNG devel-beta (beta tester) - Avahi - Notes - Ntopng - PIMD/udpbroadcastrelay - Service Watchdog - System Patches

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