top of page
support626160

Setup custom threat feed into a pfSense firewall

Updated: Oct 18, 2024

To integrate a custom threat feed into a pfSense firewall, you can use the pfBlockerNG package. This package allows you to automatically block or monitor IP addresses, domains, or URLs based on custom feeds. Here's a step-by-step guide to implement your feed into pfSense:

Step 1: Install pfBlockerNG on pfSense



  1. Log into the pfSense Web Interface:

    • Open a browser and go to your pfSense management IP.

    • Example: https://<pfSense_IP>

  2. Navigate to System > Package Manager.

  3. Click on the Available Packages tab.

  4. Search for pfBlockerNG.

  5. Click Install next to pfBlockerNG.

  6. Once installed, you will see pfBlockerNG appear in the main menu under Firewall.

Step 2: Enable and Configure pfBlockerNG

  1. Navigate to Firewall > pfBlockerNG.

  2. Click on the General tab.

  3. Under General Settings, ensure the following:

    • Enable pfBlockerNG: Check this option.

    • Update Interval: Set the update frequency for your feeds (e.g., Once a Day or Every Hour).

    • Log Settings: Enable logging if you want to track blocked/monitored entries.

  4. Click Save at the bottom.

Step 3: Create a New Alias for the Custom Feed

  1. Go to Firewall > pfBlockerNG.

  2. Click on the IP tab to configure the IP blocking lists.

  3. Click on Add to create a new custom list.

Fill in the following details:

  • Name: Give a unique name, such as AbuseFirewall_Bad_IPs.

  • Description: Optional. Add a brief description like Custom feed from AbuseFirewall.

  • List Action: Choose an action for the list:

    • Deny Both: Blocks both inbound and outbound traffic from these IPs.

    • Deny Inbound: Blocks inbound traffic only.

    • Deny Outbound: Blocks outbound traffic only.

    • Permit: Allows traffic (for monitoring purposes).

    Choose Deny Both to block all traffic from this feed.

  • IP Format: Set to Auto.

  • State Order: Leave as Default.

Under the IPv4 Lists Section:

Under Advanced Inbound/Outbound Firewall Rule Settings:

  • Auto Rule Order: Leave as Default.

  • Logging: Enable Log Permit/Block to log entries matching the feed.

  • Click Save and Apply Changes.

Step 4: Apply the Feed to pfBlockerNG

  1. Navigate back to Firewall > pfBlockerNG.

  2. Go to the Update tab.

  3. Click Run to manually update the feed.

  4. Wait for the update process to complete. You should see messages indicating that the feed was successfully pulled and applied.

Step 5: Verify the Feed Integration

  1. Go to Firewall > pfBlockerNG.

  2. Click on the Reports tab.

  3. Check the Alert Logs to see if any IPs from the feed are being blocked.

  4. Alternatively, go to Firewall Logs to see if any traffic is being blocked based on the new feed.

Step 6: Create a Firewall Rule Using the Feed (Optional)

If you want more granular control, you can create custom firewall rules using the feed:

  1. Go to Firewall > Rules.

  2. Click on the Floating tab.

  3. Click Add to create a new rule.

  4. Set the following:

    • Action: Select Block or Reject.

    • Interface: Choose the interface(s) to which this rule applies (e.g., WAN, LAN).

    • Direction: Choose in or out depending on your requirement.

    • Source: Set to Single host or alias.

    • Alias: Select your newly created alias (AbuseFirewall_Bad_IPs).

  5. Click Save and Apply Changes.

Step 7: Test the Feed and Monitor Logs

  1. Go to Status > System Logs.

  2. Check the Firewall logs to see if IPs from the custom feed are being blocked.

  3. Verify that the traffic is being filtered as per the settings.

Additional Considerations:

  • Regular Feed Updates: Ensure that the Update Frequency for the feed is set correctly in pfBlockerNG.

  • Whitelist Critical IPs: If there are certain IPs in the feed that should never be blocked, add them to a Whitelist.

  • Feed Format Compatibility: Ensure that the feed URL is returning a compatible format for pfSense (plain text, CSV, or IP list).

With this setup, your pfSense firewall will automatically pull updates from the custom feed and block/monitor malicious IPs, enhancing your network's security posture.


6 views0 comments

Recent Posts

See All

Comments


bottom of page