Unterschiede
Hier werden die Unterschiede zwischen zwei Versionen angezeigt.
Beide Seiten der vorigen Revision Vorhergehende Überarbeitung Nächste Überarbeitung | Vorhergehende Überarbeitung | ||
centos:dansg:optimize [15.11.2011 12:44. ] – [Blacklisting von MIME-Types] django | centos:dansg:optimize [17.01.2017 13:45. ] (aktuell) – Externe Bearbeitung 127.0.0.1 | ||
---|---|---|---|
Zeile 1: | Zeile 1: | ||
+ | ====== Optimierung von Dansguardian ====== | ||
+ | {{: | ||
+ | |||
+ | Nachdem wir nun im ersten Schritt die [[centos: | ||
+ | |||
+ | ===== Optimierung von Dansguardian ===== | ||
+ | ==== Anpassung Loglevel ==== | ||
+ | Nach der erfolgten Inbetriebnahme drehen wir dem Dansguardian etwas die Luft ab, was heissen will, wir lassen uns nur noch die geblockten Seiten reporten, da das Logfile ggf. etwas arg überschwemmt wird mit Informationen, | ||
+ | # vim / | ||
+ | < | ||
+ | # | ||
+ | # 0 = none 1 = just denied | ||
+ | # Django 2011-11-15 Anpassen des Log-Levels | ||
+ | # default : loglevel = 2 | ||
+ | loglevel = 1 | ||
+ | </ | ||
+ | ==== Anpassung Authentication ==== | ||
+ | Damit in den Logfiles die **User** angezeigt werden können, aktivieren wir noch die Option __**Auth plugins**__ in der Konfigurationsdatei // | ||
+ | # vim / | ||
+ | < | ||
+ | # These replace the usernameidmethod* options in previous versions. They | ||
+ | # handle the extraction of client usernames from various sources, such as | ||
+ | # Proxy-Authorisation headers and ident servers, enabling requests to be | ||
+ | # handled according to the settings of the user's filter group. | ||
+ | # Multiple plugins can be specified, and will be queried in order until one | ||
+ | # of them either finds a username or throws an error. For example, if Squid | ||
+ | # is configured with both NTLM and Basic auth enabled, and both the ' | ||
+ | # and ' | ||
+ | # NTLM can fall back to Basic without sacrificing access rights. | ||
+ | # | ||
+ | # If you do not use multiple filter groups, you need not specify this option. | ||
+ | # | ||
+ | authplugin = '/ | ||
+ | An der aktiverten **proxy-basic.conf** ist weiter nichts zu ändern. | ||
+ | |||
+ | <file bash / | ||
+ | # Proxy-Basic auth plugin | ||
+ | # Identifies usernames in " | ||
+ | # relies upon the upstream proxy (squid) to perform the actual password check. | ||
+ | |||
+ | plugname = ' | ||
+ | </ | ||
+ | Ein anschließender Restart aktiviert unsere Änderungen. | ||
+ | # service dansguardian restart | ||
+ | Somit werden nunmehr die Usernamen im Logfile mit ausgegeben und wir können später nach Bedarf, nach einzelnen Usern greppen. | ||
+ | | ||
+ | |||
+ | Die Hauptkonfigurationsdatei // | ||
+ | <file bash / | ||
+ | # DansGuardian config file for version 2.10.1.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 ' | ||
+ | # 1 = report why but not what denied phrase | ||
+ | # 2 = report fully | ||
+ | # 3 = use HTML template file (accessdeniedaddress ignored) - recommended | ||
+ | # | ||
+ | reportinglevel = 3 | ||
+ | |||
+ | # Language dir where languages are stored for internationalisation. | ||
+ | # The HTML template within this dir is only used when reportinglevel | ||
+ | # is set to 3. When used, DansGuardian will display the HTML file instead of | ||
+ | # using the perl cgi script. | ||
+ | # and easier to customise the access denied page. | ||
+ | # The language file is used no matter what setting however. | ||
+ | # | ||
+ | languagedir = '/ | ||
+ | |||
+ | # language to use from languagedir. | ||
+ | # Django 2011-11-15 | ||
+ | # Default: language = ' | ||
+ | language = ' | ||
+ | |||
+ | # Logging Settings | ||
+ | # | ||
+ | # 0 = none 1 = just denied | ||
+ | # Django 2011-11-15 Anpassen des Log-Levels | ||
+ | # default : loglevel = 2 | ||
+ | loglevel = 1 | ||
+ | |||
+ | # Log Exception Hits | ||
+ | # Log if an exception (user, ip, URL, phrase) is matched and so | ||
+ | # the page gets let through. | ||
+ | # why a site gets through the filter. | ||
+ | # 0 = never log exceptions | ||
+ | # 1 = log exceptions, but do not explicitly mark them as such | ||
+ | # 2 = always log & mark exceptions (default) | ||
+ | logexceptionhits = 2 | ||
+ | |||
+ | # Log File Format | ||
+ | # 1 = DansGuardian format (space delimited) | ||
+ | # 2 = CSV-style format | ||
+ | # 3 = Squid Log File Format | ||
+ | # 4 = Tab delimited | ||
+ | logfileformat = 1 | ||
+ | |||
+ | # truncate large items in log lines | ||
+ | # | ||
+ | |||
+ | # anonymize logs (blank out usernames & IPs) | ||
+ | # | ||
+ | |||
+ | |||
+ | # Syslog logging | ||
+ | # | ||
+ | # Use syslog for access logging instead of logging to the file | ||
+ | # at the defined or built-in " | ||
+ | #syslog = on | ||
+ | |||
+ | # Log file location | ||
+ | # | ||
+ | # Defines the log directory and filename. | ||
+ | # | ||
+ | |||
+ | |||
+ | # Statistics log file location | ||
+ | # | ||
+ | # Defines the stat file directory and filename. | ||
+ | # Only used in conjunction with maxips > 0 | ||
+ | # Once every 3 minutes, the current number of IPs in the cache, and the most | ||
+ | # that have been in the cache since the daemon was started, are written to this | ||
+ | # file. IPs persist in the cache for 7 days. | ||
+ | # | ||
+ | |||
+ | |||
+ | # Network Settings | ||
+ | # | ||
+ | # the IP that DansGuardian listens on. If left blank DansGuardian will | ||
+ | # listen on all IPs. That would include all NICs, loopback, modem, etc. | ||
+ | # Normally you would have your firewall protecting this, but if you want | ||
+ | # you can limit it to a certain IP. To bind to multiple interfaces, | ||
+ | # specify each IP on an individual filterip line. | ||
+ | filterip = | ||
+ | |||
+ | # the port that DansGuardian listens to. | ||
+ | filterport = 8080 | ||
+ | |||
+ | # the ip of the proxy (default is the loopback - i.e. this server) | ||
+ | proxyip = 127.0.0.1 | ||
+ | |||
+ | # the port DansGuardian connects to proxy on | ||
+ | proxyport = 3128 | ||
+ | |||
+ | # Whether to retrieve the original destination IP in transparent proxy | ||
+ | # setups and check it against the domain pulled from the HTTP headers. | ||
+ | # | ||
+ | # Be aware that when visiting sites which use a certain type of round-robin | ||
+ | # DNS for load balancing, DG may mark requests as invalid unless DG gets | ||
+ | # exactly the same answers to its DNS requests as clients. | ||
+ | # this happening can be increased if all clients and servers on the same LAN | ||
+ | # make use of a local, caching DNS server instead of using upstream DNS | ||
+ | # directly. | ||
+ | # | ||
+ | # See http:// | ||
+ | # on (default) | off | ||
+ | #!! Not compiled !! originalip = on | ||
+ | |||
+ | # 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' | ||
+ | # 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. | ||
+ | # | ||
+ | # Django 2011-11-15 | ||
+ | # default : accessdeniedaddress = ' | ||
+ | # accessdeniedaddress = ' | ||
+ | |||
+ | |||
+ | # Non standard delimiter (only used with accessdeniedaddress) | ||
+ | # To help preserve the full banned URL, including parameters, the variables | ||
+ | # passed into the access denied CGI are separated using non-standard | ||
+ | # delimiters. This can be useful to ensure correct operation of the filter | ||
+ | # bypass modes. Parameters are split using "::" | ||
+ | # place of " | ||
+ | # Default is enabled, but to go back to the standard mode, disable it. | ||
+ | nonstandarddelimiter = on | ||
+ | |||
+ | |||
+ | |||
+ | # Banned image replacement | ||
+ | # Images that are banned due to domain/ | ||
+ | # in the adverts blacklists can be replaced by an image. | ||
+ | # for example, hide images from advert sites and remove broken image | ||
+ | # icons from banned domains. | ||
+ | # on (default) | off | ||
+ | usecustombannedimage = on | ||
+ | custombannedimagefile = '/ | ||
+ | |||
+ | |||
+ | |||
+ | # Filter groups options | ||
+ | # filtergroups sets the number of filter groups. A filter group is a set of content | ||
+ | # filtering options you can apply to a group of users. | ||
+ | # DansGuardian will automatically look for dansguardianfN.conf where N is the filter | ||
+ | # group. | ||
+ | # to filter group 1. You must have some sort of authentication to be able to map users | ||
+ | # to a group. | ||
+ | # use as few as possible. | ||
+ | filtergroups = 1 | ||
+ | filtergroupslist = '/ | ||
+ | |||
+ | |||
+ | |||
+ | # Authentication files location | ||
+ | bannediplist = '/ | ||
+ | exceptioniplist = '/ | ||
+ | |||
+ | |||
+ | |||
+ | # Show weighted phrases found | ||
+ | # If enabled then the phrases found that made up the total which excedes | ||
+ | # the naughtyness limit will be logged and, if the reporting level is | ||
+ | # high enough, reported. on | off | ||
+ | showweightedfound = on | ||
+ | |||
+ | # Weighted phrase mode | ||
+ | # There are 3 possible modes of operation: | ||
+ | # 0 = off = do not use the weighted phrase feature. | ||
+ | # 1 = on, normal = normal weighted phrase operation. | ||
+ | # 2 = on, singular = each weighted phrase found only counts once on a page. | ||
+ | # | ||
+ | weightedphrasemode = 2 | ||
+ | |||
+ | |||
+ | |||
+ | # Positive (clean) result caching for URLs | ||
+ | # Caches good pages so they don't need to be scanned again. | ||
+ | # It also works with AV plugins. | ||
+ | # 0 = off (recommended for ISPs with users with disimilar browsing) | ||
+ | # 1000 = recommended for most users | ||
+ | # 5000 = suggested max upper limit | ||
+ | # If you're using an AV plugin then use at least 5000. | ||
+ | urlcachenumber = 1000 | ||
+ | # | ||
+ | # Age before they are stale and should be ignored in seconds | ||
+ | # 0 = never | ||
+ | # 900 = recommended = 15 mins | ||
+ | urlcacheage = 900 | ||
+ | |||
+ | |||
+ | |||
+ | # Clean cache for content (AV) scan results | ||
+ | # By default, to save CPU, files scanned and found to be | ||
+ | # clean are inserted into the clean cache and NOT scanned | ||
+ | # again for a while. | ||
+ | # to disable it. | ||
+ | # (on|off) default = on. | ||
+ | scancleancache = on | ||
+ | |||
+ | |||
+ | |||
+ | # Smart, Raw and Meta/Title phrase content filtering options | ||
+ | # Smart is where the multiple spaces and HTML are removed before phrase filtering | ||
+ | # Raw is where the raw HTML including meta tags are phrase filtered | ||
+ | # Meta/Title is where only meta and title tags are phrase filtered (v. quick) | ||
+ | # CPU usage can be effectively halved by using setting 0 or 1 compared to 2 | ||
+ | # 0 = raw only | ||
+ | # 1 = smart only | ||
+ | # 2 = both of the above (default) | ||
+ | # 3 = meta/title | ||
+ | phrasefiltermode = 2 | ||
+ | |||
+ | # Lower casing options | ||
+ | # When a document is scanned the uppercase letters are converted to lower case | ||
+ | # in order to compare them with the phrases. | ||
+ | # other 16-bit texts. | ||
+ | # characters are supported. | ||
+ | # 0 = force lower case (default) | ||
+ | # 1 = do not change case | ||
+ | # 2 = scan first in lower case, then in original case | ||
+ | preservecase = 0 | ||
+ | |||
+ | # Note: | ||
+ | # If phrasefiltermode and preserve case are both 2, this equates to 4 phrase | ||
+ | # filtering passes. If you have a large enough userbase for this to be a | ||
+ | # worry, and need to filter pages in exotic character encodings, it may be | ||
+ | # better to run two instances on separate servers: one with preservecase 1 | ||
+ | # (and possibly forcequicksearch 1) and non ASCII/UTF-8 phrase lists, and one | ||
+ | # with preservecase 0 and ASCII/UTF-8 lists. | ||
+ | |||
+ | |||
+ | |||
+ | # Hex decoding options | ||
+ | # When a document is scanned it can optionally convert %XX to chars. | ||
+ | # If you find documents are getting past the phrase filtering due to encoding | ||
+ | # then enable. | ||
+ | # off = disabled (default) | ||
+ | # on = enabled | ||
+ | hexdecodecontent = off | ||
+ | |||
+ | |||
+ | |||
+ | # Force Quick Search rather than DFA search algorithm | ||
+ | # The current DFA implementation is not totally 16-bit character compatible | ||
+ | # but is used by default as it handles large phrase lists much faster. | ||
+ | # If you wish to use a large number of 16-bit character phrases then | ||
+ | # enable this option. | ||
+ | # off (default) | on (Big5 compatible) | ||
+ | forcequicksearch = off | ||
+ | |||
+ | |||
+ | |||
+ | # Reverse lookups for banned site and URLs. | ||
+ | # If set to on, DansGuardian will look up the forward DNS for an IP URL | ||
+ | # address and search for both in the banned site and URL lists. | ||
+ | # prevent a user from simply entering the IP for a banned address. | ||
+ | # It will reduce searching speed somewhat so unless you have a local caching | ||
+ | # DNS server, leave it off and use the Blanket IP Block option in the | ||
+ | # bannedsitelist file instead. | ||
+ | reverseaddresslookups = off | ||
+ | |||
+ | |||
+ | |||
+ | # Reverse lookups for banned and exception IP lists. | ||
+ | # If set to on, DansGuardian will look up the forward DNS for the IP | ||
+ | # of the connecting computer. | ||
+ | # the exceptioniplist and bannediplist. | ||
+ | # If a client computer is matched against an IP given in the lists, then the | ||
+ | # IP will be recorded in any log entries; if forward DNS is successful and a | ||
+ | # match occurs against a hostname, the hostname will be logged instead. | ||
+ | # It will reduce searching speed somewhat so unless you have a local DNS server, | ||
+ | # leave it off. | ||
+ | reverseclientiplookups = off | ||
+ | |||
+ | |||
+ | # Perform reverse lookups on client IPs for successful requests. | ||
+ | # If set to on, DansGuardian will look up the forward DNS for the IP | ||
+ | # of the connecting computer, and log host names (where available) rather than | ||
+ | # IPs against requests. | ||
+ | # This is not dependent on reverseclientiplookups being enabled; however, if it | ||
+ | # is, enabling this option does not incur any additional forward DNS requests. | ||
+ | logclienthostnames = off | ||
+ | |||
+ | |||
+ | # Build bannedsitelist and bannedurllist cache files. | ||
+ | # This will compare the date stamp of the list file with the date stamp of | ||
+ | # the cache file and will recreate as needed. | ||
+ | # If a bsl or bul .processed file exists, then that will be used instead. | ||
+ | # It will increase process start speed by 300%. On slow computers this will | ||
+ | # be significant. | ||
+ | createlistcachefiles = on | ||
+ | |||
+ | |||
+ | |||
+ | # POST protection (web upload and forms) | ||
+ | # does not block forms without any file upload, i.e. this is just for | ||
+ | # blocking or limiting uploads | ||
+ | # measured in kibibytes after MIME encoding and header bumph | ||
+ | # use 0 for a complete block | ||
+ | # use higher (e.g. 512 = 512Kbytes) for limiting | ||
+ | # use -1 for no blocking | ||
+ | # | ||
+ | # | ||
+ | maxuploadsize = -1 | ||
+ | |||
+ | |||
+ | |||
+ | # Max content filter size | ||
+ | # Sometimes web servers label binary files as text which can be very | ||
+ | # large which causes a huge drain on memory and cpu resources. | ||
+ | # To counter this, you can limit the size of the document to be | ||
+ | # filtered and get it to just pass it straight through. | ||
+ | # This setting also applies to content regular expression modification. | ||
+ | # The value must not be higher than maxcontentramcachescansize | ||
+ | # The size is in Kibibytes - eg 2048 = 2Mb | ||
+ | # use 0 to set it to maxcontentramcachescansize | ||
+ | maxcontentfiltersize = 256 | ||
+ | |||
+ | |||
+ | |||
+ | # Max content ram cache scan size | ||
+ | # This is only used if you use a content scanner plugin such as AV | ||
+ | # This is the max size of file that DG will download and cache | ||
+ | # in RAM. After this limit is reached it will cache to disk | ||
+ | # This value must be less than or equal to maxcontentfilecachescansize. | ||
+ | # The size is in Kibibytes - eg 10240 = 10Mb | ||
+ | # use 0 to set it to maxcontentfilecachescansize | ||
+ | # This option may be ignored by the configured download manager. | ||
+ | maxcontentramcachescansize = 2000 | ||
+ | |||
+ | |||
+ | |||
+ | # Max content file cache scan size | ||
+ | # This is only used if you use a content scanner plugin such as AV | ||
+ | # This is the max size file that DG will download | ||
+ | # so that it can be scanned or virus checked. | ||
+ | # This value must be greater or equal to maxcontentramcachescansize. | ||
+ | # The size is in Kibibytes - eg 10240 = 10Mb | ||
+ | maxcontentfilecachescansize = 20000 | ||
+ | |||
+ | |||
+ | |||
+ | # File cache dir | ||
+ | # Where DG will download files to be scanned if too large for the | ||
+ | # RAM cache. | ||
+ | filecachedir = '/ | ||
+ | |||
+ | |||
+ | |||
+ | # Delete file cache after user completes download | ||
+ | # When a file gets save to temp it stays there until it is deleted. | ||
+ | # You can choose to have the file deleted when the user makes a sucessful | ||
+ | # download. | ||
+ | # the temp store a second time it will give a 404 error. | ||
+ | # You should configure something to delete old files in temp to stop it filling up. | ||
+ | # on|off (defaults to on) | ||
+ | deletedownloadedtempfiles = on | ||
+ | |||
+ | |||
+ | |||
+ | # Initial Trickle delay | ||
+ | # This is the number of seconds a browser connection is left waiting | ||
+ | # before first being sent *something* to keep it alive. | ||
+ | # *something* depends on the download manager chosen. | ||
+ | # Do not choose a value too low or normal web pages will be affected. | ||
+ | # A value between 20 and 110 would be sensible | ||
+ | # This may be ignored by the configured download manager. | ||
+ | initialtrickledelay = 20 | ||
+ | |||
+ | |||
+ | |||
+ | # Trickle delay | ||
+ | # This is the number of seconds a browser connection is left waiting | ||
+ | # before being sent more *something* to keep it alive. | ||
+ | # *something* depends on the download manager chosen. | ||
+ | # This may be ignored by the configured download manager. | ||
+ | trickledelay = 10 | ||
+ | |||
+ | |||
+ | |||
+ | # Download Managers | ||
+ | # These handle downloads of files to be filtered and scanned. | ||
+ | # They differ in the method they deal with large downloads. | ||
+ | # Files usually need to be downloaded 100% before they can be | ||
+ | # filtered and scanned before being sent on to the browser. | ||
+ | # Normally the browser can just wait, but with content scanning, | ||
+ | # for example to AV, the browser may timeout or the user may get | ||
+ | # confused so the download manager has to do some sort of | ||
+ | # 'keep alive' | ||
+ | # | ||
+ | # There are various methods possible but not all are included. | ||
+ | # The author does not have the time to write them all so I have | ||
+ | # included a plugin systam. | ||
+ | # browsers and clients. | ||
+ | # work with software that downloads updates. | ||
+ | # each plugin can support a regular expression for matching | ||
+ | # the client' | ||
+ | # and extensions it should manage. | ||
+ | # | ||
+ | # Note that these are the matching methods provided by the base plugin | ||
+ | # code, and individual plugins may override or add to them. | ||
+ | # See the individual plugin conf files for supported options. | ||
+ | # | ||
+ | # The plugins are matched in the order you specify and the last | ||
+ | # one is forced to match as the default, regardless of user agent | ||
+ | # and other matching mechanisms. | ||
+ | # | ||
+ | downloadmanager = '/ | ||
+ | # | ||
+ | downloadmanager = '/ | ||
+ | |||
+ | |||
+ | |||
+ | # Content Scanners (Also known as AV scanners) | ||
+ | # These are plugins that scan the content of all files your browser fetches | ||
+ | # for example to AV scan. The options are limitless. | ||
+ | # DansGuardian will be plugin based. | ||
+ | # scanner. The plugins are run in the order you specify. | ||
+ | # This is one of the few places you can have multiple options of the same name. | ||
+ | # | ||
+ | # Some of the scanner(s) require 3rd party software and libraries eg clamav. | ||
+ | # See the individual plugin conf file for more options (if any). | ||
+ | # | ||
+ | #!! Not compiled !! contentscanner = '/ | ||
+ | # | ||
+ | #!! Unimplemented !! contentscanner = '/ | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | |||
+ | |||
+ | |||
+ | # Content scanner timeout | ||
+ | # Some of the content scanners support using a timeout value to stop | ||
+ | # processing (eg AV scanning) the file if it takes too long. | ||
+ | # If supported this will be used. | ||
+ | # The default of 60 seconds is probably reasonable. | ||
+ | contentscannertimeout = 60 | ||
+ | |||
+ | |||
+ | |||
+ | # Content scan exceptions | ||
+ | # If ' | ||
+ | # This is probably not desirable behavour as exceptions are | ||
+ | # supposed to be trusted and will increase load. | ||
+ | # Correct use of grey lists are a better idea. | ||
+ | # (on|off) default = off | ||
+ | contentscanexceptions = off | ||
+ | |||
+ | |||
+ | |||
+ | # Auth plugins | ||
+ | # These replace the usernameidmethod* options in previous versions. They | ||
+ | # handle the extraction of client usernames from various sources, such as | ||
+ | # Proxy-Authorisation headers and ident servers, enabling requests to be | ||
+ | # handled according to the settings of the user's filter group. | ||
+ | # Multiple plugins can be specified, and will be queried in order until one | ||
+ | # of them either finds a username or throws an error. For example, if Squid | ||
+ | # is configured with both NTLM and Basic auth enabled, and both the ' | ||
+ | # and ' | ||
+ | # NTLM can fall back to Basic without sacrificing access rights. | ||
+ | # | ||
+ | # If you do not use multiple filter groups, you need not specify this option. | ||
+ | # | ||
+ | #authplugin = '/ | ||
+ | #authplugin = '/ | ||
+ | #authplugin = '/ | ||
+ | #authplugin = '/ | ||
+ | #authplugin = '/ | ||
+ | # Django 2011-11-15 Username im Logfile mit ausgeben | ||
+ | # default : NULL | ||
+ | authplugin = '/ | ||
+ | |||
+ | # Re-check replaced URLs | ||
+ | # As a matter of course, URLs undergo regular expression search/ | ||
+ | # *after* checking the exception site/ | ||
+ | # the banned site/URL lists, allowing certain requests that would be matched against the | ||
+ | # latter in their original state to effectively be converted into grey requests. | ||
+ | # With this option enabled, the exception site/ | ||
+ | # after replacement, | ||
+ | # on them. | ||
+ | # Defaults to off. | ||
+ | recheckreplacedurls = off | ||
+ | |||
+ | |||
+ | |||
+ | # Misc settings | ||
+ | |||
+ | # if on it adds an X-Forwarded-For: | ||
+ | # header. | ||
+ | # source ip. on | off | ||
+ | forwardedfor = off | ||
+ | |||
+ | |||
+ | # if on it uses the X-Forwarded-For: | ||
+ | # IP. This is for when you have squid between the clients and DansGuardian. | ||
+ | # Warning - headers are easily spoofed. on | off | ||
+ | usexforwardedfor = off | ||
+ | |||
+ | |||
+ | # if on it logs some debug info regarding fork()ing and accept()ing which | ||
+ | # can usually be ignored. | ||
+ | # it on or off | ||
+ | logconnectionhandlingerrors = on | ||
+ | |||
+ | |||
+ | |||
+ | # Fork pool options | ||
+ | |||
+ | # If on, this causes DG to write to the log file whenever child processes are | ||
+ | # created or destroyed (other than by crashes). This information can help in | ||
+ | # understanding and tuning the following parameters, but is not generally | ||
+ | # useful in production. | ||
+ | logchildprocesshandling = off | ||
+ | |||
+ | # sets the maximum number of processes to spawn to handle the incoming | ||
+ | # connections. | ||
+ | # On large sites you might want to try 180. | ||
+ | maxchildren = 120 | ||
+ | |||
+ | |||
+ | # sets the minimum number of processes to spawn to handle the incoming connections. | ||
+ | # On large sites you might want to try 32. | ||
+ | minchildren = 8 | ||
+ | |||
+ | |||
+ | # sets the minimum number of processes to be kept ready to handle connections. | ||
+ | # On large sites you might want to try 8. | ||
+ | minsparechildren = 4 | ||
+ | |||
+ | |||
+ | # sets the minimum number of processes to spawn when it runs out | ||
+ | # On large sites you might want to try 10. | ||
+ | preforkchildren = 6 | ||
+ | |||
+ | |||
+ | # sets the maximum number of processes to have doing nothing. | ||
+ | # When this many are spare it will cull some of them. | ||
+ | # On large sites you might want to try 64. | ||
+ | maxsparechildren = 32 | ||
+ | |||
+ | |||
+ | # sets the maximum age of a child process before it croaks it. | ||
+ | # This is the number of connections they handle before exiting. | ||
+ | # On large sites you might want to try 10000. | ||
+ | maxagechildren = 500 | ||
+ | |||
+ | |||
+ | # Sets the maximum number client IP addresses allowed to connect at once. | ||
+ | # Use this to set a hard limit on the number of users allowed to concurrently | ||
+ | # browse the web. Set to 0 for no limit, and to disable the IP cache process. | ||
+ | maxips = 0 | ||
+ | |||
+ | |||
+ | |||
+ | # Process options | ||
+ | # (Change these only if you really know what you are doing). | ||
+ | # These options allow you to run multiple instances of DansGuardian on a single machine. | ||
+ | # Remember to edit the log file path above also if that is your intention. | ||
+ | |||
+ | # IPC filename | ||
+ | # | ||
+ | # Defines IPC server directory and filename used to communicate with the log process. | ||
+ | ipcfilename = '/ | ||
+ | |||
+ | # URL list IPC filename | ||
+ | # | ||
+ | # Defines URL list IPC server directory and filename used to communicate with the URL | ||
+ | # cache process. | ||
+ | urlipcfilename = '/ | ||
+ | |||
+ | # IP list IPC filename | ||
+ | # | ||
+ | # Defines IP list IPC server directory and filename, for communicating with the client | ||
+ | # IP cache process. | ||
+ | ipipcfilename = '/ | ||
+ | |||
+ | # PID filename | ||
+ | # | ||
+ | # Defines process id directory and filename. | ||
+ | # | ||
+ | |||
+ | # Disable daemoning | ||
+ | # If enabled the process will not fork into the background. | ||
+ | # It is not usually advantageous to do this. | ||
+ | # on|off (defaults to off) | ||
+ | nodaemon = off | ||
+ | |||
+ | # Disable logging process | ||
+ | # on|off (defaults to off) | ||
+ | nologger = off | ||
+ | |||
+ | # Enable logging of " | ||
+ | # on|off (defaults to off) | ||
+ | logadblocks = off | ||
+ | |||
+ | # Enable logging of client User-Agent | ||
+ | # Some browsers will cause a *lot* of extra information on each line! | ||
+ | # on|off (defaults to off) | ||
+ | loguseragent = off | ||
+ | |||
+ | # Daemon runas user and group | ||
+ | # This is the user that DansGuardian runs as. Normally the user/group nobody. | ||
+ | # Uncomment to use. Defaults to the user set at compile time. | ||
+ | # Temp files created during virus scanning are given owner and group read | ||
+ | # permissions; | ||
+ | # clamdscan, the two processes must run with either the same group or user ID. | ||
+ | #daemonuser = ' | ||
+ | # | ||
+ | |||
+ | # Soft restart | ||
+ | # When on this disables the forced killing off all processes in the process group. | ||
+ | # This is not to be confused with the -g run time option - they are not related. | ||
+ | # on|off (defaults to off) | ||
+ | softrestart = off | ||
+ | |||
+ | # Mail program | ||
+ | # Path (sendmail-compatible) email program, with options. | ||
+ | # Not used if usesmtp is disabled (filtergroup specific). | ||
+ | mailer = '/ | ||
+ | |||
+ | </ | ||
+ | ==== Site-Whitelisting ==== | ||
+ | Von Haus aus, ist der „ausgelieferte“ Dansguardian doch recht aggressiv eingestellt; | ||
+ | # vim / | ||
+ | <file bash / | ||
+ | #Sites in exception list | ||
+ | #Don't bother with the www. or | ||
+ | #the http:// | ||
+ | # | ||
+ | #These are specifically domains and are not URLs. | ||
+ | #For example ' | ||
+ | #to just have ' | ||
+ | # | ||
+ | #You can also match IPs here too. | ||
+ | # | ||
+ | #As of DansGuardian 2.7.3 you can now include | ||
+ | #.tld so for example you can match .gov for example | ||
+ | |||
+ | |||
+ | # Time limiting syntax: | ||
+ | # #time: <start hour> <start minute> <end hour> <end minute> < | ||
+ | # Example: | ||
+ | ##time: 9 0 17 0 01234 | ||
+ | # Remove the first # from the line above to enable this list only from | ||
+ | # 9am to 5pm, Monday to Friday. | ||
+ | |||
+ | |||
+ | # Blanket exception. | ||
+ | # exceptionsitelist and greysitelist files, remove | ||
+ | # the # from the next line to leave only a ' | ||
+ | #** | ||
+ | |||
+ | # Blanket SSL/CONNECT exception. | ||
+ | # and CONNECT tunnels except to addresses in the | ||
+ | # exceptionsitelist and greysitelist files, remove | ||
+ | # the # from the next line to leave only a ' | ||
+ | #**s | ||
+ | |||
+ | # Blanket IP exception. | ||
+ | # remove the # from the next line to leave only a ' | ||
+ | #*ip | ||
+ | |||
+ | # Blanket SSL/CONNECT IP exception. | ||
+ | # tunnels to sites specified only as an IP, | ||
+ | # remove the # from the next line to leave only a ' | ||
+ | #*ips | ||
+ | |||
+ | |||
+ | windowsupdate.microsoft.com | ||
+ | # Django 2011-11-15 | ||
+ | # Nutzerindividuelle Seiten | ||
+ | nausch.org | ||
+ | urlblacklist.com | ||
+ | ebay.de | ||
+ | bay.com | ||
+ | </ | ||
+ | ==== Site-Blacklisting ==== | ||
+ | Genauso kann man natürlich auch unerwünschte Seiten komplett sperren. Hierzu bearbeiten wir die Konfigurationsdatei // | ||
+ | # vim / | ||
+ | <file bash / | ||
+ | #domains in banned list | ||
+ | #Don't bother with the www. or the http:// | ||
+ | |||
+ | #The bannedurllist is for blocking PART of a site | ||
+ | #The bannedsitelist is for blocking ALL of a site | ||
+ | |||
+ | #As of DansGuardian 2.7.3 you can now include | ||
+ | #.tld so for example you can match .gov for example | ||
+ | |||
+ | #The ' | ||
+ | #The ' | ||
+ | #The difference is that the ' | ||
+ | #off *all* other filtering for the match. | ||
+ | #stop the URL filtering and allow the normal filtering to work. | ||
+ | |||
+ | #An example of grey list use is when in Blanket Block (whitelist) | ||
+ | #mode and you want to allow some sites but still filter as normal | ||
+ | #on their content | ||
+ | |||
+ | #Another example of grey list use is when you ban a site but want | ||
+ | #to allow part of it. | ||
+ | |||
+ | #To include additional files in this list use this example: | ||
+ | # | ||
+ | |||
+ | #You can have multiple .Includes. | ||
+ | |||
+ | # Time limiting syntax: | ||
+ | # #time: <start hour> <start minute> <end hour> <end minute> < | ||
+ | # Example: | ||
+ | ##time: 9 0 17 0 01234 | ||
+ | # Remove the first # from the line above to enable this list only from | ||
+ | # 9am to 5pm, Monday to Friday. | ||
+ | |||
+ | # List categorisation | ||
+ | # | ||
+ | |||
+ | #List other sites to block: | ||
+ | |||
+ | badboys.com | ||
+ | |||
+ | # Django 2011-11-15 | ||
+ | # Nutzerindividuelle gesperrte Seiten blocklists | ||
+ | |||
+ | microsoft.com | ||
+ | cdu.de | ||
+ | csu.de | ||
+ | spd.de | ||
+ | ftp.de | ||
+ | |||
+ | #Blanket Block. | ||
+ | # | ||
+ | #the # from the next line to leave only a ' | ||
+ | #** | ||
+ | |||
+ | #Blanket SSL/CONNECT Block. | ||
+ | #and CONNECT tunnels except to addresses in the | ||
+ | # | ||
+ | #the # from the next line to leave only a ' | ||
+ | #**s | ||
+ | |||
+ | #Blanket IP Block. | ||
+ | #remove the # from the next line to leave only a ' | ||
+ | #*ip | ||
+ | |||
+ | #Blanket SSL/CONNECT IP Block. | ||
+ | #tunnels to sites specified only as an IP, | ||
+ | #remove the # from the next line to leave only a ' | ||
+ | #*ips | ||
+ | |||
+ | |||
+ | # The squidGuard advert domain/URL lists are now included by default. | ||
+ | # To work with advanced ad blocking & the logadblocks option, advert | ||
+ | # phrase/ | ||
+ | .Include</ | ||
+ | |||
+ | #Remove the # from the following and edit as needed to use a stock | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | |||
+ | # You will need to edit to add and remove categories you want | ||
+ | </ | ||
+ | |||
+ | ==== Host-Whitelisting ==== | ||
+ | Möchte man einen Host im Netz gänzlich von der Bewertung ausnehmen, so z.B. für die Geschäftsleitung und/oder Betriebs-/ | ||
+ | # vim / | ||
+ | <file bash / | ||
+ | # IP addresses of computers from which | ||
+ | # web access should not be filtered. | ||
+ | # | ||
+ | # These would be servers which | ||
+ | # need unfiltered access for | ||
+ | # updates. | ||
+ | # workstations which need to | ||
+ | # download programs and check | ||
+ | # out blocked sites should be | ||
+ | # put here. | ||
+ | # | ||
+ | # Hostnames are allowed here, provided you | ||
+ | # enable the reverseclientlookups option. | ||
+ | # | ||
+ | # This is not the IP of web servers | ||
+ | # you don't want to filter. | ||
+ | |||
+ | # | ||
+ | # | ||
+ | # | ||
+ | |||
+ | # Ranges and subnets can also be used, | ||
+ | # e.g. | ||
+ | # 10.0.0.1-10.0.0.3 | ||
+ | # 10.0.0.0/24 | ||
+ | # | ||
+ | # Hostnames can also be used, provided | ||
+ | # you cater for reverse DNS lookups | ||
+ | # on your LAN and enable the | ||
+ | # " | ||
+ | # dansguardian.conf | ||
+ | # | ||
+ | # Django 2011-11-15 | ||
+ | # BOfH's Workstation bei der Bewertung ausnehmen | ||
+ | 10.10.10.10 | ||
+ | </ | ||
+ | |||
+ | ==== Host-Blacklisting ==== | ||
+ | Im Gegensatz zur Vorgenannten Ausnahmeregelung kann man natürlich auch einem Host den Zugriff zum Web gänzlich blocken, hierzu trägt man dessen IP-Adresse in die Konfigurationsdatei // | ||
+ | # vim / | ||
+ | <file bash / | ||
+ | # IP addresses of client machines to | ||
+ | # disallow web access to. | ||
+ | # | ||
+ | # Hostnames are also allowed here, provided you | ||
+ | # enable the reverseclientlookups option. | ||
+ | # | ||
+ | # This is not the IP of web servers | ||
+ | # you want to filter. | ||
+ | |||
+ | # | ||
+ | # | ||
+ | # | ||
+ | |||
+ | # Ranges and subnets can also be used, | ||
+ | # e.g. | ||
+ | # 10.0.0.1-10.0.0.3 | ||
+ | # 10.0.0.0/24 | ||
+ | # | ||
+ | # Hostnames can also be used, provided | ||
+ | # you cater for reverse DNS lookups | ||
+ | # on your LAN and enable the | ||
+ | # " | ||
+ | # dansguardian.conf | ||
+ | |||
+ | # Django 2011-11-15 | ||
+ | # Workstation der Ferienwohnung komplett den Web-Zugriff sperren | ||
+ | 10.10.10.100 | ||
+ | </ | ||
+ | ==== Sperrlisten für URLS (regex) ==== | ||
+ | Über die // | ||
+ | # vim / | ||
+ | <file bash / | ||
+ | #Banned URLs based on Regular Expressions | ||
+ | # | ||
+ | # E.g. ' | ||
+ | |||
+ | # | ||
+ | |||
+ | #Banned URLs based on Regular Expressions | ||
+ | |||
+ | ###################################################### | ||
+ | # | ||
+ | # Django 2011-11-15 | ||
+ | # SOHO-spezifische Anpassungen für nausch.org | ||
+ | # | ||
+ | ###################################################### | ||
+ | |||
+ | # Onlinegaming | ||
+ | (gladiatus|4story|gameforge|ikariam|pog.com|cracymonkeygames|poissonrouge) | ||
+ | |||
+ | # Musikmaffia | ||
+ | (musicload|musikload) | ||
+ | |||
+ | # videoportale | ||
+ | (vo.llnwd) | ||
+ | |||
+ | # Werbemüll | ||
+ | (Standardteaser|sponsorads|google-analytics) | ||
+ | |||
+ | # Schnacksl-Anbahnungsportale | ||
+ | (facebook|lokalisten|myspace|friendscout) | ||
+ | |||
+ | ###################################################### | ||
+ | # Pornography, | ||
+ | ###################################################### | ||
+ | |||
+ | # The following two lines may work better than the above - Philip Pearce 9/11/2004 | ||
+ | (big|cyber|hard|huge|mega|small|soft|super|tiny|bare|naked|nude|anal|oral|topp? | ||
+ | (anal|babe|bharath|boob|breast|busen|busty|clit|cum|cunt|dick|fetish|fuck|girl|hooter|lez|lust|naked|nude|oral|orgy|penis|porn|porno|pupper|pussy|rotten|sex|shit|smutpump|teen|tit|topp? | ||
+ | |||
+ | #HardCore phrases | ||
+ | (adultsight|adultsite|adultsonly|adultweb|blowjob|bondage|centerfold|cumshot|cyberlust|cybercore|hardcore|masturbat) | ||
+ | (bangbros|pussylip|playmate|pornstar|sexdream|showgirl|softcore|striptease) | ||
+ | |||
+ | #SoftCore phrases - more likely to overblock - possibly on news sites | ||
+ | # | ||
+ | |||
+ | #Photo Modeling - supplied by David Burkholder | ||
+ | # | ||
+ | |||
+ | # The following will help to block explicit media files (images and video) | ||
+ | (sex|fuck|boob|cunt|fetish|tits|anal|hooter|asses|shemale|submission|porn|xxx|busty|knockers|slut|nude|naked|pussy)+.*(\.jpg|\.wmv|\.mpg|\.mpeg|\.gif|\.mov) | ||
+ | (girls|babes|bikini|model)+.*(\.jpg|\.wmv|\.mpg|\.mpeg|\.gif|\.mov) | ||
+ | |||
+ | #Block Naturism and Nudist sites | ||
+ | # | ||
+ | |||
+ | |||
+ | ###################################################### | ||
+ | # Search Engine and Related | ||
+ | ###################################################### | ||
+ | |||
+ | #Block unfiltered options on various search engines | ||
+ | # | ||
+ | # | ||
+ | |||
+ | #Block images and video on altavista, alltheweb, yahoo etc - as they are anonomised | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | |||
+ | #Block images and video on google | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | |||
+ | |||
+ | ###################################################### | ||
+ | # Proxy Sites | ||
+ | ###################################################### | ||
+ | |||
+ | #Block Cgiproxy, Poxy, PHProxy and other Web-based proxies | ||
+ | (cecid.php|nph-webpr|nph-pro|/ | ||
+ | |||
+ | #Block websites containing proxy lists | ||
+ | (anonymizer|proxify|megaproxy) | ||
+ | |||
+ | #AGRESSIVE blocking of all URLs containing proxy - WARNING - this WILL overblock!! | ||
+ | #(proxy) | ||
+ | |||
+ | |||
+ | ###################################################### | ||
+ | # Gambling - supplied by David Burkholder | ||
+ | ###################################################### | ||
+ | # | ||
+ | |||
+ | |||
+ | ###################################################### | ||
+ | # Sport - supplied by David Burkholder | ||
+ | ###################################################### | ||
+ | # | ||
+ | # | ||
+ | |||
+ | #Racing - supplied by David Burkholder | ||
+ | # | ||
+ | |||
+ | |||
+ | ###################################################### | ||
+ | # News sites - supplied by David Burkholder | ||
+ | ###################################################### | ||
+ | # | ||
+ | |||
+ | |||
+ | ###################################################### | ||
+ | # Dating Sites - supplied by David Burkholder | ||
+ | ###################################################### | ||
+ | # | ||
+ | # | ||
+ | |||
+ | |||
+ | ###################################################### | ||
+ | # Miscellaneous - Productivity etc. | ||
+ | ###################################################### | ||
+ | |||
+ | #Use this to block web counters: | ||
+ | # | ||
+ | # | ||
+ | |||
+ | #Free stuff - supplied by David Burkholder | ||
+ | # | ||
+ | # | ||
+ | |||
+ | #Music - supplied by David Burkholder | ||
+ | # | ||
+ | |||
+ | # WARNING: This is part of the URL for the dansguardian.org sample virus archive. | ||
+ | # You probably don't want to go there unintentionally. | ||
+ | (Variants/ | ||
+ | </ | ||
+ | |||
+ | ==== Blacklisting von MIME-Types ==== | ||
+ | Will man bestimmte MIME-Typen generell nicht zulassen, trägt man diese in die Konfigurationsdatei // | ||
+ | # vim / | ||
+ | <file bash / | ||
+ | |||
+ | audio/mpeg | ||
+ | audio/ | ||
+ | audio/ | ||
+ | audio/x-wav | ||
+ | video/mpeg | ||
+ | video/ | ||
+ | video/ | ||
+ | video/ | ||
+ | video/ | ||
+ | video/ | ||
+ | application/ | ||
+ | application/ | ||
+ | application/ | ||
+ | application/ | ||
+ | application/ | ||
+ | application/ | ||
+ | </ | ||
+ | ==== Blacklisting von Datei-Extensions ==== | ||
+ | Über die // | ||
+ | # vim / | ||
+ | <file bash / | ||
+ | #Banned extension list | ||
+ | |||
+ | # File extensions with executable code | ||
+ | |||
+ | # The following file extensions can contain executable code. | ||
+ | # This means they can potentially carry a virus to infect your computer. | ||
+ | |||
+ | .ade # Microsoft Access project extension | ||
+ | .adp # Microsoft Access project | ||
+ | .asx # Windows Media Audio / Video | ||
+ | .bas # Microsoft Visual Basic class module | ||
+ | .bat # Batch file | ||
+ | .cab # Windows setup file | ||
+ | .chm # Compiled HTML Help file | ||
+ | .cmd # Microsoft Windows NT Command script | ||
+ | .com # Microsoft MS-DOS program | ||
+ | .cpl # Control Panel extension | ||
+ | .crt # Security certificate | ||
+ | .dll # Windows system file | ||
+ | .exe # Program | ||
+ | .hlp # Help file | ||
+ | .ini # Windows system file | ||
+ | .hta # HTML program | ||
+ | .inf # Setup Information | ||
+ | .ins # Internet Naming Service | ||
+ | .isp # Internet Communication settings | ||
+ | # .js # JScript file - often needed in web pages | ||
+ | # .jse # Jscript Encoded Script file - often needed in web pages | ||
+ | .lnk # Windows Shortcut | ||
+ | .mda # Microsoft Access add-in program | ||
+ | .mdb # Microsoft Access program | ||
+ | .mde # Microsoft Access MDE database | ||
+ | .mdt # Microsoft Access workgroup information | ||
+ | .mdw # Microsoft Access workgroup information | ||
+ | .mdz # Microsoft Access wizard program | ||
+ | .msc # Microsoft Common Console document | ||
+ | .msi # Microsoft Windows Installer package | ||
+ | .msp # Microsoft Windows Installer patch | ||
+ | .mst # Microsoft Visual Test source files | ||
+ | .pcd # Photo CD image, Microsoft Visual compiled script | ||
+ | .pif # Shortcut to MS-DOS program | ||
+ | .prf # Microsoft Outlook profile settings | ||
+ | .reg # Windows registry entries | ||
+ | .scf # Windows Explorer command | ||
+ | .scr # Screen saver | ||
+ | .sct # Windows Script Component | ||
+ | .sh # Shell script | ||
+ | .shs # Shell Scrap object | ||
+ | .shb # Shell Scrap object | ||
+ | .sys # Windows system file | ||
+ | .url # Internet shortcut | ||
+ | .vb # VBScript file | ||
+ | .vbe # VBScript Encoded script file | ||
+ | .vbs # VBScript file | ||
+ | .vxd # Windows system file | ||
+ | .wsc # Windows Script Component | ||
+ | .wsf # Windows Script file | ||
+ | .wsh # Windows Script Host Settings file | ||
+ | .otf # Font file - can be used to instant reboot 2k and xp | ||
+ | .ops # Office XP settings | ||
+ | |||
+ | |||
+ | |||
+ | # Files which one normally things as non-executable but | ||
+ | # can contain harmful macros and viruses | ||
+ | |||
+ | .doc # Word document | ||
+ | .xls # Excel document | ||
+ | .pps | ||
+ | |||
+ | |||
+ | # Other files which may contain files with executable code | ||
+ | |||
+ | .gz # Gziped file | ||
+ | .tar # Tape ARchive file | ||
+ | .zip # Windows compressed file | ||
+ | .tgz # Unix compressed file | ||
+ | .bz2 # Unix compressed file | ||
+ | .cdr # Mac disk image | ||
+ | .dmg # Mac disk image | ||
+ | .smi # Mac self mounting disk image | ||
+ | .sit # Mac compressed file | ||
+ | .sea # Mac compressed file, self extracting | ||
+ | .bin # Mac binary compressed file | ||
+ | .hqx # Mac binhex encoded file | ||
+ | .rar # Similar to zip | ||
+ | |||
+ | |||
+ | # Time/ | ||
+ | |||
+ | .mp3 # Music file | ||
+ | .mpeg # Movie file | ||
+ | .mpg # Movie file | ||
+ | .avi # Movie file | ||
+ | .asf # this can also exploit a security hole allowing virus infection | ||
+ | .iso # CD ISO image | ||
+ | .ogg # Music file | ||
+ | .wmf # Movie file | ||
+ | .bin # CD ISO image | ||
+ | .cue # CD ISO image | ||
+ | |||
+ | # Banned Media extension list (Audio , Video , Streaming) | ||
+ | # Arrange Alphabetically | ||
+ | # Some have no Description | ||
+ | #.3g2 # | ||
+ | #.3gp # Nokia Movie File | ||
+ | #.3gp2 | ||
+ | #.3gpp | ||
+ | #.3gpp2 | ||
+ | #.aac # AAC Audio | ||
+ | #.acp # AAC for SD Media | ||
+ | #.adts | ||
+ | #.aif | ||
+ | #.aifc | ||
+ | # | ||
+ | #.amc # AMC Media | ||
+ | #.amr # narrow-Band Content | ||
+ | #.asf # Media / this can also exploit a security hole allowing virus infection | ||
+ | #.asx # Windows Media Audio / Video | ||
+ | #.au # uLaw/AU Audio | ||
+ | #.avi # Movie file | ||
+ | #.awb # AMR Wide-Band Content | ||
+ | #.bwf | ||
+ | #.caf # CAF Audio | ||
+ | #.cda # Audio CD File | ||
+ | # | ||
+ | #.cel | ||
+ | #.cue # CD ISO image | ||
+ | #.dif | ||
+ | # | ||
+ | #.dv # Video Format used in Portable Camera | ||
+ | #.flc # Autodesk Animator | ||
+ | #.fli | ||
+ | #.flv # Internet Movies | ||
+ | #.gsm | ||
+ | #.ivf | ||
+ | #.kar # Karaoke Media Files | ||
+ | #.m15 | ||
+ | #.m1a | ||
+ | #.m1s | ||
+ | #.m1v | ||
+ | #.m2v | ||
+ | #.m3u # MP3 Playlist | ||
+ | #.m4a # AAC Audio | ||
+ | #.m4b | ||
+ | #.m4e | ||
+ | #.m4p # AAC Audio (Protected) | ||
+ | #.m4v # Video (Protected) | ||
+ | #.m75 | ||
+ | #.mid # Midi Audio Files | ||
+ | # | ||
+ | #.mjpg | ||
+ | #.mov # Movie Files | ||
+ | #.mp1 | ||
+ | #.mp2 | ||
+ | #.mp3 # Music file | ||
+ | #.mp4 # Mpeg-4 Media | ||
+ | #.mpa | ||
+ | #.mpe | ||
+ | # | ||
+ | #.mpg # Movie file | ||
+ | #.mpga | ||
+ | #.mpm | ||
+ | #.mps | ||
+ | #.mpv | ||
+ | #.mpv2 | ||
+ | #.mqv # Quicktime Movies | ||
+ | #.mv | ||
+ | #.ogg # Music file | ||
+ | #.ogm # Ogg Based Movie Files | ||
+ | #.pls # Shoutcast type of radio | ||
+ | #.qcp # Qualcomm Purevoice Audio | ||
+ | #.qt # Quicktime File | ||
+ | #.qtc | ||
+ | #.qtl # Quicktime Movies | ||
+ | #.ra # Real Audio | ||
+ | #.ram # Real Audio Media | ||
+ | #.rm # Real Media Files | ||
+ | #.rmi | ||
+ | #.rmm | ||
+ | #.rmp | ||
+ | # | ||
+ | #.rnx | ||
+ | #.rp # Real Player Files | ||
+ | #.rt | ||
+ | #.rts | ||
+ | #.rtsp | ||
+ | #.rv | ||
+ | #.sd2 # Sound Designer II | ||
+ | #.sdp # Stream Descriptor | ||
+ | #.sdv # SD Video | ||
+ | #.sf | ||
+ | #.smf | ||
+ | #.smi # | ||
+ | # | ||
+ | #.snd | ||
+ | #.ssm # Streaming Media Metafile | ||
+ | #.swa # MP3 Audio | ||
+ | #.swf # Shockwave Streaming files | ||
+ | #.ulw | ||
+ | #.vfw # Video for Windows | ||
+ | #.wav | ||
+ | #.wax | ||
+ | #.wm | ||
+ | #.wma | ||
+ | #.wmf # Movie file | ||
+ | #.wmp | ||
+ | #.wmv # Windows Media Video | ||
+ | #.wmx | ||
+ | #.wvx | ||
+ | #.xpl | ||
+ | </ | ||
+ | ==== separate Blacklists einbinden ==== | ||
+ | Wem die grundlegenden Möglichkeiten von Dansguardian noch nicht ausreichen, dem sind separate **blacklists** ans Herz zu legen. | ||
+ | |||
+ | Ein __**kostenpflichige**__ Sammlung von Blacklists((Listen mit unerwünschten Seiten)) kann bei Bedarf von [[http:// | ||
+ | | ||
+ | |||
+ | Nachdem wir das Archiv **bigblacklist.tar.gz** heruntergeladen haben, entpacken wir den Inhalt kurzerhand nach // | ||
+ | # tar xzfv bigblacklist.tar.gz | ||
+ | |||
+ | Anschließend kopieren wir das Verzeichnis mit samt seinem Inhalt in unsere Dansguardian-Konfigurationsverzeichnis // | ||
+ | # cp -fr / | ||
+ | |||
+ | cp: overwrite `/ | ||
+ | cp: overwrite `/ | ||
+ | cp: overwrite `/ | ||
+ | |||
+ | Eine detaillierte Beschreibung der einzelnen Listen ist in folgender Datei enthalten: | ||
+ | * // | ||
+ | |||
+ | Eine Aufstellung von //positiven Seiten//, solche, die also keiner Sperre unterworfen werden sollen finden sich in den beiden Verzeichnissen: | ||
+ | * // | ||
+ | * // | ||
+ | |||
+ | Die Konfiguration bzw. das Einbinden der Domain-Listen aus den einzelnen Verzeichnissen erfolgt in der Konfigurationsdatei | ||
+ | // | ||
+ | des neuen und aktuelleren Umfangs ignoriert werden sollte, jedoch als Vorlage dienen kann, wie die einzelnen Domain-Listen | ||
+ | eingebunden werden können. | ||
+ | |||
+ | In der Konfigurationsdatei // | ||
+ | Im nachfolgendem Beispiel haben wir folgende beiden Zeilen aktiviert: | ||
+ | * **.Include</ | ||
+ | * **.Include</ | ||
+ | |||
+ | # vim / | ||
+ | <file bash / | ||
+ | #domains in banned list | ||
+ | #Don't bother with the www. or the http:// | ||
+ | |||
+ | #The bannedurllist is for blocking PART of a site | ||
+ | #The bannedsitelist is for blocking ALL of a site | ||
+ | |||
+ | #As of DansGuardian 2.7.3 you can now include | ||
+ | #.tld so for example you can match .gov for example | ||
+ | |||
+ | #The ' | ||
+ | #The ' | ||
+ | #The difference is that the ' | ||
+ | #off *all* other filtering for the match. | ||
+ | #stop the URL filtering and allow the normal filtering to work. | ||
+ | |||
+ | #An example of grey list use is when in Blanket Block (whitelist) | ||
+ | #mode and you want to allow some sites but still filter as normal | ||
+ | #on their content | ||
+ | |||
+ | #Another example of grey list use is when you ban a site but want | ||
+ | #to allow part of it. | ||
+ | |||
+ | #To include additional files in this list use this example: | ||
+ | # | ||
+ | |||
+ | #You can have multiple .Includes. | ||
+ | |||
+ | # Time limiting syntax: | ||
+ | # #time: <start hour> <start minute> <end hour> <end minute> < | ||
+ | # Example: | ||
+ | ##time: 9 0 17 0 01234 | ||
+ | # Remove the first # from the line above to enable this list only from | ||
+ | # 9am to 5pm, Monday to Friday. | ||
+ | |||
+ | # List categorisation | ||
+ | # | ||
+ | |||
+ | #List other sites to block: | ||
+ | |||
+ | badboys.com | ||
+ | |||
+ | # Django 2011-11-15 | ||
+ | # Nutzerindividuelle gesperrte Seiten blocklists | ||
+ | |||
+ | microsoft.com | ||
+ | cdu.de | ||
+ | csu.de | ||
+ | spd.de | ||
+ | ftp.de | ||
+ | |||
+ | #Blanket Block. | ||
+ | # | ||
+ | #the # from the next line to leave only a ' | ||
+ | #** | ||
+ | |||
+ | #Blanket SSL/CONNECT Block. | ||
+ | #and CONNECT tunnels except to addresses in the | ||
+ | # | ||
+ | #the # from the next line to leave only a ' | ||
+ | #**s | ||
+ | |||
+ | #Blanket IP Block. | ||
+ | #remove the # from the next line to leave only a ' | ||
+ | #*ip | ||
+ | |||
+ | #Blanket SSL/CONNECT IP Block. | ||
+ | #tunnels to sites specified only as an IP, | ||
+ | #remove the # from the next line to leave only a ' | ||
+ | #*ips | ||
+ | |||
+ | |||
+ | # The squidGuard advert domain/URL lists are now included by default. | ||
+ | # To work with advanced ad blocking & the logadblocks option, advert | ||
+ | # phrase/ | ||
+ | .Include</ | ||
+ | |||
+ | #Remove the # from the following and edit as needed to use a stock | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | |||
+ | # You will need to edit to add and remove categories you want | ||
+ | |||
+ | # Django : 2011-11-15 | ||
+ | # BigBlacklist vom 2011-11-15 von Seite http:// | ||
+ | |||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | .Include</ | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | .Include</ | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | </ | ||
+ | |||
+ | Unter Umständen werdedn nun eine ganze Reihe von Seiten plötzlich nicht mehr erreichbar sein, weil diese eben auf eine der besagten **blacklists** steht (warum auch immer!). | ||
+ | |||
+ | Hier hilft dann nur eine Detailsuche wo überall die Seite geblockt werden könnte. | ||
+ | # grep webmail.trachtler.net / | ||
+ | |||
+ | / | ||
+ | |||
+ | Bei Bedarf muss also in der Datei // | ||
+ | |||
+ | ==== Sperrseite Individualisierung ==== | ||
+ | Steuert ein Nutzer eine Seite an, deren Inhalte nicht mit den auf Grund unserer Definitionen nicht als geeignet erscheint, wird eine Sperrseite eingeblendet. | ||
+ | In der Konfigurationsdatei // | ||
+ | den Reportinglevel auf **3** gesetzt // | ||
+ | |||
+ | <file html / | ||
+ | < | ||
+ | |||
+ | < | ||
+ | < | ||
+ | <meta http-equiv=" | ||
+ | </ | ||
+ | |||
+ | <body bgcolor=# | ||
+ | |||
+ | < | ||
+ | <table border=0 cellspacing=0 cellpadding=2 height=540 width=700> | ||
+ | <tr> | ||
+ | <td colspan=2 bgcolor=# | ||
+ | <font face=arial, | ||
+ | < | ||
+ | </ | ||
+ | </tr> | ||
+ | <tr> | ||
+ | <td colspan=2 bgcolor=# | ||
+ | <font face=arial, | ||
+ | < | ||
+ | </ | ||
+ | </tr> | ||
+ | <tr> | ||
+ | <td align=center valign=bottom width=150 bgcolor=# | ||
+ | <font face=arial, | ||
+ | IHRE FIRMA | ||
+ | </ | ||
+ | <td width=550 bgcolor=# | ||
+ | <font face=arial, | ||
+ | <font size=4> | ||
+ | Der Zugriff auf die Seite | ||
+ | < | ||
+ | <a href=" | ||
+ | < | ||
+ | <font size=3> | ||
+ | wurde mit folgender Begründung verweigert: | ||
+ | < | ||
+ | <font color=red> | ||
+ | < | ||
+ | <font color=black> | ||
+ | < | ||
+ | Sie sehen diese Fehlermeldung, | ||
+ | < | ||
+ | Bei Fragen oder Beschwerden wenden Sie sich bitte an Ihren Netzwerkadministrator. | ||
+ | < | ||
+ | <font size=1> | ||
+ | Powered by <a href=" | ||
+ | </ | ||
+ | </tr> | ||
+ | </ | ||
+ | |||
+ | </ | ||
+ | |||
+ | </ | ||
+ | |||
+ | <!-- | ||
+ | Translated and adapted for Unicode by Peter Vollmar | ||
+ | The available variables are as follows: | ||
+ | - URL- gives the URL the user was trying to get to. | ||
+ | - REASONGIVEN- gives the nice reason (i.e. not quoting the banned phrase). | ||
+ | - REASONLOGGED- gives the reason that gets logged including full details. | ||
+ | - USER- gives the username if known. | ||
+ | - IP- gives the originating IP. | ||
+ | - FILTERGROUP- gives the group number. | ||
+ | - BYPASS- gives URL which allows temporary bypass of denied page | ||
+ | |||
+ | You need to remove the space between the - and the variable to use them | ||
+ | in your HTML. They are there above so extra processing is not required. | ||
+ | |||
+ | More example templates are likely to be found on the DansGuardian web site | ||
+ | on the Extras page. | ||
+ | |||
+ | This page was designed by Paul Richards. | ||
+ | |||
+ | Daniel Barron 2003-09-01 | ||
+ | --!> | ||
+ | |||
+ | </ | ||
+ | |||
+ | Die angezeigte Seite zeigt im Detail die exakte Beschreibung, | ||
+ | |||
+ | {{ : | ||
+ | |||
+ | Neben der Formulierung werden wird neben dem richtigen // | ||
+ | |||
+ | Entsprechen bearbeiten wir nun die HTML-Vorgabedatei // | ||
+ | # vim / | ||
+ | <file html / | ||
+ | < | ||
+ | |||
+ | < | ||
+ | < | ||
+ | <meta http-equiv=" | ||
+ | </ | ||
+ | |||
+ | <body bgcolor=# | ||
+ | |||
+ | < | ||
+ | <table border=0 cellspacing=0 cellpadding=2 height=540 width=700> | ||
+ | <tr> | ||
+ | <td colspan=2 bgcolor=# | ||
+ | <font face=arial, | ||
+ | < | ||
+ | </ | ||
+ | </tr> | ||
+ | <tr> | ||
+ | <td colspan=2 bgcolor=# | ||
+ | <font face=arial, | ||
+ | < | ||
+ | </ | ||
+ | </tr> | ||
+ | <tr> | ||
+ | <td align=center valign=bottom width=150 bgcolor=# | ||
+ | <font face=arial, | ||
+ | NAUSCH.ORG | ||
+ | </ | ||
+ | <td width=550 bgcolor=# | ||
+ | <font face=arial, | ||
+ | <font size=4> | ||
+ | Der Zugriff auf die Seite | ||
+ | < | ||
+ | <a href=" | ||
+ | < | ||
+ | <font size=3> | ||
+ | wurde mit folgender Begründung verweigert: | ||
+ | < | ||
+ | <font color=red> | ||
+ | < | ||
+ | <font color=black> | ||
+ | < | ||
+ | Du siehst diese Fehlermeldung, | ||
+ | < | ||
+ | Bei Fragen oder Beschwerden wende Dich bitte an Deinen Netzwerkadministrator, | ||
+ | < | ||
+ | <font size=1> | ||
+ | Powered by <a href=" | ||
+ | </ | ||
+ | </tr> | ||
+ | </ | ||
+ | |||
+ | </ | ||
+ | |||
+ | </ | ||
+ | |||
+ | <!-- | ||
+ | Translated and adapted for Unicode by Peter Vollmar | ||
+ | The available variables are as follows: | ||
+ | - URL- gives the URL the user was trying to get to. | ||
+ | - REASONGIVEN- gives the nice reason (i.e. not quoting the banned phrase). | ||
+ | - REASONLOGGED- gives the reason that gets logged including full details. | ||
+ | - USER- gives the username if known. | ||
+ | - IP- gives the originating IP. | ||
+ | - FILTERGROUP- gives the group number. | ||
+ | - BYPASS- gives URL which allows temporary bypass of denied page | ||
+ | |||
+ | You need to remove the space between the - and the variable to use them | ||
+ | in your HTML. They are there above so extra processing is not required. | ||
+ | |||
+ | More example templates are likely to be found on the DansGuardian web site | ||
+ | on the Extras page. | ||
+ | |||
+ | This page was designed by Paul Richards. | ||
+ | |||
+ | Daniel Barron 2003-09-01 | ||
+ | --!> | ||
+ | |||
+ | </ | ||
+ | |||
+ | Das Ergebnis der oben gezeigten HTML-Vorgabedatei sieht dann schon etwas ansprechender aus, oder? | ||
+ | |||
+ | {{ : | ||
+ | |||
+ | ==== Optimierung der Dansguardian-Ressourcen ==== | ||
+ | Die Standardeinstellungen, | ||
+ | |||
+ | In der zentralen Konfigurationsdatei // | ||
+ | # vim / | ||
+ | |||
+ | <file bash / | ||
+ | # DansGuardian config file for version 2.10.1.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 ' | ||
+ | # 1 = report why but not what denied phrase | ||
+ | # 2 = report fully | ||
+ | # 3 = use HTML template file (accessdeniedaddress ignored) - recommended | ||
+ | # | ||
+ | reportinglevel = 3 | ||
+ | |||
+ | # Language dir where languages are stored for internationalisation. | ||
+ | # The HTML template within this dir is only used when reportinglevel | ||
+ | # is set to 3. When used, DansGuardian will display the HTML file instead of | ||
+ | # using the perl cgi script. | ||
+ | # and easier to customise the access denied page. | ||
+ | # The language file is used no matter what setting however. | ||
+ | # | ||
+ | languagedir = '/ | ||
+ | |||
+ | # language to use from languagedir. | ||
+ | # Django 2011-11-15 | ||
+ | # Default: language = ' | ||
+ | language = ' | ||
+ | |||
+ | # Logging Settings | ||
+ | # | ||
+ | # 0 = none 1 = just denied | ||
+ | # Django 2011-11-15 Anpassen des Log-Levels | ||
+ | # default : loglevel = 2 | ||
+ | loglevel = 1 | ||
+ | |||
+ | # Log Exception Hits | ||
+ | # Log if an exception (user, ip, URL, phrase) is matched and so | ||
+ | # the page gets let through. | ||
+ | # why a site gets through the filter. | ||
+ | # 0 = never log exceptions | ||
+ | # 1 = log exceptions, but do not explicitly mark them as such | ||
+ | # 2 = always log & mark exceptions (default) | ||
+ | logexceptionhits = 2 | ||
+ | |||
+ | # Log File Format | ||
+ | # 1 = DansGuardian format (space delimited) | ||
+ | # 2 = CSV-style format | ||
+ | # 3 = Squid Log File Format | ||
+ | # 4 = Tab delimited | ||
+ | logfileformat = 1 | ||
+ | |||
+ | # truncate large items in log lines | ||
+ | # | ||
+ | |||
+ | # anonymize logs (blank out usernames & IPs) | ||
+ | # | ||
+ | |||
+ | |||
+ | # Syslog logging | ||
+ | # | ||
+ | # Use syslog for access logging instead of logging to the file | ||
+ | # at the defined or built-in " | ||
+ | #syslog = on | ||
+ | |||
+ | # Log file location | ||
+ | # | ||
+ | # Defines the log directory and filename. | ||
+ | # | ||
+ | |||
+ | |||
+ | # Statistics log file location | ||
+ | # | ||
+ | # Defines the stat file directory and filename. | ||
+ | # Only used in conjunction with maxips > 0 | ||
+ | # Once every 3 minutes, the current number of IPs in the cache, and the most | ||
+ | # that have been in the cache since the daemon was started, are written to this | ||
+ | # file. IPs persist in the cache for 7 days. | ||
+ | # | ||
+ | |||
+ | |||
+ | # Network Settings | ||
+ | # | ||
+ | # the IP that DansGuardian listens on. If left blank DansGuardian will | ||
+ | # listen on all IPs. That would include all NICs, loopback, modem, etc. | ||
+ | # Normally you would have your firewall protecting this, but if you want | ||
+ | # you can limit it to a certain IP. To bind to multiple interfaces, | ||
+ | # specify each IP on an individual filterip line. | ||
+ | filterip = | ||
+ | |||
+ | # the port that DansGuardian listens to. | ||
+ | filterport = 8080 | ||
+ | |||
+ | # the ip of the proxy (default is the loopback - i.e. this server) | ||
+ | proxyip = 127.0.0.1 | ||
+ | |||
+ | # the port DansGuardian connects to proxy on | ||
+ | proxyport = 3128 | ||
+ | |||
+ | # Whether to retrieve the original destination IP in transparent proxy | ||
+ | # setups and check it against the domain pulled from the HTTP headers. | ||
+ | # | ||
+ | # Be aware that when visiting sites which use a certain type of round-robin | ||
+ | # DNS for load balancing, DG may mark requests as invalid unless DG gets | ||
+ | # exactly the same answers to its DNS requests as clients. | ||
+ | # this happening can be increased if all clients and servers on the same LAN | ||
+ | # make use of a local, caching DNS server instead of using upstream DNS | ||
+ | # directly. | ||
+ | # | ||
+ | # See http:// | ||
+ | # on (default) | off | ||
+ | #!! Not compiled !! originalip = on | ||
+ | |||
+ | # 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' | ||
+ | # 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. | ||
+ | # | ||
+ | # Django 2011-11-15 | ||
+ | # default : accessdeniedaddress = ' | ||
+ | # accessdeniedaddress = ' | ||
+ | |||
+ | |||
+ | # Non standard delimiter (only used with accessdeniedaddress) | ||
+ | # To help preserve the full banned URL, including parameters, the variables | ||
+ | # passed into the access denied CGI are separated using non-standard | ||
+ | # delimiters. This can be useful to ensure correct operation of the filter | ||
+ | # bypass modes. Parameters are split using "::" | ||
+ | # place of " | ||
+ | # Default is enabled, but to go back to the standard mode, disable it. | ||
+ | nonstandarddelimiter = on | ||
+ | |||
+ | |||
+ | |||
+ | # Banned image replacement | ||
+ | # Images that are banned due to domain/ | ||
+ | # in the adverts blacklists can be replaced by an image. | ||
+ | # for example, hide images from advert sites and remove broken image | ||
+ | # icons from banned domains. | ||
+ | # on (default) | off | ||
+ | usecustombannedimage = on | ||
+ | custombannedimagefile = '/ | ||
+ | |||
+ | |||
+ | |||
+ | # Filter groups options | ||
+ | # filtergroups sets the number of filter groups. A filter group is a set of content | ||
+ | # filtering options you can apply to a group of users. | ||
+ | # DansGuardian will automatically look for dansguardianfN.conf where N is the filter | ||
+ | # group. | ||
+ | # to filter group 1. You must have some sort of authentication to be able to map users | ||
+ | # to a group. | ||
+ | # use as few as possible. | ||
+ | filtergroups = 1 | ||
+ | filtergroupslist = '/ | ||
+ | |||
+ | |||
+ | |||
+ | # Authentication files location | ||
+ | bannediplist = '/ | ||
+ | exceptioniplist = '/ | ||
+ | |||
+ | |||
+ | |||
+ | # Show weighted phrases found | ||
+ | # If enabled then the phrases found that made up the total which excedes | ||
+ | # the naughtyness limit will be logged and, if the reporting level is | ||
+ | # high enough, reported. on | off | ||
+ | showweightedfound = on | ||
+ | |||
+ | # Weighted phrase mode | ||
+ | # There are 3 possible modes of operation: | ||
+ | # 0 = off = do not use the weighted phrase feature. | ||
+ | # 1 = on, normal = normal weighted phrase operation. | ||
+ | # 2 = on, singular = each weighted phrase found only counts once on a page. | ||
+ | # | ||
+ | weightedphrasemode = 2 | ||
+ | |||
+ | |||
+ | |||
+ | # Positive (clean) result caching for URLs | ||
+ | # Caches good pages so they don't need to be scanned again. | ||
+ | # It also works with AV plugins. | ||
+ | # 0 = off (recommended for ISPs with users with disimilar browsing) | ||
+ | # 1000 = recommended for most users | ||
+ | # 5000 = suggested max upper limit | ||
+ | # If you're using an AV plugin then use at least 5000. | ||
+ | urlcachenumber = 1000 | ||
+ | # | ||
+ | # Age before they are stale and should be ignored in seconds | ||
+ | # 0 = never | ||
+ | # 900 = recommended = 15 mins | ||
+ | urlcacheage = 900 | ||
+ | |||
+ | |||
+ | |||
+ | # Clean cache for content (AV) scan results | ||
+ | # By default, to save CPU, files scanned and found to be | ||
+ | # clean are inserted into the clean cache and NOT scanned | ||
+ | # again for a while. | ||
+ | # to disable it. | ||
+ | # (on|off) default = on. | ||
+ | scancleancache = on | ||
+ | |||
+ | |||
+ | |||
+ | # Smart, Raw and Meta/Title phrase content filtering options | ||
+ | # Smart is where the multiple spaces and HTML are removed before phrase filtering | ||
+ | # Raw is where the raw HTML including meta tags are phrase filtered | ||
+ | # Meta/Title is where only meta and title tags are phrase filtered (v. quick) | ||
+ | # CPU usage can be effectively halved by using setting 0 or 1 compared to 2 | ||
+ | # 0 = raw only | ||
+ | # 1 = smart only | ||
+ | # 2 = both of the above (default) | ||
+ | # 3 = meta/title | ||
+ | phrasefiltermode = 2 | ||
+ | |||
+ | # Lower casing options | ||
+ | # When a document is scanned the uppercase letters are converted to lower case | ||
+ | # in order to compare them with the phrases. | ||
+ | # other 16-bit texts. | ||
+ | # characters are supported. | ||
+ | # 0 = force lower case (default) | ||
+ | # 1 = do not change case | ||
+ | # 2 = scan first in lower case, then in original case | ||
+ | preservecase = 0 | ||
+ | |||
+ | # Note: | ||
+ | # If phrasefiltermode and preserve case are both 2, this equates to 4 phrase | ||
+ | # filtering passes. If you have a large enough userbase for this to be a | ||
+ | # worry, and need to filter pages in exotic character encodings, it may be | ||
+ | # better to run two instances on separate servers: one with preservecase 1 | ||
+ | # (and possibly forcequicksearch 1) and non ASCII/UTF-8 phrase lists, and one | ||
+ | # with preservecase 0 and ASCII/UTF-8 lists. | ||
+ | |||
+ | |||
+ | |||
+ | # Hex decoding options | ||
+ | # When a document is scanned it can optionally convert %XX to chars. | ||
+ | # If you find documents are getting past the phrase filtering due to encoding | ||
+ | # then enable. | ||
+ | # off = disabled (default) | ||
+ | # on = enabled | ||
+ | hexdecodecontent = off | ||
+ | |||
+ | |||
+ | |||
+ | # Force Quick Search rather than DFA search algorithm | ||
+ | # The current DFA implementation is not totally 16-bit character compatible | ||
+ | # but is used by default as it handles large phrase lists much faster. | ||
+ | # If you wish to use a large number of 16-bit character phrases then | ||
+ | # enable this option. | ||
+ | # off (default) | on (Big5 compatible) | ||
+ | forcequicksearch = off | ||
+ | |||
+ | |||
+ | |||
+ | # Reverse lookups for banned site and URLs. | ||
+ | # If set to on, DansGuardian will look up the forward DNS for an IP URL | ||
+ | # address and search for both in the banned site and URL lists. | ||
+ | # prevent a user from simply entering the IP for a banned address. | ||
+ | # It will reduce searching speed somewhat so unless you have a local caching | ||
+ | # DNS server, leave it off and use the Blanket IP Block option in the | ||
+ | # bannedsitelist file instead. | ||
+ | reverseaddresslookups = off | ||
+ | |||
+ | |||
+ | |||
+ | # Reverse lookups for banned and exception IP lists. | ||
+ | # If set to on, DansGuardian will look up the forward DNS for the IP | ||
+ | # of the connecting computer. | ||
+ | # the exceptioniplist and bannediplist. | ||
+ | # If a client computer is matched against an IP given in the lists, then the | ||
+ | # IP will be recorded in any log entries; if forward DNS is successful and a | ||
+ | # match occurs against a hostname, the hostname will be logged instead. | ||
+ | # It will reduce searching speed somewhat so unless you have a local DNS server, | ||
+ | # leave it off. | ||
+ | reverseclientiplookups = off | ||
+ | |||
+ | |||
+ | # Perform reverse lookups on client IPs for successful requests. | ||
+ | # If set to on, DansGuardian will look up the forward DNS for the IP | ||
+ | # of the connecting computer, and log host names (where available) rather than | ||
+ | # IPs against requests. | ||
+ | # This is not dependent on reverseclientiplookups being enabled; however, if it | ||
+ | # is, enabling this option does not incur any additional forward DNS requests. | ||
+ | logclienthostnames = off | ||
+ | |||
+ | |||
+ | # Build bannedsitelist and bannedurllist cache files. | ||
+ | # This will compare the date stamp of the list file with the date stamp of | ||
+ | # the cache file and will recreate as needed. | ||
+ | # If a bsl or bul .processed file exists, then that will be used instead. | ||
+ | # It will increase process start speed by 300%. On slow computers this will | ||
+ | # be significant. | ||
+ | createlistcachefiles = on | ||
+ | |||
+ | |||
+ | |||
+ | # POST protection (web upload and forms) | ||
+ | # does not block forms without any file upload, i.e. this is just for | ||
+ | # blocking or limiting uploads | ||
+ | # measured in kibibytes after MIME encoding and header bumph | ||
+ | # use 0 for a complete block | ||
+ | # use higher (e.g. 512 = 512Kbytes) for limiting | ||
+ | # use -1 for no blocking | ||
+ | # | ||
+ | # | ||
+ | maxuploadsize = -1 | ||
+ | |||
+ | |||
+ | |||
+ | # Max content filter size | ||
+ | # Sometimes web servers label binary files as text which can be very | ||
+ | # large which causes a huge drain on memory and cpu resources. | ||
+ | # To counter this, you can limit the size of the document to be | ||
+ | # filtered and get it to just pass it straight through. | ||
+ | # This setting also applies to content regular expression modification. | ||
+ | # The value must not be higher than maxcontentramcachescansize | ||
+ | # The size is in Kibibytes - eg 2048 = 2Mb | ||
+ | # use 0 to set it to maxcontentramcachescansize | ||
+ | maxcontentfiltersize = 256 | ||
+ | |||
+ | |||
+ | |||
+ | # Max content ram cache scan size | ||
+ | # This is only used if you use a content scanner plugin such as AV | ||
+ | # This is the max size of file that DG will download and cache | ||
+ | # in RAM. After this limit is reached it will cache to disk | ||
+ | # This value must be less than or equal to maxcontentfilecachescansize. | ||
+ | # The size is in Kibibytes - eg 10240 = 10Mb | ||
+ | # use 0 to set it to maxcontentfilecachescansize | ||
+ | # This option may be ignored by the configured download manager. | ||
+ | maxcontentramcachescansize = 2000 | ||
+ | |||
+ | |||
+ | |||
+ | # Max content file cache scan size | ||
+ | # This is only used if you use a content scanner plugin such as AV | ||
+ | # This is the max size file that DG will download | ||
+ | # so that it can be scanned or virus checked. | ||
+ | # This value must be greater or equal to maxcontentramcachescansize. | ||
+ | # The size is in Kibibytes - eg 10240 = 10Mb | ||
+ | maxcontentfilecachescansize = 20000 | ||
+ | |||
+ | |||
+ | |||
+ | # File cache dir | ||
+ | # Where DG will download files to be scanned if too large for the | ||
+ | # RAM cache. | ||
+ | filecachedir = '/ | ||
+ | |||
+ | |||
+ | |||
+ | # Delete file cache after user completes download | ||
+ | # When a file gets save to temp it stays there until it is deleted. | ||
+ | # You can choose to have the file deleted when the user makes a sucessful | ||
+ | # download. | ||
+ | # the temp store a second time it will give a 404 error. | ||
+ | # You should configure something to delete old files in temp to stop it filling up. | ||
+ | # on|off (defaults to on) | ||
+ | deletedownloadedtempfiles = on | ||
+ | |||
+ | |||
+ | |||
+ | # Initial Trickle delay | ||
+ | # This is the number of seconds a browser connection is left waiting | ||
+ | # before first being sent *something* to keep it alive. | ||
+ | # *something* depends on the download manager chosen. | ||
+ | # Do not choose a value too low or normal web pages will be affected. | ||
+ | # A value between 20 and 110 would be sensible | ||
+ | # This may be ignored by the configured download manager. | ||
+ | initialtrickledelay = 20 | ||
+ | |||
+ | |||
+ | |||
+ | # Trickle delay | ||
+ | # This is the number of seconds a browser connection is left waiting | ||
+ | # before being sent more *something* to keep it alive. | ||
+ | # *something* depends on the download manager chosen. | ||
+ | # This may be ignored by the configured download manager. | ||
+ | trickledelay = 10 | ||
+ | |||
+ | |||
+ | |||
+ | # Download Managers | ||
+ | # These handle downloads of files to be filtered and scanned. | ||
+ | # They differ in the method they deal with large downloads. | ||
+ | # Files usually need to be downloaded 100% before they can be | ||
+ | # filtered and scanned before being sent on to the browser. | ||
+ | # Normally the browser can just wait, but with content scanning, | ||
+ | # for example to AV, the browser may timeout or the user may get | ||
+ | # confused so the download manager has to do some sort of | ||
+ | # 'keep alive' | ||
+ | # | ||
+ | # There are various methods possible but not all are included. | ||
+ | # The author does not have the time to write them all so I have | ||
+ | # included a plugin systam. | ||
+ | # browsers and clients. | ||
+ | # work with software that downloads updates. | ||
+ | # each plugin can support a regular expression for matching | ||
+ | # the client' | ||
+ | # and extensions it should manage. | ||
+ | # | ||
+ | # Note that these are the matching methods provided by the base plugin | ||
+ | # code, and individual plugins may override or add to them. | ||
+ | # See the individual plugin conf files for supported options. | ||
+ | # | ||
+ | # The plugins are matched in the order you specify and the last | ||
+ | # one is forced to match as the default, regardless of user agent | ||
+ | # and other matching mechanisms. | ||
+ | # | ||
+ | downloadmanager = '/ | ||
+ | # | ||
+ | downloadmanager = '/ | ||
+ | |||
+ | |||
+ | |||
+ | # Content Scanners (Also known as AV scanners) | ||
+ | # These are plugins that scan the content of all files your browser fetches | ||
+ | # for example to AV scan. The options are limitless. | ||
+ | # DansGuardian will be plugin based. | ||
+ | # scanner. The plugins are run in the order you specify. | ||
+ | # This is one of the few places you can have multiple options of the same name. | ||
+ | # | ||
+ | # Some of the scanner(s) require 3rd party software and libraries eg clamav. | ||
+ | # See the individual plugin conf file for more options (if any). | ||
+ | # | ||
+ | #!! Not compiled !! contentscanner = '/ | ||
+ | # | ||
+ | #!! Unimplemented !! contentscanner = '/ | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | |||
+ | |||
+ | |||
+ | # Content scanner timeout | ||
+ | # Some of the content scanners support using a timeout value to stop | ||
+ | # processing (eg AV scanning) the file if it takes too long. | ||
+ | # If supported this will be used. | ||
+ | # The default of 60 seconds is probably reasonable. | ||
+ | contentscannertimeout = 60 | ||
+ | |||
+ | |||
+ | |||
+ | # Content scan exceptions | ||
+ | # If ' | ||
+ | # This is probably not desirable behavour as exceptions are | ||
+ | # supposed to be trusted and will increase load. | ||
+ | # Correct use of grey lists are a better idea. | ||
+ | # (on|off) default = off | ||
+ | contentscanexceptions = off | ||
+ | |||
+ | |||
+ | |||
+ | # Auth plugins | ||
+ | # These replace the usernameidmethod* options in previous versions. They | ||
+ | # handle the extraction of client usernames from various sources, such as | ||
+ | # Proxy-Authorisation headers and ident servers, enabling requests to be | ||
+ | # handled according to the settings of the user's filter group. | ||
+ | # Multiple plugins can be specified, and will be queried in order until one | ||
+ | # of them either finds a username or throws an error. For example, if Squid | ||
+ | # is configured with both NTLM and Basic auth enabled, and both the ' | ||
+ | # and ' | ||
+ | # NTLM can fall back to Basic without sacrificing access rights. | ||
+ | # | ||
+ | # If you do not use multiple filter groups, you need not specify this option. | ||
+ | # | ||
+ | #authplugin = '/ | ||
+ | #authplugin = '/ | ||
+ | #authplugin = '/ | ||
+ | #authplugin = '/ | ||
+ | #authplugin = '/ | ||
+ | # Django 2011-11-15 Username im Logfile mit ausgeben | ||
+ | # default : NULL | ||
+ | authplugin = '/ | ||
+ | |||
+ | # Re-check replaced URLs | ||
+ | # As a matter of course, URLs undergo regular expression search/ | ||
+ | # *after* checking the exception site/ | ||
+ | # the banned site/URL lists, allowing certain requests that would be matched against the | ||
+ | # latter in their original state to effectively be converted into grey requests. | ||
+ | # With this option enabled, the exception site/ | ||
+ | # after replacement, | ||
+ | # on them. | ||
+ | # Defaults to off. | ||
+ | recheckreplacedurls = off | ||
+ | |||
+ | |||
+ | |||
+ | # Misc settings | ||
+ | |||
+ | # if on it adds an X-Forwarded-For: | ||
+ | # header. | ||
+ | # source ip. on | off | ||
+ | forwardedfor = off | ||
+ | |||
+ | |||
+ | # if on it uses the X-Forwarded-For: | ||
+ | # IP. This is for when you have squid between the clients and DansGuardian. | ||
+ | # Warning - headers are easily spoofed. on | off | ||
+ | usexforwardedfor = off | ||
+ | |||
+ | |||
+ | # if on it logs some debug info regarding fork()ing and accept()ing which | ||
+ | # can usually be ignored. | ||
+ | # it on or off | ||
+ | logconnectionhandlingerrors = on | ||
+ | |||
+ | |||
+ | |||
+ | # Fork pool options | ||
+ | |||
+ | # If on, this causes DG to write to the log file whenever child processes are | ||
+ | # created or destroyed (other than by crashes). This information can help in | ||
+ | # understanding and tuning the following parameters, but is not generally | ||
+ | # useful in production. | ||
+ | logchildprocesshandling = off | ||
+ | |||
+ | # sets the maximum number of processes to spawn to handle the incoming | ||
+ | # connections. | ||
+ | # On large sites you might want to try 180. | ||
+ | # Django 2011-11-15 | ||
+ | # default maxchildren = 120 | ||
+ | maxchildren = 80 | ||
+ | |||
+ | |||
+ | # sets the minimum number of processes to spawn to handle the incoming connections. | ||
+ | # On large sites you might want to try 32. | ||
+ | # Django 2011-11-15 | ||
+ | # default minchildren = 8 | ||
+ | minchildren = 4 | ||
+ | |||
+ | |||
+ | # sets the minimum number of processes to be kept ready to handle connections. | ||
+ | # On large sites you might want to try 8. | ||
+ | # Django 2011-11-15 | ||
+ | # default minsparechildren = 4 | ||
+ | minsparechildren = 2 | ||
+ | |||
+ | |||
+ | # sets the minimum number of processes to spawn when it runs out | ||
+ | # On large sites you might want to try 10. | ||
+ | # Django 2011-11-15 | ||
+ | # default preforkchildren = 6 | ||
+ | preforkchildren = 4 | ||
+ | |||
+ | |||
+ | # sets the maximum number of processes to have doing nothing. | ||
+ | # When this many are spare it will cull some of them. | ||
+ | # On large sites you might want to try 64. | ||
+ | # Django 2011-11-15 | ||
+ | # default maxsparechildren = 32 | ||
+ | maxsparechildren = 8 | ||
+ | |||
+ | |||
+ | # sets the maximum age of a child process before it croaks it. | ||
+ | # This is the number of connections they handle before exiting. | ||
+ | # On large sites you might want to try 10000. | ||
+ | maxagechildren = 500 | ||
+ | |||
+ | |||
+ | # Sets the maximum number client IP addresses allowed to connect at once. | ||
+ | # Use this to set a hard limit on the number of users allowed to concurrently | ||
+ | # browse the web. Set to 0 for no limit, and to disable the IP cache process. | ||
+ | maxips = 0 | ||
+ | |||
+ | |||
+ | |||
+ | # Process options | ||
+ | # (Change these only if you really know what you are doing). | ||
+ | # These options allow you to run multiple instances of DansGuardian on a single machine. | ||
+ | # Remember to edit the log file path above also if that is your intention. | ||
+ | |||
+ | # IPC filename | ||
+ | # | ||
+ | # Defines IPC server directory and filename used to communicate with the log process. | ||
+ | ipcfilename = '/ | ||
+ | |||
+ | # URL list IPC filename | ||
+ | # | ||
+ | # Defines URL list IPC server directory and filename used to communicate with the URL | ||
+ | # cache process. | ||
+ | urlipcfilename = '/ | ||
+ | |||
+ | # IP list IPC filename | ||
+ | # | ||
+ | # Defines IP list IPC server directory and filename, for communicating with the client | ||
+ | # IP cache process. | ||
+ | ipipcfilename = '/ | ||
+ | |||
+ | # PID filename | ||
+ | # | ||
+ | # Defines process id directory and filename. | ||
+ | # | ||
+ | |||
+ | # Disable daemoning | ||
+ | # If enabled the process will not fork into the background. | ||
+ | # It is not usually advantageous to do this. | ||
+ | # on|off (defaults to off) | ||
+ | nodaemon = off | ||
+ | |||
+ | # Disable logging process | ||
+ | # on|off (defaults to off) | ||
+ | nologger = off | ||
+ | |||
+ | # Enable logging of " | ||
+ | # on|off (defaults to off) | ||
+ | logadblocks = off | ||
+ | |||
+ | # Enable logging of client User-Agent | ||
+ | # Some browsers will cause a *lot* of extra information on each line! | ||
+ | # on|off (defaults to off) | ||
+ | loguseragent = off | ||
+ | |||
+ | # Daemon runas user and group | ||
+ | # This is the user that DansGuardian runs as. Normally the user/group nobody. | ||
+ | # Uncomment to use. Defaults to the user set at compile time. | ||
+ | # Temp files created during virus scanning are given owner and group read | ||
+ | # permissions; | ||
+ | # clamdscan, the two processes must run with either the same group or user ID. | ||
+ | #daemonuser = ' | ||
+ | # | ||
+ | |||
+ | # Soft restart | ||
+ | # When on this disables the forced killing off all processes in the process group. | ||
+ | # This is not to be confused with the -g run time option - they are not related. | ||
+ | # on|off (defaults to off) | ||
+ | softrestart = off | ||
+ | |||
+ | # Mail program | ||
+ | # Path (sendmail-compatible) email program, with options. | ||
+ | # Not used if usesmtp is disabled (filtergroup specific). | ||
+ | mailer = '/ | ||
+ | |||
+ | </ | ||
+ | |||
+ | Anschließend müssen wir useren Dansguardian Daemon einmal durchstarten, | ||
+ | # service dansguardian restart | ||
+ | |||
+ | | ||
+ | | ||
+ | ====== Links ====== | ||
+ | * **[[centos: | ||
+ | * **[[wiki: | ||
+ | * **[[http:// | ||
+ | |||