From a566588e9bdcc02197d9d2de0fc81411a4698f03 Mon Sep 17 00:00:00 2001
From: theli
+The new proxy IP filter is set to #[filter]#
The proxy port is: #[port]#
+The new proxy IP filter is set to #[filter]#.
The proxy port is: #[port]# Your proxy networking settings have been changed.
Your proxy account check has been disabled, since you did not supply a password.
-The new proxy IP filter is set to #[filter]#
-Transparent Proxy Support is: #[isTransparentProxy]#
if you changed the Port, you need to restart YaCy.
::
Your proxy access setting has been changed.
Your new proxy account name is #[user]#. The password has been accepted.
If you open any public web page through the proxy, you must log-in then.
-The new proxy IP filter is set to #[filter]#.
-Transparent Proxy Support is: #[isTransparentProxy]#
if you changed the Port, you need to restart YaCy.
::
@@ -88,6 +86,18 @@ Seed Upload method was changed successfully.
Seed Upload Method: #[seedUploadMethod]#
+::
+Seed File URL: #[seedURL]#
+
#(/info)#
+
+Transparent Proxy Support is:
+ #[isTransparentProxy]#
+
+
+ Connection Keep-Alive Support is:
+ #[connectionKeepAliveSupport]#
+
You can now go back to the Settings page if you want to make more changes.
diff --git a/htroot/SettingsAck_p.java b/htroot/SettingsAck_p.java index 7045052f5..29969cd86 100644 --- a/htroot/SettingsAck_p.java +++ b/htroot/SettingsAck_p.java @@ -54,6 +54,7 @@ import java.util.Iterator; import java.util.List; import de.anomic.http.httpHeader; +import de.anomic.http.httpd; import de.anomic.http.httpdProxyHandler; import de.anomic.plasma.plasmaSwitchboard; import de.anomic.server.serverCodings; @@ -125,15 +126,10 @@ public class SettingsAck_p { // proxy password if (post.containsKey("proxyaccount")) { - // set new port + // set new port String port = (String) post.get("port"); - env.setConfig("port", port); - prop.put("info_port", port); - - // set transparent proxy flag - httpdProxyHandler.isTransparentProxy = post.containsKey("isTransparentProxy"); - env.setConfig("isTransparentProxy", httpdProxyHandler.isTransparentProxy ? "true" : "false"); - prop.put("info_isTransparentProxy", httpdProxyHandler.isTransparentProxy ? "on" : "off"); + env.setConfig("port", port); + prop.put("info_port", port); // read and process data String filter = (String) post.get("proxyfilter"); @@ -173,6 +169,23 @@ public class SettingsAck_p { return prop; } + // http networking + if (post.containsKey("httpNetworking")) { + + // set transparent proxy flag + httpdProxyHandler.isTransparentProxy = post.containsKey("isTransparentProxy"); + env.setConfig("isTransparentProxy", httpdProxyHandler.isTransparentProxy ? "true" : "false"); + prop.put("info_isTransparentProxy", httpdProxyHandler.isTransparentProxy ? "on" : "off"); + + // setting the keep alive property + httpd.keepAliveSupport = post.containsKey("connectionKeepAliveSupport"); + env.setConfig("connectionKeepAliveSupport", httpd.keepAliveSupport ? "true" : "false"); + prop.put("info_connectionKeepAliveSupport", httpd.keepAliveSupport ? "on" : "off"); + + prop.put("info", 20); + return prop; + } + // server password if (post.containsKey("serveraccount")) { // read and process data diff --git a/htroot/Settings_p.html b/htroot/Settings_p.html index 889bc717c..3d58b0854 100644 --- a/htroot/Settings_p.html +++ b/htroot/Settings_p.html @@ -53,9 +53,7 @@ delete the file 'DATA/SETTINGS/httpProxy.conf' in the YaCy application root fold -->iptables -t nat -A PREROUTING -p tcp -s 192.168.0.0/16 --dport 80 -j DNAT --to 192.168.0.1:#[port]#
- You can restrict the access to this proxy using a two-stage security barrier:
@@ -96,6 +86,30 @@ delete the file 'DATA/SETTINGS/httpProxy.conf' in the YaCy application root fold
+