Koozali.org: home of the SME Server

Obsolete Releases => SME 7.x Contribs => Topic started by: tspoon1986 on November 05, 2008, 05:42:07 AM

Title: Editing dansguardian.pl has no effect.
Post by: tspoon1986 on November 05, 2008, 05:42:07 AM
Hi,

I'm using Dansguardian on SME Server 7.3. I've just started using the default page rather than HTML, in order to take advantage of the "Submit a site review request" link. However, I want to change the address that the link points to. I've edited /home/e-smith/files/primary/cgi-bin/dansguardian.pl and run signal-event post-upgrade and signal-event reboot, but the links on the page still point to the old address. Can someone please confirm that this is the correct file to edit? If so, I will create a bug report.

Thanks.
Title: Re: Editing dansguardian.pl has no effect.
Post by: Normando on November 05, 2008, 07:02:10 AM
This happens because you are using reportinglevel = 3

Look at dansguardian.conf file:
Quote
# Web Access Denied Reporting (does not affect logging)
#
# -1 = log, but do not block - Stealth mode
#  0 = just say 'Access Denied'
#  1 = report why but not what denied phrase
#  2 = report fully
#  3 = use HTML template file (accessdeniedaddress ignored) - recommended
#
reportinglevel = 3

and below you will see:
Quote
# accessdeniedaddress is the address of your web server to which the cgi
# dansguardian reporting script was copied. Only used in reporting levels 1 and 2.
#
# This webserver must be either:
#  1. Non-proxied. Either a machine on the local network, or listed as an exception
#     in your browser's proxy configuration.
#  2. Added to the exceptionsitelist. Option 1 is preferable; this option is
#     only for users using both transparent proxying and a non-local server
#     to host this script.
#
# Individual filter groups can override this setting in their own configuration.
#
accessdeniedaddress = 'http://xxxxxxxx/cgi-bin/dansguardian.pl'

So you will need to customize the file /languages/the_lang_you_have_set/template.html or change the reportinglevel parameter (Not recomended).
Title: Re: Editing dansguardian.pl has no effect.
Post by: tspoon1986 on November 05, 2008, 11:23:09 PM
Thanks for your reply Normando.

Quote
This happens because you are using reportinglevel = 3

I'm not sure if this is the case. I'm using Dungog's panel to configure dansguardian, and reporting level for the filter group is set to "report fully". Below is a section of /etc/dansguardian/dansguardian.conf:

Code: [Select]
###---------- LOCAL DansGuardian's  settings   ----------###

filterport = 8080
accessdeniedaddress = 'http://obfuscated.com/cgi-bin/dansguardian.pl'
maxuploadsize = -1
filtergroups = 1
loglevel = 3
logfileformat = 3
language = ukenglish

reportinglevel = 1
maxlogitemlength = 300
contentscanner = '/etc/dansguardian/contentscanners/clamdscan.conf'

###---------- Default DansGuardian's settings   ----------###
# DansGuardian config file for version 2.9.9.1,

# **NOTE** as of version 2.7.5 most of the list files are now in dansguardianf1.conf


# Web Access Denied Reporting (does not affect logging)
#
# -1 = log, but do not block - Stealth mode
#  0 = just say 'Access Denied'
#  1 = report why but not what denied phrase
#  2 = report fully
#  3 = use HTML template file (accessdeniedaddress ignored) - recommended
#
reportinglevel = 3

Which reportinglevel takes precedence? The first or second? It seems to me as though it's the cgi-bin script that is displayed when a page is blocked, not the HTML template file.
Title: Re: Editing dansguardian.pl has no effect.
Post by: Normando on November 06, 2008, 03:13:13 AM
hmmmmm...may be dungog bug? I think the second will be removed.
Delete the second "reportinglevel", and use the first. Because this "bug?" you have not see your changes at dansguardian.pl file.
Title: Re: Editing dansguardian.pl has no effect.
Post by: tspoon1986 on November 06, 2008, 05:18:04 AM
Quote
Delete the second "reportinglevel", and use the first.

This didn't work. I'm going to raise a bug report.
Title: Re: Editing dansguardian.pl has no effect.
Post by: tspoon1986 on November 06, 2008, 05:26:01 AM
Bug report raised: http://bugs.contribs.org/show_bug.cgi?id=4745
Title: Re: Editing dansguardian.pl has no effect.
Post by: tspoon1986 on November 10, 2008, 04:33:43 AM
I found out what the problem is. I have two SME Servers running dansguardian on the same domain, however only one of them is a public web server. I didn't realise that when using Dans on the non-web server it actually uses a URL to display the denied page from the web server, so I was editing the file on the wrong server! Thanks for your help Normando.
Title: Re: Editing dansguardian.pl has no effect.
Post by: Normando on November 10, 2008, 05:01:08 AM
I found out what the problem is. I have two SME Servers running dansguardian on the same domain, however only one of them is a public web server. I didn't realise that when using Dans on the non-web server it actually uses a URL to display the denied page from the web server, so I was editing the file on the wrong server! Thanks for your help Normando.

hahaha :lol: :lol: :lol: ..very funny! No offense  :wink: