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.6m 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.
    • R
      Rinzwind
      last edited by

      Yup loggin is enabled. Also as test enabled "Global Enable Logging"  on general tab. Still nothing. DNSBL blocks should show up on the Alerts tab right?

      I also don't see any result of settings DNSBL Firewall Rule. No floathing rules are created.

      So yeah a good informational best practice setup tutorial would be very welcome.

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

        If your Lan is 10.10.10.x, what did you set the DNSBL VIP to? It has to be set to any other RFC1918 range for it to work.

        In the general tab, the 'global logging' is only specific to IPv4/6 firewall rules. The DNSBL IP logging is only used when a DNSBL list posts IP addresses and these addresses are collected and put into an alias and a firewall rule added. It doesn't log domain based alerts..

        I suggest you check your VIP and execute a 'force reload'. You should be able to ping and browse the VIP address from any LAN device. If not, then either the DNSBL service is not running or there is something preventing access to the VIP address. If you have multi-segment LAN addresses, enable the option in the DNSBL tab to create a floating firewall rule to pass the traffic from other Lan subnets.

        If your still having trouble, post screenshots of the general and DNSBL tabs.

        "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
        • F
          fraglord
          last edited by

          @bbcan177: I still have the issue that after pfsense has been rebooted with DNSBL enabled I manually have to start or restart the unbound service to get the DNS working. Any clue what cause this?

          pfSense 2.4.0 (amd64) running on IGEL H710C | 1G RAM | 8G SSD | INTEL PRO/1000 PT Dual NIC

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

            Hi fraglord, do you have either of the DHCP check boxes enabled in the Unbound Resolver settings tab? There seems to be some issues with those options. You can also review the pfSense System and Resolver logs for more clues.

            "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
            • F
              fraglord
              last edited by

              Thanks for the quick reply  :D I habe none of these options enabled because pfsense is not doing DHCP.
              But there is something suspicious in the system logs

              php-fpm[49122]: /rc.newwanip: The command '/usr/local/sbin/unbound -c /var/unbound/unbound.conf' returned exit code '1', the output was '[1456266101] unbound[78664:0] error: bind: address already in use [1456266101] unbound[78664:0] fatal error: could not open ports'
              

              pfSense 2.4.0 (amd64) running on IGEL H710C | 1G RAM | 8G SSD | INTEL PRO/1000 PT Dual NIC

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

                It's not a DNSBL issue. Check your Unbound settings. Maybe an interface settings issue? If you don't resolve it, post in the DNS forum and see if anyone has other advice for you.

                "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
                • X
                  XmickS
                  last edited by

                  Im having troubles loading links in .txt format. with both easylist and blocklists such as: https://www.spamhaus.org/drop/drop.txt

                  this is the log created when updating:

                  [ Spamhaus_drop ] Downloading update  .. 403 Forbidden

                  [ pfB_spamhaus - Spamhaus_drop ] Download FAIL [ 02/24/16 2:07:43 ]
                    Firewall and/or IDS are not blocking download.

                  The Following list has been REMOVED [ Spamhaus_drop ]

                  …
                  ...

                  [ https://easylist-downloads.adblockplus.org/antiadblockfilters.txt ] Downloading update  .

                  [ DNSBL_EasyList - https://easylist-downloads.adblockplus.org/antiadblockfilters.txt ] Download FAIL
                    Firewall and/or IDS are not blocking download.

                  I cant figure out what is going wrong in my settings. can somebody help me?

                  Thanks

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

                    When you see "403 Forbidden", the site that your trying to download from is either blocking your IP or rate limiting you. Disable the snort list for 24 hours and re-enable to get around that issue.

                    You can't use other EasyList feeds. Currently only two feeds for EasyList are hardcoded in the EasyList tab. There is also a note about this in the DNSBL tab.

                    "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
                    • F
                      fraglord
                      last edited by

                      @BBcan177:

                      It's not a DNSBL issue. Check your Unbound settings. Maybe an interface settings issue? If you don't resolve it, post in the DNS forum and see if anyone has other advice for you.

                      Not sure if this is the cause of the problem - I am still investigating. At least I can confirm that with DNSBL disabled this problem does not occur.

                      pfSense 2.4.0 (amd64) running on IGEL H710C | 1G RAM | 8G SSD | INTEL PRO/1000 PT Dual NIC

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

                        @fraglord:

                        @BBcan177:

                        It's not a DNSBL issue. Check your Unbound settings. Maybe an interface settings issue? If you don't resolve it, post in the DNS forum and see if anyone has other advice for you.

                        Not sure if this is the cause of the problem - I am still investigating. At least I can confirm that with DNSBL disabled this problem does not occur.

                        How many domains are you blocking? You can see the total in the widget? Your footnote shows 1Gb of ram, maybe with DNSBL, it's taking longer for Unbound to start and newwanip is attempting to restart a second time?‎ Can you increase the RAM size?
                        ‎

                        "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
                        • RonpfSR
                          RonpfS
                          last edited by

                          @BBcan177:

                          How many domains are you blocking? You can see the total in the widget? Your footnote shows 1Gb of ram, maybe with DNSBL, it's taking longer for Unbound to start and newwanip is attempting to restart a second time?‎ Can you increase the RAM size?

                          1099450 Domains in my case with 2.5GB

                          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
                          • X
                            XmickS
                            last edited by

                            @BBcan177:

                            When you see "403 Forbidden", the site that your trying to download from is either blocking your IP or rate limiting you. Disable the snort list for 24 hours and re-enable to get around that issue.

                            I can open the link in my browser, so i think they're not blocking me. I dont have the snort package installed on my pfsensebox. Which snortlist should i disable?

                            Thanks for the help!

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

                              Hi XmickS,

                              Sorry I meant to say disable the spamhaus drop list in pfBlockerNG for 24hrs. Typically a "403" error means the site you are downloading from is blocking you. Is your browser using a different Gateway or DNS server then the pfSense box? Do you use a proxy? If that doesn't help, post a screenshot of the spamhaus alias settings.

                              "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
                              • K
                                krhainos
                                last edited by

                                I'm starting from a fresh install of 2.2.6-RELEASE (amd64) and rebuilding to clear out cruft from multiple past upgrades.

                                The installation of the pfBlockerNG package has been sitting at "Executing custom_php_resync_config_command()…" for about 45 minutes now.  The browser is not showing a loading animation either (shows the pfSense logo favicon).

                                Is this normal?

                                I'm on a 30 down/5 up connection. Whatever it's downloading, if it's downloading that is, shouldn't take that long.  Diagnostics/System Activity doesn't appear to say a whole lot is happening on the CPU either.

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

                                  Hi krhainos, can you post the last 20 lines of the pfblockerng.log? You can run this command from the Diagnostics: Command Prompt:

                                  tail -n20 /var/log/pfblockerng/pfblockerng.log

                                  Are there any relevant errors in the pfSense system log?

                                  "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
                                  • K
                                    krhainos
                                    last edited by

                                    @BBcan177:

                                    Hi krhainos, can you post the last 20 lines of the pfblockerng.log? You can run this command from the Diagnostics: Command Prompt:

                                    tail -n20 /var/log/pfblockerng/pfblockerng.log

                                    Are there any relevant errors in the pfSense system log?

                                    I'm actually on the way to figuring it out!

                                    Something about one of my rules is tripping up the pfBlockerNG installation.

                                    I've been keeping configuration backups after every piece I configure.  I've only done restores from my old config on my alises list, and my rules.  It seems the installation hangs after I restore my rules.  I'll update once I figure out what exactly it dislikes about my rules.

                                    Update: I found it.  After going through the filter section in my config, I found a line between two rules that read "<rule>".  It looked out of place, so I removed it.  pfBlockerNG is happy now!  It downloads, updates, crons and everything.  I don't know how it got in there, and going through old backups, it's been there for a while.

                                    I've attached a screenshot in case a visual helps.

                                    youruineverything.png
                                    youruineverything.png_thumb</rule>

                                    1 Reply Last reply Reply Quote 0
                                    • X
                                      XmickS
                                      last edited by

                                      @BBcan177:

                                      Hi XmickS,

                                      Sorry I meant to say disable the spamhaus drop list in pfBlockerNG for 24hrs. Typically a "403" error means the site you are downloading from is blocking you. Is your browser using a different Gateway or DNS server then the pfSense box? Do you use a proxy? If that doesn't help, post a screenshot of the spamhaus alias settings.

                                      Found the problem. I was using vpn client and the ip i was using was being blocked by spamhaus. when i switched to another ip i was able to download the list. now everything is working as (i think) it should. thanks for the help!

                                      1 Reply Last reply Reply Quote 0
                                      • X
                                        XmickS
                                        last edited by

                                        maybe a newbie question, but im curious. what is the difference with pfblockerng and adblock plus (or ghostery)? when these extensions are saying that they're blocking stuff, does that mean that my pfsense box is not blocking everything, or are they blocking the same stuff?

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

                                          Adblock plus is an extension inside your Browser, so it does filter what your browser is using. It does not filter traffic for other application like Windows Update.

                                          pfBlockerNG is on the firewall and filter traffic from all applications and computers.

                                          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
                                          • X
                                            XmickS
                                            last edited by

                                            @RonpfS:

                                            Adblock plus is an extension inside your Browser, so it does filter what your browser is using. It does not filter traffic for other application like Windows Update.

                                            pfBlockerNG is on the firewall and filter traffic from all applications and computers.

                                            But there is no difference in what they filter? Thought maybe pfblocker can't filter everything as well as an adblocker extension.

                                            Sometimes an ad slips through my firewall. Does that mean I don't have everything set as it should?

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