⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 edit_misc.cgi

📁 Unix下基于Web的管理工具
💻 CGI
字号:
#!/usr/local/bin/perl# edit_misc.cgi# A form for edit misc optionsrequire './squid-lib.pl';&header("Miscellaneous Options", "", undef, 0, 0, 0, &restart_button());print "<hr>\n";$conf = &get_config();print "<form action=save_misc.cgi>\n";print "<table border width=100%>\n";print "<tr $tb> <td><b>Miscellaneous Options</b></td> </tr>\n";print "<tr $cb> <td><table width=100%>\n";print "<tr>\n";print &opt_input("Startup DNS test addresses", "dns_testnames", $conf,		 "Default", 40);print "</tr>\n";print "<tr>\n";print &opt_input("SIGUSR1 logfile rotations", "logfile_rotate", $conf,		 "Default", 6);print &opt_input("Default domain", "append_domain", $conf, "None", 10);print "</tr>\n";if ($squid_version < 2) {	print "<tr>\n";	print &opt_input("SSL proxy", "ssl_proxy", $conf, "None", 15);	print &opt_input("Non-GET HTTP proxy", "passthrough_proxy",			 $conf, "None", 15);	print "</tr>\n";	}print "<tr>\n";print &opt_input("Error messages text", "err_html_text", $conf, "None", 40);print "</tr>\n";print "<tr>\n";print &choice_input("Per-client statistics?", "client_db", $conf,		    "on", "Yes", "on", "No", "off");print &choice_input("X-Forwarded-For header?", "forwarded_for", $conf,		    "on", "Yes", "on", "No", "off");print "</tr>\n";print "<tr>\n";print &choice_input("Log ICP queries?", "log_icp_queries", $conf,		    "on", "Yes", "on", "No", "off");print &opt_input("Minimum direct hops", "minimum_direct_hops", $conf,		 "Default", 6);print "</tr>\n";print "<tr>\n";print &choice_input("Keep memory for future use?", "memory_pools", $conf,		    "on", "Yes", "on", "No", "off");if ($squid_version >= 2) {	print &opt_bytes_input("Amount of memory to keep", "memory_pools_limit",			       $conf, "Unlimited", 6);	}print "</tr>\n";print "<tr>\n";if ($squid_version >= 2.2) {	foreach $a (&find_config("anonymize_headers", $conf)) {		@ap = @{$a->{'values'}};		$anon = shift(@ap);		push(@anon, @ap);		}	print "<td valign=top><b>Headers to pass through</b></td> ",	      "<td colspan=3>\n";	printf "<input type=radio name=anon_mode value=0 %s> All headers<br>\n",		$anon ? "" : "checked";	printf "<input type=radio name=anon_mode value=1 %s> Only headers\n",		$anon eq "allow" ? "checked" : "";	printf "<input name=anon_allow size=50 value='%s'><br>\n",		$anon eq "allow" ? join(" ", @anon) : "";	printf "<input type=radio name=anon_mode value=2 %s> All except\n",		$anon eq "deny" ? "checked" : "";	printf "<input name=anon_deny size=50 value='%s'>\n",		$anon eq "deny" ? join(" ", @anon) : "";	print "</td> </tr> <tr>\n";	}else {	print &choice_input("Anonymizer?", "http_anonymizer", $conf,			    "off", "Off", "off", "Standard", "standard",			    "Paranoid", "paranoid");	}print &opt_input("Fake User-Agent", "fake_user_agent", $conf, "None", 15);print "</tr>\n";print "</table></td></tr></table><br>\n";print "<input type=submit value=Save></form>\n";print "<hr>\n";&footer("", "squid index");

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -