From 7c8b2854e579402d546b41457828bf7622868d5a Mon Sep 17 00:00:00 2001 From: Andreas Brodmann Date: Wed, 9 Jan 2008 16:03:54 +0000 Subject: updates on gui and functionality of squid and dansguardian acfs git-svn-id: svn://svn.alpinelinux.org/acf/squid/trunk@520 ab2d0c66-481e-0410-8bed-d214d4d58bed --- dansguardian-edit-html.lsp | 3 +- dansguardian-general-html.lsp | 64 +++++++++++++++++++++++-------------------- dansguardian-plain-html.lsp | 5 ++-- squid-advanced-html.lsp | 44 ++++++++++++++--------------- squid-authentication-html.lsp | 55 +++++++++++++++++++++---------------- squid-controller.lua | 42 ++++++++-------------------- 6 files changed, 105 insertions(+), 108 deletions(-) diff --git a/dansguardian-edit-html.lsp b/dansguardian-edit-html.lsp index 43aac93..fe6205c 100644 --- a/dansguardian-edit-html.lsp +++ b/dansguardian-edit-html.lsp @@ -29,6 +29,7 @@ These parameters define the interface and port that Dansguardian uses to accept
-
+

Save Changes

+
Save the content of the above box
diff --git a/dansguardian-general-html.lsp b/dansguardian-general-html.lsp index 6a146d2..0d286ac 100644 --- a/dansguardian-general-html.lsp +++ b/dansguardian-general-html.lsp @@ -19,59 +19,65 @@ ?>

Content Filter

+

DansGuardian is web content filtering software. It works as a web proxy, making web requests in behalf of the client, and inspecting the returned content before passing on to the client. DansGuardian uses phraselists to identify harmful content. This means that updated "blacklists" are generally not necessary. DansGuardian must be used in combination with a "smart proxy", such as squid. -This page defines the basic network configuration settings for DansGuardian.

+

+This page defines the basic network configuration settings for DansGuardian. +

-

Status

+

Status

- - - - - -
dansguardian is: style="width:100px"> style="width:100px"> style="width:100px">
+
dansguardian is:
+
style="width:100px"> + style="width:100px"> + style="width:100px">
-

+

+

+

+

This process runs as a service. When you make and save changes, the configuration files for the service are changed. However, the changes will not be applied -until you restart the service.


+until you restart the service. +

-

Configuration

+

Configuration


Listener service

-These parameters define the interface and port that Dansguardian uses to accept connections.

+

+These parameters define the interface and port that Dansguardian uses to accept connections. +

- -
filterip
-
filterport
-

+
filterip
+
filterport
-

Proxy service

-These parameters define the ip address and port that Dansguardian should forward requests on to.

+

Proxy service

+

+These parameters define the ip address and port that Dansguardian should forward requests on to. +

- -
proxyip
-
proxyport
-


+
proxyip
+
proxyport
-

Filter Actions

+

Filter Actions

+

These parameters define how sensitive the filter is, and where to redirect requests if the content filter determines that the content is inappropriate. The "naughtynesslimit" is more sensitive the lower it is set. -The author recommends 50 for "young children", 100 for "older children" and 160 for "young adults".

+The author recommends 50 for "young children", 100 for "older children" and 160 for "young adults". +

- -
accessdeniedaddress
-
naughtynesslimit
-


+
accessdeniedaddress
+
naughtynesslimit
-
+

Save Changes

+
Save the above changes?
diff --git a/dansguardian-plain-html.lsp b/dansguardian-plain-html.lsp index 184efaf..2e24fd0 100644 --- a/dansguardian-plain-html.lsp +++ b/dansguardian-plain-html.lsp @@ -47,7 +47,7 @@ until you restart the service.

-

Configuration

+

Configuration


These parameters define the interface and port that Dansguardian uses to accept connections.

@@ -55,6 +55,7 @@ These parameters define the interface and port that Dansguardian uses to accept
-
+

Save Changes

