aboutsummaryrefslogtreecommitdiffstats
path: root/config/squidGuard
diff options
context:
space:
mode:
Diffstat (limited to 'config/squidGuard')
-rw-r--r--config/squidGuard/squidguard.inc7
-rw-r--r--config/squidGuard/squidguard_configurator.inc3
2 files changed, 4 insertions, 6 deletions
diff --git a/config/squidGuard/squidguard.inc b/config/squidGuard/squidguard.inc
index 303f53b0..f5df409a 100644
--- a/config/squidGuard/squidguard.inc
+++ b/config/squidGuard/squidguard.inc
@@ -1074,21 +1074,20 @@ function convert_pfxml_to_sgxml() {
# other
$sgxml['view_gui_log'] = $pfxml['view_gui_log'];
+ $lanip = $config['interfaces']['lan']['ipaddr'];
+ $sgxml[F_CURRENT_LAN_IP] = $lanip;
# transparent
$squidxml = $config['installedpackages']['squid']['config'][0];
- if(isset($squidxml['transparent_proxy'])) {
- $lanip = $config['interfaces']['lan']['ipaddr'];
+ if($squidxml['transparent_proxy'] == 'on') {
$guiport = $config['system']['webgui']['port'];
$guiprotocol = $config['system']['webgui']['protocol'];
$sgxml[F_SQUID_TRANSPARENT_MODE] = 'on';
- $sgxml[F_CURRENT_LAN_IP] = $lanip;
$sgxml[F_CURRENT_GUI_PORT] = $guiport;
$sgxml[F_CURRENT_GUI_PROTO] = $guiprotocol;
} else {
unset($sgxml[F_SQUID_TRANSPARENT_MODE]);
- unset($sgxml[F_CURRENT_LAN_IP]);
unset($sgxml[F_CURRENT_GUI_PORT]);
unset($sgxml[F_CURRENT_GUI_PROTO]);
}
diff --git a/config/squidGuard/squidguard_configurator.inc b/config/squidGuard/squidguard_configurator.inc
index afc6d23a..f008ef2e 100644
--- a/config/squidGuard/squidguard_configurator.inc
+++ b/config/squidGuard/squidguard_configurator.inc
@@ -1069,8 +1069,7 @@ function sg_redirector_base_url($rdr_info, $redirect_mode)
# gui port, ip & proto
$guiip = (!empty($squidguard_config[F_CURRENT_LAN_IP])) ? $squidguard_config[F_CURRENT_LAN_IP] : '127.0.0.1';
$guiport = (!empty($squidguard_config[F_CURRENT_GUI_PORT])) ? $squidguard_config[F_CURRENT_GUI_PORT] : '80';
- $guiproto = ($squidguard_config[F_CURRENT_GUI_PROTO] === "https") ? "https" : "http";
- $rdr_path = "$guiproto://$guiip:$guiport" . REDIRECT_BASE_URL;
+ $rdr_path = "http://$guiip:$guiport" . REDIRECT_BASE_URL;
# check redirect
$errmsg = '';