pfSense Gold Subscription

Author Topic: Unofficial E2guardian package for pfSense  (Read 27429 times)

0 Members and 1 Guest are viewing this topic.

Offline marcelloc

  • Hero Member
  • *****
  • Posts: 13398
  • Karma: +589/-7
    • View Profile
Re: Unofficial E2guardian package for pfSense
« Reply #45 on: April 06, 2017, 10:27:24 am »
E2guardian is a daemon, not a squid helper. You need to configure ip, port , forward rules as a normal proxy daemon.

Offline Stewart

  • Full Member
  • ***
  • Posts: 255
  • Karma: +16/-2
    • View Profile
Re: Unofficial E2guardian package for pfSense
« Reply #46 on: April 06, 2017, 04:08:36 pm »
Ah, it's completely independent of Squid, then.  Where does it sit in-line?  I'll check the manuals tomorrow but does it sit between Squid and the user or between Squid and the WAN?  I'm sure the forwards needed are in the documentation so I'll see if I can find the ports needed in the morning.  Thanks for all your help!

Offline marcelloc

  • Hero Member
  • *****
  • Posts: 13398
  • Karma: +589/-7
    • View Profile
Re: Unofficial E2guardian package for pfSense
« Reply #47 on: April 06, 2017, 04:44:55 pm »
Ah, it's completely independent of Squid, then.  Where does it sit in-line?  I'll check the manuals tomorrow but does it sit between Squid and the user or between Squid and the WAN?  I'm sure the forwards needed are in the documentation so I'll see if I can find the ports needed in the morning.  Thanks for all your help!

E2guardian replaces squidguard and in some cases can do all squid job too but it needs a cache peer to fetch urls.


The idea of this package is to have a full-feature replacement for squidguard and depending on you user authentication needs, dansguardian package itsel will do the job as it include tynyproxy for url fetch.
« Last Edit: April 06, 2017, 05:09:36 pm by marcelloc »

Offline marcelloc

  • Hero Member
  • *****
  • Posts: 13398
  • Karma: +589/-7
    • View Profile
Re: Unofficial E2guardian package for pfSense
« Reply #48 on: April 07, 2017, 10:41:31 am »
I've updated the binaries and GUI to include dnsauth and icap antivirus integration. The idea is to call clamv exactly the same way squid does to avoid package conflict.

Offline marcelloc

  • Hero Member
  • *****
  • Posts: 13398
  • Karma: +589/-7
    • View Profile
Re: Unofficial E2guardian package for pfSense
« Reply #49 on: April 07, 2017, 10:45:13 am »
Latest TODO as far as I can see

  • add gui  group ssl options introduced since E2guardian 3.1
  • fix search acl tab and configuration
  • increase tiny proxy config values to March E2guardian start process configuration
  • Configure clamav icap

Offline danjeman

  • Newbie
  • *
  • Posts: 13
  • Karma: +0/-0
    • View Profile
Re: Unofficial E2guardian package for pfSense
« Reply #50 on: April 10, 2017, 11:34:19 am »
A method of configuring it to listen on a CARP address via the GUI would be great too - Squid you can do this from the 'Advanced Features - Custom Options'... or is this not possible with e2g, looks like multi interface listen causes problems at the moment?

Offline marcelloc

  • Hero Member
  • *****
  • Posts: 13398
  • Karma: +589/-7
    • View Profile
Re: Unofficial E2guardian package for pfSense
« Reply #51 on: April 10, 2017, 11:54:44 am »
It looks like multi interface listen causes problems at the moment?

Not anymore. I've hard coded a config option util multi auth psr port is better implemented on gui.

Offline Stewart

  • Full Member
  • ***
  • Posts: 255
  • Karma: +16/-2
    • View Profile
Re: Unofficial E2guardian package for pfSense
« Reply #52 on: April 10, 2017, 02:20:41 pm »
How do we update?  Rerun the script?  That's what I've done and I've got some changes. 
« Last Edit: April 10, 2017, 02:41:19 pm by Stewart »

Offline marcelloc

  • Hero Member
  • *****
  • Posts: 13398
  • Karma: +589/-7
    • View Profile
Re: Unofficial E2guardian package for pfSense
« Reply #53 on: April 10, 2017, 02:59:39 pm »
How do we update?  Rerun the script?  That's what I've done and I've got some changes.

Yes, rerun. Few days ago I've updated the e2guardian binaries to include icap and dnsauth.

Offline Stewart

  • Full Member
  • ***
  • Posts: 255
  • Karma: +16/-2
    • View Profile
Re: Unofficial E2guardian package for pfSense
« Reply #54 on: April 10, 2017, 03:17:19 pm »
I reran the script and suddenly e2Guardian wouldn't load.  The error was:

Code: [Select]
/usr/local/etc/rc.d/e2guardian.sh: WARNING: failed to start e2guardian
Error parsing the e2guardian.conf file or other e2guardian configuration files
Error loading auth plugins
auth_plugin_load() returned NULL pointer with config file: /usr/local/etc/e2guardian/authplugins/proxy-header.conf
Unable read plugin config plugname variable /usr/local/etc/e2guardian/authplugins/proxy-header.conf

I was able to get it to start by uncommenting the last 3 lines in /usr/local/etc/e2guardian/authplugins/proxy-header.conf:
Code: [Select]
low case
header = ''

plugname = 'proxy-header'

Not sure what uncommenting them does but it allows it to load.