+
Save the contents of the above box
diff --git a/squid-advanced-html.lsp b/squid-advanced-html.lsp index 108f3f1..f65a19b 100644 --- a/squid-advanced-html.lsp +++ b/squid-advanced-html.lsp @@ -12,38 +12,36 @@ ?>

Web Proxy Configuration

- - - - -
-
-
WARNING:

- Modifying the web proxy configuration file is generally not necessary. - You must be familiar with the configuration file before proceeding. -
-
+

+

+
WARNING:

+ Modifying the web proxy configuration file is generally not necessary. + You must be familiar with the configuration file before proceeding. +
+

Status

- - - - - -
squid is: style="width:100px"> style="width:100px"> style="width:100px">
+
squid is:
+
style="width:100px"> + style="width:100px"> + style="width:100px">
-

+

+

+

+

This process runs as a service. When you make and save changes, the configuration files for the service are changed. However, the changes will not be applied -until you restart the service.

+until you restart the service. +

Configuration

- - - -
+ + +

Save Changes

+
Save the contents of the box above
diff --git a/squid-authentication-html.lsp b/squid-authentication-html.lsp index 1c693f0..6f5cbd5 100644 --- a/squid-authentication-html.lsp +++ b/squid-authentication-html.lsp @@ -19,46 +19,54 @@ ?>

Web Proxy

+

Squid is a web proxy server. It makes web requests in behalf of the client, and inspecting the returned and optionally caches that content so that the next time a client request is made, the content can be served from local disk. This can make web surfing faster. Squid can also forward its requests on to a content filter, -such as DansGuardian.

-This page lets you modify the authentication scheme of squid.

+such as DansGuardian. +

+

+This page lets you modify the authentication scheme of squid. +

-

Status

+

Status

- - - - - -
squid is: style="width:100px"> style="width:100px"> style="width:100px">
+
squid is:
+
> +> +>
-

+

+

+

+

This process runs as a service. When you make and save changes, the configuration files for the service are changed. However, the changes will not be applied -until you restart the service.

+until you restart the service. +

-

Configuration

+

Configuration

-

Authentication Scheme

-Choose the desired authentication mechanisms and their order.

+

Authentication Scheme

+

+Choose the desired authentication mechanisms and their order. +

- +
- +
- +
Active
-
?>
-
- +
+
- +
Selectable
@@ -100,6 +108,7 @@ Choose the desired authentication mechanisms and their order.


-
-
+

Save Changes

+
Save Authentication Scheme
+ diff --git a/squid-controller.lua b/squid-controller.lua index 84e60dd..03c6f7b 100644 --- a/squid-controller.lua +++ b/squid-controller.lua @@ -88,6 +88,18 @@ authentication = function( self ) end end + if self.clientdata.inout then + if self.clientdata.inout == " << " then + local newauth = self.clientdata.authmethod + if #self.clientdata.tmpempty > 0 then + newauth = newauth .. self.clientdata.tmpempty + end + else + + end + self.model.upd_authmethod(newauth) + end + service.status = self.model.get_status() service.config, service.error = self.model.get_basic_config() @@ -200,33 +212,3 @@ saccess = function( self ) return ( cfe ({ option = option, service = service }) ) end -cfilter = function( self ) - - local option = { script = ENV["SCRIPT_NAME"], - prefix = self.conf.prefix, - controller = self.conf.controller, - action = self.conf.action, - extra = "" - } - - local service = { message="", status="", config="" } - - if self.clientdata.cmd then - if self.clientdata.cmd == "save" then - local conf = self.clientdata - local config = { filterip = conf.filterip, filterport = conf.filterport, - proxyip = conf.proxyip, proxyport = conf.proxyport, - accessdeniedaddress = conf.accessdeniedaddress, - naughtynesslimit = conf.naughtynesslimit - } - - self.model.update_filter_config( config ) - end - end - - service.status = self.model.get_dansguardian_status() - service.config, service.cfgerr = self.model.get_filter_config() - - return ( cfe ({ option = option, service = service }) ) -end - -- cgit v1.2.3