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

    Dansguardian package for 2.0

    Scheduled Pinned Locked Moved pfSense Packages
    492 Posts 51 Posters 467.3k 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.
    • M
      Macom2007
      last edited by

      I get this error if i want to use Dansguardian :

      dansguardian[723]: Error connecting to proxy

      Squid is installed and running … Any help ?

      1 Reply Last reply Reply Quote 0
      • marcellocM
        marcelloc
        last edited by

        @Macom2007:

        dansguardian[723]: Error connecting to proxy

        Are you listening squid on loopback and configured dansguardian with 127.0.0.1 on port 3128?

        Treinamentos de Elite: http://sys-squad.com

        Help a community developer! ;D

        1 Reply Last reply Reply Quote 0
        • marcellocM
          marcelloc
          last edited by

          @Cino:

          i made a quick rc.d script to start dansguardian on startup..

          You did a second startup or changed current script?

          Can you check if dansguardian default rc script is on the same folder and what permission it has?

          Treinamentos de Elite: http://sys-squad.com

          Help a community developer! ;D

          1 Reply Last reply Reply Quote 0
          • C
            Cino
            last edited by

            @marcelloc:

            @Cino:

            i made a quick rc.d script to start dansguardian on startup..

            You did a second startup or changed current script?

            Can you check if dansguardian default rc script is on the same folder and what permission it has?

            I didn't change the 'dansguardian' script, permissions are 755. I created 'dansguardian.sh' which basically run's '/usr/local/sbin/dansguardian -Q'

            1 Reply Last reply Reply Quote 0
            • marcellocM
              marcelloc
              last edited by

              @Cino:

              I didn't change the 'dansguardian' script, permissions are 755. I created 'dansguardian.sh' which basically run's '/usr/local/sbin/dansguardian -Q'

              Ok. I'll do some tests and/or logs to see what is happening.

              Treinamentos de Elite: http://sys-squad.com

              Help a community developer! ;D

              1 Reply Last reply Reply Quote 0
              • M
                Macom2007
                last edited by

                @marcelloc:

                @Macom2007:

                dansguardian[723]: Error connecting to proxy

                Are you listening squid on loopback and configured dansguardian with 127.0.0.1 on port 3128?

                Yes, Squid and Dansguardian interfaces are LAN/Loopback, Dansguardian is configured with 127.0.0.1:3128. Squid is running without problems.

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

                  @marcelloc:

                  wheelz,

                  some checks:

                  • Make sure pfsense machine name isn't the same name as any user on your active directory

                  • perform a kinit/klist to make sure you have kerberos comunication do active directory before net ads join

                  • Pay attention on . and UPPERCASES of kerberos config files, follow exactly what is on squid howto.

                  att,
                  Marcello Coutinho

                  OK, so now I am getting closer.  After much trial and error I was able to get it to join the domain.  Also now I have wbinfo showing the trust is successful and it can pull users and groups from the domain.  I did the chgrp command, set up the group policy setting for NTLM on Win 7 etc, and added:

                  acl all src 0.0.0.0/0.0.0.0;auth_param ntlm program /usr/local/bin/ntlm_auth –use-cached-creds --helper-protocol=squid-2.5-ntlmssp;auth_param ntlm children 30;auth_param ntlm keep_alive on;acl AuthorizedUsers proxy_auth REQUIRED;http_access allow AuthorizedUsers

                  to the custom options.  Now it mentions removing the "cache_effective_group" setting is squid.conf but how do you do that properly?  I did it manually, but I imagine that will get overridden on the next boot.  Even with that and restarting the services I don't get the user names showing in the access.log.  What am I missing or what should my next steps be?

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

                    One more note… It does look like the user name is showing up in the squid access log.  So it is the dansguardian that isn't picking it up.  Any ideas on that?  Thanks!

                    1 Reply Last reply Reply Quote 0
                    • C
                      Cino
                      last edited by

                      @wheelz:

                      to the custom options.  Now it mentions removing the "cache_effective_group" setting is squid.conf but how do you do that properly?  I did it manually, but I imagine that will get overridden on the next boot.  Even with that and restarting the services I don't get the user names showing in the access.log.  What am I missing or what should my next steps be?

                      if you dont mind hand editing files… edit /usr/local/pkg/squid.inc. Search for 'cache_effective_group' then either remove that line or add comment it out, by adding '# ' in front. Without the quotes tho... They will create the squid.conf file without 'cache_effective_group' on reboots/and restarts

                      1 Reply Last reply Reply Quote 0
                      • marcellocM
                        marcelloc
                        last edited by

                        @wheelz:

                        One more note… It does look like the user name is showing up in the squid access log.  So it is the dansguardian that isn't picking it up.  Any ideas on that?  Thanks!

                        Did you selected ntlm_auth on dansguardian conf?

                        Treinamentos de Elite: http://sys-squad.com

                        Help a community developer! ;D

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

                          Yep, that is enabled.  I even found your comment on the bug log: http://sourceforge.net/support/tracker.php?aid=3462549 in my research as I was looking at multiple authplugins (would be good to be able to enable/disable multiple and order them in the package GUI once the bug is fixed - is this bug fixed?).

                          For now though just trying to get ntlm working.  You were able to get this working correct?  Seems as I have everything working up until dansguardian tries to "sniff" the user information… and I'm kind of stuck.  :(

                          1 Reply Last reply Reply Quote 0
                          • marcellocM
                            marcelloc
                            last edited by

                            I have sucessfull reports with squid on a Linux machine. This is the first feedback with samba on pfsense.

                            I'm having issues with multiplugin patch but I'm not sure if It's a squid3 issue or just the patch.  I'm still working on it.

                            Treinamentos de Elite: http://sys-squad.com

                            Help a community developer! ;D

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

                              If I get it working I'll share the whole process I did to get everything working.  Perhaps some day it could be integrated into this package (or an additional package).

                              I did see this:

                              DansGuardian (but not recent versions of Squid) does not support encrypted Kerberos auth. Even if you correctly configure Squid, Samba, and IE to exchange and validate encrypted Kerberos credentials, DansGuardian will not be able to extract usernames.

                              This restriction does not apply to the Squid “LDAP” helper, as it handles un-encrypted Kerberos credentials in such a way that the exchange between the Broswer and Squid appears to be BASIC authentication.

                              on http://contentfilter.futuragts.com/wiki/doku.php?id=using_ntlm_for_user_identification

                              Could this be the cause of it not working?  I know there was some kerberos configs in the steps I followed.  If so, any ideas on work arounds?

                              1 Reply Last reply Reply Quote 0
                              • marcellocM
                                marcelloc
                                last edited by

                                you may want to try just the samba config options and no kerberos.

                                Treinamentos de Elite: http://sys-squad.com

                                Help a community developer! ;D

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

                                  Hmm…. I see a few other articles about this kind of setup (like http://www.petespcs.co.uk/petespcs/2011/10/dans-guardian-and-ntlm-from-active-directory/ - debian, but still…) and they mention using kerberos.  This seems to indicate that other have this working.  I'm wondering if it has to do with that multiple authplugin bug... I'll see what I can dig up.

                                  1 Reply Last reply Reply Quote 0
                                  • A
                                    abnz
                                    last edited by

                                    @Cino:

                                    @marcelloc:

                                    @Cino:

                                    i made a quick rc.d script to start dansguardian on startup..

                                    You did a second startup or changed current script?

                                    Can you check if dansguardian default rc script is on the same folder and what permission it has?

                                    I didn't change the 'dansguardian' script, permissions are 755. I created 'dansguardian.sh' which basically run's '/usr/local/sbin/dansguardian -Q'

                                    I am having the same error, dansguardian[25631]: Error connecting to proxy.

                                    /usr/local/etc/rc.d/dansguardian

                                    -rwxr-xr-x  1 root  wheel  895 Apr  4 19:31 dansguardian

                                    The service appears to be running but just not working.

                                    run's '/usr/local/sbin/dansguardian -Q' makes no difference, neither a reboot.

                                    Proxy address is 127.0.0.1 port is 3128.

                                    squid works fine, dansguardian just doesn't seem to bind.

                                    I tried uninstalling both squid and dansguardian, deleting conf files, reinstalling squid and testing it.

                                    I then installed dansguardian and still doesnt work.

                                    I suspect its because I installed dansguardian before squid and some config got screwed.  I have not deleted this file before reinstalling?

                                    Appreciate any suggestions.

                                    1 Reply Last reply Reply Quote 0
                                    • C
                                      Cino
                                      last edited by

                                      its not the same error as I was having… I wasn't getting an error at all... Nothing in my logs.

                                      What port did you setup dansguardian on?

                                      Is squid setup to run on loopback or LAN interface?

                                      1 Reply Last reply Reply Quote 0
                                      • marcellocM
                                        marcelloc
                                        last edited by

                                        @wheelz:

                                        This seems to indicate that other have this working.  I'm wondering if it has to do with that multiple authplugin bug… I'll see what I can dig up.

                                        Try to run dansguardian on console to see if there is any running time/config erros

                                        /usr/local/etc/rc.d/dansguardian start

                                        Treinamentos de Elite: http://sys-squad.com

                                        Help a community developer! ;D

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

                                          So it looks like the dansguardian package is forcing 2.7.STABLE9 of squid.  I had installed squid-reverse and that loads 3.1.19.  After Dansguardian it reverts it to the older version.  Is there a way to make it not override existing squid versions or does the dansguardian package have to be updated with the newer squid version?

                                          1 Reply Last reply Reply Quote 0
                                          • marcellocM
                                            marcelloc
                                            last edited by

                                            I could not make this on package, dansguardian force squid install.

                                            What I'm trying to do is compile dansguardian using squid3 as a dependence.

                                            For now, reinstall squid-reverse after you install dansguardian.

                                            Treinamentos de Elite: http://sys-squad.com

                                            Help a community developer! ;D

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