Offline Stewart

  • Full Member
  • ***
  • Posts: 255
  • Karma: +16/-2
    • View Profile
Re: Unofficial E2guardian package for pfSense
« Reply #55 on: April 10, 2017, 03:48:40 pm »
Well, it loads but it doesn't do anything.  Whether I try to create a NAT rule or just set the browser to 8080, no pages load.  They all just time out.  I'm watching /var/log/system.log but it isn't showing anything.

Offline marcelloc

  • Hero Member
  • *****
  • Posts: 13398
  • Karma: +589/-7
    • View Profile
Re: Unofficial E2guardian package for pfSense
« Reply #56 on: April 10, 2017, 03:57:19 pm »
I'll what's different from my working e2guardian.  Did you selected any authentication method?

Offline Stewart

  • Full Member
  • ***
  • Posts: 255
  • Karma: +16/-2
    • View Profile
Re: Unofficial E2guardian package for pfSense
« Reply #57 on: April 10, 2017, 04:29:36 pm »
I've tried Proxy-Basic and none.  Now, some pages load.  Others are blocked but show a category of NA.  I also can't get to the pfSense GUI from the local network.  Is there a way to reset to defaults in case I've done something?

Edit:  i am getting a bunch of: 
Code: [Select]
Apr 10 17:25:20 e2guardian 53019 stats reset to freechildren 16 busychildren 2 numchildren 18
Apr 10 17:25:20 e2guardian 53019 freechildren 15 + busychildren 2 != numchildren 18
Apr 10 17:25:20 e2guardian 53019 stats reset to freechildren 16 busychildren 2 numchildren 18
Apr 10 17:25:20 e2guardian 53019 freechildren 16 + busychildren 1 != numchildren 18
Apr 10 17:25:20 e2guardian 53019 stats reset to freechildren 17 busychildren 1 numchildren 18
Apr 10 17:25:21 e2guardian 53019 freechildren 16 + busychildren 1 != numchildren 18
Apr 10 17:25:21 e2guardian 53019 stats reset to freechildren 17 busychildren 1 numchildren 18
Apr 10 17:25:21 e2guardian 53019 freechildren 15 + busychildren 2 != numchildren 18
Apr 10 17:25:21 e2guardian 53019 stats reset to freechildren 16 busychildren 2 numchildren 18
Apr 10 17:25:21 e2guardian 53019 freechildren 14 + busychildren 3 != numchildren 18
Apr 10 17:25:21 e2guardian 53019 stats reset to freechildren 15 busychildren 3 numchildren 18
Apr 10 17:25:21 e2guardian 53019 freechildren 14 + busychildren 3 != numchildren 18
Apr 10 17:25:21 e2guardian 53019 stats reset to freechildren 15 busychildren 3 numchildren 18
Apr 10 17:26:36 e2guardian 53019 freechildren 16 + busychildren 1 != numchildren 18
Apr 10 17:26:36 e2guardian 53019 stats reset to freechildren 17 busychildren 1 numchildren 18
Apr 10 17:26:36 e2guardian 53019 freechildren 16 + busychildren 1 != numchildren 18
Apr 10 17:26:36 e2guardian 53019 stats reset to freechildren 17 busychildren 1 numchildren 18
Apr 10 17:26:36 e2guardian 53019 freechildren 17 + busychildren 0 != numchildren 18
Apr 10 17:26:36 e2guardian 53019 stats reset to freechildren 18 busychildren 0 numchildren 18
Apr 10 17:26:37 e2guardian 53019 freechildren 17 + busychildren 0 != numchildren 18
Apr 10 17:26:37 e2guardian 53019 stats reset to freechildren 18 busychildren 0 numchildren 18
Apr 10 17:26:39 e2guardian 53019 freechildren 17 + busychildren 0 != numchildren 18
Apr 10 17:26:39 e2guardian 53019 stats reset to freechildren 18 busychildren 0 numchildren 18

in the log now.

Offline marcelloc

  • Hero Member
  • *****
  • Posts: 13398
  • Karma: +589/-7
    • View Profile
Re: Unofficial E2guardian package for pfSense
« Reply #58 on: April 10, 2017, 04:47:09 pm »
Unselect any autentication, save and apply(and maybe restart the service). The small documentation on proxy-header says that you must select a http header field to identify as users, and then add them on groups

Code: [Select]
# Proxy-header auth plugin
# FredB August 2016
# Identifies users with header;
# relies upon the upstream proxy.
# Eg: in groups file
# Mozilla/5.0 (Windows NT 6.1; rv:47.0) Gecko/20100101 Firefox/47.0=filter3
# here:
# header = 'user-agent'


Offline danjeman

  • Newbie
  • *
  • Posts: 13
  • Karma: +0/-0
    • View Profile
Re: Unofficial E2guardian package for pfSense
« Reply #59 on: April 11, 2017, 06:04:57 am »
Have updated looks ok so far except on the menus if you go to IPs then ACLs changes to Access Lists - will clear cache etc. and check again...

Don't believe sync has ever worked with the default 'Sync to configured system backup server' either - this is the log entry..

Apr 11 11:57:52   php-fpm   69222   /pkg_edit.php: [E2guardian] xmlrpc sync is enabled but there is no system backup hosts to push squid config.
Apr 11 11:57:52   php-fpm   69222   /pkg_edit.php: Reloading E2guardian

Every other package syncs fine with this setting.