2012-01-10 13:21:35 +00:00
<%@page contentType="text/html" import="net.i2p.i2ptunnel.web.EditBean"
%><%@page trimDirectiveWhitespaces="true"
%><?xml version="1.0" encoding="UTF-8"?>
2005-11-12 02:38:55 +00:00
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
2005-03-30 00:07:36 +00:00
<jsp:useBean class="net.i2p.i2ptunnel.web.EditBean" id="editBean" scope="request" />
2009-12-10 01:06:55 +00:00
<jsp:useBean class="net.i2p.i2ptunnel.web.Messages" id="intl" scope="request" />
2005-03-30 00:07:36 +00:00
<% String tun = request.getParameter("tunnel");
int curTunnel = -1;
if (tun != null) {
try {
curTunnel = Integer.parseInt(tun);
} catch (NumberFormatException nfe) {
curTunnel = -1;
}
}
%>
2005-11-12 02:38:55 +00:00
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
2005-03-30 00:07:36 +00:00
<head>
2015-09-25 19:55:36 +00:00
<title><%=intl._t("Hidden Services Manager")%> - <%=intl._t("Edit Client Tunnel")%></title>
2005-11-12 02:38:55 +00:00
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<meta http-equiv="Content-Type" content="application/xhtml+xml; charset=UTF-8" />
2012-07-10 21:29:49 +00:00
<link href="/themes/console/images/favicon.ico" type="image/x-icon" rel="shortcut icon" />
2005-11-12 02:38:55 +00:00
<% if (editBean.allowCSS()) {
2012-07-30 13:15:58 +00:00
%><link rel="icon" href="<%=editBean.getTheme()%>images/favicon.ico" />
2017-01-08 01:37:15 +00:00
<link href="<%=editBean.getTheme()%>i2ptunnel.css?<%=net.i2p.CoreVersion.VERSION%>" rel="stylesheet" type="text/css" />
2005-11-12 02:38:55 +00:00
<% }
%>
2013-04-17 17:04:34 +00:00
<style type='text/css'>
input.default { width: 1px; height: 1px; visibility: hidden; }
</style>
2005-03-30 00:07:36 +00:00
</head>
2005-11-12 02:38:55 +00:00
<body id="tunnelEditPage">
2016-07-11 06:54:26 +00:00
2012-10-27 18:51:50 +00:00
<%
2005-11-12 02:38:55 +00:00
2012-10-27 18:51:50 +00:00
if (editBean.isInitialized()) {
%>
2010-11-19 16:14:14 +00:00
<form method="post" action="list">
2005-03-30 00:07:36 +00:00
2016-07-11 06:54:26 +00:00
<div class="panel">
2005-11-12 02:38:55 +00:00
<%
2014-10-13 16:46:58 +00:00
String tunnelTypeName;
String tunnelType;
2005-11-12 02:38:55 +00:00
if (curTunnel >= 0) {
tunnelTypeName = editBean.getTunnelType(curTunnel);
tunnelType = editBean.getInternalType(curTunnel);
2016-07-11 06:54:26 +00:00
%><h2><%=intl._t("Edit proxy settings")%> (<%=editBean.getTunnelName(curTunnel)%>)</h2><%
2005-11-12 02:38:55 +00:00
} else {
tunnelTypeName = editBean.getTypeName(request.getParameter("type"));
2014-07-26 09:32:26 +00:00
tunnelType = net.i2p.data.DataHelper.stripHTML(request.getParameter("type"));
2016-07-11 06:54:26 +00:00
%><h2><%=intl._t("New proxy settings")%></h2><%
2005-11-12 02:38:55 +00:00
} %>
2014-07-26 09:32:26 +00:00
<input type="hidden" name="tunnel" value="<%=curTunnel%>" />
2015-10-17 17:38:57 +00:00
<input type="hidden" name="nonce" value="<%=net.i2p.i2ptunnel.web.IndexBean.getNextNonce()%>" />
2005-11-12 02:38:55 +00:00
<input type="hidden" name="type" value="<%=tunnelType%>" />
2015-01-03 13:32:24 +00:00
<%
// these are four keys that are generated automatically on first save,
// and we want to persist in i2ptunnel.config, but don't want to
// show clogging up the custom options form.
String key = editBean.getKey1(curTunnel);
if (key != null && key.length() > 0) { %>
<input type="hidden" name="key1" value="<%=key%>" />
<% }
key = editBean.getKey2(curTunnel);
if (key != null && key.length() > 0) { %>
<input type="hidden" name="key2" value="<%=key%>" />
<% }
key = editBean.getKey3(curTunnel);
if (key != null && key.length() > 0) { %>
<input type="hidden" name="key3" value="<%=key%>" />
<% }
key = editBean.getKey4(curTunnel);
if (key != null && key.length() > 0) { %>
<input type="hidden" name="key4" value="<%=key%>" />
<% } %>
2013-04-17 17:04:34 +00:00
<input type="submit" class="default" name="action" value="Save changes" />
2016-07-11 06:54:26 +00:00
<table id="clientTunnelEdit" class="tunnelConfig">
<tr>
<th>
<%=intl._t("Name")%>
</th>
<th>
<%=intl._t("Type")%>
</th>
</tr>
<tr>
<td>
<input type="text" size="30" maxlength="50" name="name" title="Tunnel Name" value="<%=editBean.getTunnelName(curTunnel)%>" class="freetext tunnelName" />
</td>
<td>
<%=tunnelTypeName%>
</td>
</tr>
<tr>
<th>
<%=intl._t("Description")%>
</th>
<th>
<%=intl._t("Auto Start Tunnel")%>
</th>
</tr>
<tr>
<td>
<input type="text" size="60" maxlength="80" name="nofilter_description" title="Tunnel Description" value="<%=editBean.getTunnelDescription(curTunnel)%>" class="freetext tunnelDescription" />
</td>
<td>
2017-05-14 05:30:13 +00:00
<label><input value="1" type="checkbox" name="startOnLoad" title="Start Tunnel Automatically"<%=(editBean.startAutomatically(curTunnel) ? " checked=\"checked\"" : "")%> class="tickbox" />
<%=intl._t("Automatically start tunnel when router starts")%></label>
2016-07-11 06:54:26 +00:00
</td>
</tr>
<tr>
<th colspan="2">
2009-02-23 05:09:44 +00:00
<% if ("streamrclient".equals(tunnelType)) { %>
2016-07-11 06:54:26 +00:00
<%=intl._t("Target")%>
2009-02-23 05:09:44 +00:00
<% } else { %>
2016-07-11 06:54:26 +00:00
<%=intl._t("Access Point")%>
2010-12-30 00:36:41 +00:00
<% } /* streamrclient */ %>
2016-07-11 06:54:26 +00:00
</th>
</tr>
<tr>
<td>
<b><%=intl._t("Port")%>:</b>
2008-11-15 19:00:08 +00:00
<% String value = editBean.getClientPort(curTunnel);
2010-01-01 17:33:55 +00:00
if (value == null || "".equals(value.trim())) {
2016-07-11 06:54:26 +00:00
out.write(" <span class=\"required\"><font color=\"red\">(");
2015-09-25 19:55:36 +00:00
out.write(intl._t("required"));
2016-07-11 06:54:26 +00:00
out.write(")</font></span>");
2010-01-01 17:33:55 +00:00
}
2008-11-15 19:00:08 +00:00
%>
2016-07-11 06:54:26 +00:00
<input type="text" size="6" maxlength="5" name="port" title="Access Port Number" value="<%=editBean.getClientPort(curTunnel)%>" class="freetext port" placeholder="required" />
</td>
2010-12-30 00:36:41 +00:00
<%
2016-07-11 06:54:26 +00:00
if ("streamrclient".equals(tunnelType)) { %>
<td>
<b><%=intl._t("Host")%>:</b>
<%
2010-12-30 00:36:41 +00:00
String targetHost = editBean.getTargetHost(curTunnel);
if (targetHost == null || "".equals(targetHost.trim())) {
2016-07-11 06:54:26 +00:00
out.write(" <span class=\"required\"><font color=\"red\">(");
2015-09-25 19:55:36 +00:00
out.write(intl._t("required"));
2016-07-11 06:54:26 +00:00
out.write(")</font></span>");
2017-05-14 05:30:42 +00:00
}
2010-12-30 00:36:41 +00:00
%>
2016-07-11 06:54:26 +00:00
<input type="text" size="20" id="targetHost" name="targetHost" title="Target Hostname or IP" value="<%=targetHost%>" class="freetext host" placeholder="required" />
</td>
2009-02-23 05:09:44 +00:00
<% } else { %>
2016-07-11 06:54:26 +00:00
<td>
<b><%=intl._t("Reachable by")%>:</b>
2010-12-30 00:36:41 +00:00
<select id="reachableBy" name="reachableBy" title="IP for Client Access" class="selectbox">
<%
String clientInterface = editBean.getClientInterface(curTunnel);
for (String ifc : editBean.interfaceSet()) {
out.write("<option value=\"");
out.write(ifc);
out.write('\"');
if (ifc.equals(clientInterface))
out.write(" selected=\"selected\"");
out.write('>');
out.write(ifc);
out.write("</option>\n");
}
%>
2017-05-14 05:30:42 +00:00
</select>
2016-07-11 06:54:26 +00:00
</td>
2010-12-30 00:36:41 +00:00
<% } /* streamrclient */ %>
2016-07-11 06:54:26 +00:00
</tr>
2014-08-21 12:21:29 +00:00
<% if ("client".equals(tunnelType) || "ircclient".equals(tunnelType)) {
2017-05-14 05:30:42 +00:00
%>
2016-07-11 06:54:26 +00:00
<tr>
<th colspan="2">
2015-09-25 19:55:36 +00:00
<%=intl._t("Use SSL?")%>
2016-07-11 06:54:26 +00:00
</th>
</tr>
<tr>
<td colspan="2">
2017-05-14 05:30:13 +00:00
<label><input value="1" type="checkbox" name="useSSL" title="Clients use SSL to connect" <%=(editBean.isSSLEnabled(curTunnel) ? " checked=\"checked\"" : "")%> class="tickbox" />
<%=intl._t("Clients use SSL to connect to tunnel")%></label>
2016-07-11 06:54:26 +00:00
</td>
</tr>
2014-08-21 12:21:29 +00:00
<% } /* tunnel types */ %>
2010-12-30 00:36:41 +00:00
2010-11-17 15:47:00 +00:00
<% if ("httpclient".equals(tunnelType) || "connectclient".equals(tunnelType) || "sockstunnel".equals(tunnelType) || "socksirctunnel".equals(tunnelType)) {
2016-07-11 06:54:26 +00:00
%>
<tr>
<th colspan="2">
<%=intl._t("Outproxies")%>
</th>
</tr>
<tr>
<td colspan="2">
<input type="text" size="30" name="proxyList" title="List of Outproxy I2P destinations" value="<%=editBean.getClientDestination(curTunnel)%>" class="freetext proxyList" /> (<%=intl._t("comma separated eg. proxy1.i2p,proxy2.i2p")%>)
</td>
</tr>
2014-01-06 16:56:00 +00:00
<% if ("httpclient".equals(tunnelType)) {
2016-07-11 06:54:26 +00:00
%>
<tr>
<th colspan="2">
<%=intl._t("SSL Outproxies")%>
</th>
</tr>
<tr>
<td colspan="2">
<input type="text" size="30" name="sslProxies" title="List of Outproxy I2P destinations" value="<%=editBean.getSslProxies(curTunnel)%>" class="freetext proxyList" />
</td>
</tr>
2014-01-06 16:56:00 +00:00
<% } // httpclient %>
2016-07-11 06:54:26 +00:00
<tr>
<th colspan="2">
<%=intl._t("Use Outproxy Plugin")%>
</th>
</tr>
<tr>
<td colspan="2">
2017-05-14 05:30:13 +00:00
<label><input value="1" type="checkbox" name="useOutproxyPlugin" <%=(editBean.getUseOutproxyPlugin(curTunnel) ? " checked=\"checked\"" : "")%> class="tickbox" />
<%=intl._t("Use plugin instead of above-listed proxies if available")%></label>
2016-07-11 06:54:26 +00:00
</td>
</tr>
2009-02-23 05:09:44 +00:00
<% } else if ("client".equals(tunnelType) || "ircclient".equals(tunnelType) || "streamrclient".equals(tunnelType)) {
2016-07-11 06:54:26 +00:00
%>
<tr>
<th colspan="2">
<%=intl._t("Tunnel Destination")%>
</th>
</tr>
<tr>
<td colspan="2">
2008-11-15 19:00:08 +00:00
<% String value2 = editBean.getClientDestination(curTunnel);
2010-01-01 17:33:55 +00:00
if (value2 == null || "".equals(value2.trim())) {
2016-07-11 06:54:26 +00:00
out.write(" <span class=\"required\"><font color=\"red\">(");
2015-09-25 19:55:36 +00:00
out.write(intl._t("required"));
2016-07-11 06:54:26 +00:00
out.write(")</font></span>");
2017-05-14 05:30:42 +00:00
}
2008-11-15 19:00:08 +00:00
%>
2016-07-11 06:54:26 +00:00
<input type="text" size="30" id="targetDestination" name="targetDestination" title="Destination of the Tunnel" value="<%=editBean.getClientDestination(curTunnel)%>" class="freetext destination" placeholder="required" />
(<%=intl._t("name, name:port, or destination")%>
2013-10-23 20:20:54 +00:00
<% if ("streamrclient".equals(tunnelType)) { /* deferred resolution unimplemented in streamr client */ %>
2015-09-25 19:55:36 +00:00
- <%=intl._t("b32 not recommended")%>
2013-10-23 20:20:54 +00:00
<% } %> )
2016-07-11 06:54:26 +00:00
</td>
</tr>
2009-02-23 05:09:44 +00:00
<% } %>
2016-07-11 06:54:26 +00:00
2009-02-23 05:09:44 +00:00
<% if (!"streamrclient".equals(tunnelType)) { %>
2016-07-11 06:54:26 +00:00
<tr>
<th colspan="2">
<%=intl._t("Shared Client")%>
</th>
</tr>
<tr>
<td colspan="2">
2017-05-14 05:30:13 +00:00
<label><input value="true" type="checkbox" name="shared" title="Share tunnels with other clients"<%=(editBean.isSharedClient(curTunnel) ? " checked=\"checked\"" : "")%> class="tickbox" />
<%=intl._t("Share tunnels with other clients and irc/httpclients? (Change requires restart of client proxy tunnel)")%></label>
2016-07-11 06:54:26 +00:00
</td>
</tr>
2009-02-23 05:09:44 +00:00
<% } // !streamrclient %>
2016-07-11 06:54:26 +00:00
2011-07-15 21:41:38 +00:00
<% if ("ircclient".equals(tunnelType)) { %>
2016-07-11 06:54:26 +00:00
<tr>
<th colspan="2">
<%=intl._t("Enable DCC")%>
</th>
</tr>
<tr>
<td colspan="2">
2017-05-14 05:30:13 +00:00
<label><input value="1" type="checkbox" name="DCC" title="Enable DCC"<%=(editBean.getDCC(curTunnel) ? " checked=\"checked\"" : "")%> class="tickbox" />
<%=intl._t("Enable Direct Client-to-Client protocol. Note that this will compromise your anonymity and is <i>not</i> recommended.")%></label>
2016-07-11 06:54:26 +00:00
</td>
</tr>
2011-07-15 21:41:38 +00:00
<% } // ircclient %>
2016-07-11 06:54:26 +00:00
</table>
<h3><%=intl._t("Advanced Networking Options")%></h3>
<table class="tunnelConfig">
<% if (!"streamrclient".equals(tunnelType)) { %> <% // no shared client tunnels for streamr %>
<tr>
<td class="infohelp" colspan="2">
<%=intl._t("Note: When this client proxy is configured to share tunnels, then these options are for all the shared proxy clients!")%>
</td>
</tr>
<% } // !streamrclient %>
<tr>
<th colspan="2">
<%=intl._t("Tunnel Options")%>
</th>
</tr>
<tr>
<td>
<b><%=intl._t("Length")%></b>
</td>
<td>
<b><%=intl._t("Variance")%></b>
</td>
</tr>
<tr>
<td>
2009-12-07 21:25:27 +00:00
<select id="tunnelDepth" name="tunnelDepth" title="Length of each Tunnel" class="selectbox">
2013-05-29 16:28:28 +00:00
<% int tunnelDepth = editBean.getTunnelDepth(curTunnel, 3);
2015-09-25 19:55:36 +00:00
%><option value="0"<%=(tunnelDepth == 0 ? " selected=\"selected\"" : "") %>><%=intl._t("0 hop tunnel (no anonymity)")%></option>
<option value="1"<%=(tunnelDepth == 1 ? " selected=\"selected\"" : "") %>><%=intl._t("1 hop tunnel (low anonymity)")%></option>
<option value="2"<%=(tunnelDepth == 2 ? " selected=\"selected\"" : "") %>><%=intl._t("2 hop tunnel (medium anonymity)")%></option>
<option value="3"<%=(tunnelDepth == 3 ? " selected=\"selected\"" : "") %>><%=intl._t("3 hop tunnel (high anonymity)")%></option>
2015-11-05 20:24:12 +00:00
<% if (editBean.isAdvanced()) {
%><option value="4"<%=(tunnelDepth == 4 ? " selected=\"selected\"" : "") %>>4 hop tunnel</option>
<option value="5"<%=(tunnelDepth == 5 ? " selected=\"selected\"" : "") %>>5 hop tunnel</option>
<option value="6"<%=(tunnelDepth == 6 ? " selected=\"selected\"" : "") %>>6 hop tunnel</option>
<option value="7"<%=(tunnelDepth == 7 ? " selected=\"selected\"" : "") %>>7 hop tunnel</option>
<% } else if (tunnelDepth > 3) {
2015-09-25 19:55:36 +00:00
%> <option value="<%=tunnelDepth%>" selected="selected"><%=tunnelDepth%> <%=intl._t("hop tunnel (very poor performance)")%></option>
2005-11-12 02:38:55 +00:00
<% }
%></select>
2016-07-11 06:54:26 +00:00
</td>
<td>
2009-12-07 21:25:27 +00:00
<select id="tunnelVariance" name="tunnelVariance" title="Level of Randomization for Tunnel Length" class="selectbox">
2009-01-23 01:22:14 +00:00
<% int tunnelVariance = editBean.getTunnelVariance(curTunnel, 0);
2016-10-30 17:56:41 +00:00
%><option value="0"<%=(tunnelVariance == 0 ? " selected=\"selected\"" : "") %>><%=intl._t("0 hop variance (no randomization, consistent performance)")%></option>
<option value="1"<%=(tunnelVariance == 1 ? " selected=\"selected\"" : "") %>><%=intl._t("+ 0-1 hop variance (medium additive randomization, subtractive performance)")%></option>
<option value="2"<%=(tunnelVariance == 2 ? " selected=\"selected\"" : "") %>><%=intl._t("+ 0-2 hop variance (high additive randomization, subtractive performance)")%></option>
<option value="-1"<%=(tunnelVariance == -1 ? " selected=\"selected\"" : "") %>><%=intl._t("+/- 0-1 hop variance (standard randomization, standard performance)")%></option>
2015-09-25 19:55:36 +00:00
<option value="-2"<%=(tunnelVariance == -2 ? " selected=\"selected\"" : "") %>><%=intl._t("+/- 0-2 hop variance (not recommended)")%></option>
2005-11-12 02:38:55 +00:00
<% if (tunnelVariance > 2 || tunnelVariance < -2) {
2015-09-25 19:55:36 +00:00
%> <option value="<%=tunnelVariance%>" selected="selected"><%= (tunnelVariance > 2 ? "+ " : "+/- ") %>0-<%=tunnelVariance%> <%=intl._t("hop variance")%></option>
2005-11-12 02:38:55 +00:00
<% }
2016-07-11 06:54:26 +00:00
%></select>
</td>
</tr>
<tr>
<td>
<b><%=intl._t("Count")%></b>
</td>
<td>
<b><%=intl._t("Backup Count")%></b>
</td>
</tr>
<tr>
<td>
2005-11-12 02:38:55 +00:00
<select id="tunnelQuantity" name="tunnelQuantity" title="Number of Tunnels in Group" class="selectbox">
2013-06-12 15:07:39 +00:00
<%=editBean.getQuantityOptions(curTunnel)%>
2016-07-11 06:54:26 +00:00
</select>
</td>
<td>
2005-11-12 02:38:55 +00:00
<select id="tunnelBackupQuantity" name="tunnelBackupQuantity" title="Number of Reserve Tunnels" class="selectbox">
<% int tunnelBackupQuantity = editBean.getTunnelBackupQuantity(curTunnel, 0);
2015-09-25 19:55:36 +00:00
%><option value="0"<%=(tunnelBackupQuantity == 0 ? " selected=\"selected\"" : "") %>><%=intl._t("0 backup tunnels (0 redundancy, no added resource usage)")%></option>
<option value="1"<%=(tunnelBackupQuantity == 1 ? " selected=\"selected\"" : "") %>><%=intl._t("1 backup tunnel each direction (low redundancy, low resource usage)")%></option>
<option value="2"<%=(tunnelBackupQuantity == 2 ? " selected=\"selected\"" : "") %>><%=intl._t("2 backup tunnels each direction (medium redundancy, medium resource usage)")%></option>
<option value="3"<%=(tunnelBackupQuantity == 3 ? " selected=\"selected\"" : "") %>><%=intl._t("3 backup tunnels each direction (high redundancy, high resource usage)")%></option>
2005-11-12 02:38:55 +00:00
<% if (tunnelBackupQuantity > 3) {
2015-09-25 19:55:36 +00:00
%> <option value="<%=tunnelBackupQuantity%>" selected="selected"><%=tunnelBackupQuantity%> <%=intl._t("backup tunnels")%></option>
2005-11-12 02:38:55 +00:00
<% }
2016-07-11 06:54:26 +00:00
%></select>
</td>
</tr>
2017-05-14 05:30:42 +00:00
2010-06-26 04:11:02 +00:00
<% if (!"streamrclient".equals(tunnelType)) { %>
2016-07-11 06:54:26 +00:00
<tr>
<th>
<%=intl._t("Profile")%>
</th>
<th>
<%=intl._t("Delay Connect")%>
</th>
</tr>
<tr>
<td>
<select id="connectionProfile" name="profile" title="Connection Profile" class="selectbox">
2010-06-26 04:11:02 +00:00
<% boolean interactiveProfile = editBean.isInteractive(curTunnel);
2015-09-25 19:55:36 +00:00
%><option <%=(interactiveProfile == true ? "selected=\"selected\" " : "")%>value="interactive"><%=intl._t("interactive connection")%> </option>
<option <%=(interactiveProfile == false ? "selected=\"selected\" " : "")%>value="bulk"><%=intl._t("bulk connection (downloads/websites/BT)")%> </option>
2017-05-14 05:30:42 +00:00
</select>
2016-07-11 06:54:26 +00:00
</td>
<td>
2017-05-14 05:30:13 +00:00
<label><input value="1000" type="checkbox" name="connectDelay" title="Delay Connection"<%=(editBean.shouldDelay(curTunnel) ? " checked=\"checked\"" : "")%> class="tickbox" />
(<%=intl._t("for request/response connections")%>)</label>
2016-07-11 06:54:26 +00:00
</td>
</tr>
2010-06-26 04:11:02 +00:00
<% } // !streamrclient %>
2016-07-11 06:54:26 +00:00
<tr>
<th colspan="2">
<%=intl._t("Router I2CP Address")%>
</th>
</tr>
<tr>
<td>
<b><%=intl._t("Host")%>:</b>
<input type="text" name="clientHost" size="20" title="I2CP Hostname or IP" value="<%=editBean.getI2CPHost(curTunnel)%>" class="freetext host" <% if (editBean.isRouterContext()) { %> readonly="readonly" <% } %> />
</td>
<td>
<b><%=intl._t("Port")%>:</b>
<input type="text" name="clientport" size="20" title="I2CP Port Number" value="<%=editBean.getI2CPPort(curTunnel)%>" class="freetext port" <% if (editBean.isRouterContext()) { %> readonly="readonly" <% } %> />
</td>
</tr>
2017-05-14 05:30:42 +00:00
2009-05-05 22:24:19 +00:00
<% if (!"streamrclient".equals(tunnelType)) { // streamr client sends pings so it will never be idle %>
2016-07-11 06:54:26 +00:00
<tr>
<th colspan="2">
<%=intl._t("Delay tunnel open until required")%>
</th>
</tr>
<tr>
<td colspan="2">
2017-05-14 05:30:13 +00:00
<label><input value="1" type="checkbox" name="delayOpen" title="Delay Tunnel Open"<%=(editBean.getDelayOpen(curTunnel) ? " checked=\"checked\"" : "")%> class="tickbox" />
<%=intl._t("Delay opening client tunnel until activity is detected on the configured tunnel port")%></label>
2016-07-11 06:54:26 +00:00
</td>
</tr>
2014-08-26 13:47:06 +00:00
<% } // !streamrclient %>
2017-05-14 05:30:42 +00:00
2016-07-11 06:54:26 +00:00
<tr>
<th colspan="2">
<%=intl._t("Reduce tunnel quantity when idle")%>
</th>
</tr>
<tr>
<td colspan="2">
2017-05-14 05:30:13 +00:00
<label><input value="1" type="checkbox" name="reduce" title="Reduce Tunnels"<%=(editBean.getReduce(curTunnel) ? " checked=\"checked\"" : "")%> class="tickbox" />
<%=intl._t("Reduce tunnel quantity when idle to conserve resources")%></label>
2016-07-11 06:54:26 +00:00
</td>
</tr>
<tr>
<td>
<b><%=intl._t("Reduced tunnel count")%>:</b>
<input type="text" id="reducedTunnelCount" name="reduceCount" size="1" maxlength="1" title="Reduced Tunnel Count" value="<%=editBean.getReduceCount(curTunnel)%>" class="freetext quantity" />
</td>
<td>
<b><%=intl._t("Idle period")%>:</b>
<input type="text" name="reduceTime" size="4" maxlength="4" title="Reduced Tunnel Idle Time" value="<%=editBean.getReduceTime(curTunnel)%>" class="freetext period" />
minutes
</td>
</tr>
<tr>
<th colspan="2">
<%=intl._t("Close tunnels when idle")%>
</th>
</tr>
<tr>
<td>
2017-05-14 05:30:13 +00:00
<label><input value="1" type="checkbox" name="close" title="Close Tunnels"<%=(editBean.getClose(curTunnel) ? " checked=\"checked\"" : "")%> class="tickbox" />
<%=intl._t("Close client tunnels after specified idle period")%></label>
2016-07-11 06:54:26 +00:00
</td>
<td>
<b><%=intl._t("Idle period")%>:</b>
2017-05-14 05:30:42 +00:00
<input type="text" name="closeTime" size="4" maxlength="4" title="Close Tunnel Idle Time" value="<%=editBean.getCloseTime(curTunnel)%>" class="freetext period" />
2016-07-11 06:54:26 +00:00
minutes
</td>
</tr>
<tr>
<td colspan="2">
<b><%=intl._t("New Keys on Reopen")%>:</b>
2017-01-07 16:24:34 +00:00
<span class="multiOption">
2017-05-14 05:30:13 +00:00
<label><input value="1" type="radio" name="newDest" title="New Destination"
2016-07-11 06:54:26 +00:00
<%=(editBean.getNewDest(curTunnel) ? " checked=\"checked\"" : "")%> class="tickbox" />
2017-05-14 05:30:13 +00:00
<%=intl._t("Enable")%></label>
</span>
2017-01-07 16:24:34 +00:00
<span class="multiOption">
2017-05-14 05:30:13 +00:00
<label><input value="0" type="radio" name="newDest" title="New Destination"
2016-07-11 06:54:26 +00:00
<%=(editBean.getNewDest(curTunnel) || editBean.getPersistentClientKey(curTunnel) ? "" : " checked=\"checked\"")%> class="tickbox" />
2017-05-14 05:30:13 +00:00
<%=intl._t("Disable")%></label>
2017-01-07 16:24:34 +00:00
</span>
2016-07-11 06:54:26 +00:00
</td>
</tr>
2009-03-01 19:25:49 +00:00
2013-10-28 19:15:46 +00:00
<% if ("client".equals(tunnelType) || "ircclient".equals(tunnelType) || "socksirctunnel".equals(tunnelType) || "sockstunnel".equals(tunnelType)) { %>
2016-07-11 06:54:26 +00:00
<tr>
<th colspan="2">
<%=intl._t("Persistent private key")%>
</th>
</tr>
<tr>
<td>
2017-05-14 05:30:13 +00:00
<label><input value="2" type="radio" name="newDest" title="New Destination"
2016-07-11 06:54:26 +00:00
<%=(editBean.getPersistentClientKey(curTunnel) ? " checked=\"checked\"" : "")%> class="tickbox" />
2017-05-14 05:30:13 +00:00
<%=intl._t("Generate key to enable persistent client tunnel identity")%></label>
2016-07-11 06:54:26 +00:00
</td>
<td>
<b><%=intl._t("File")%>:</b>
<input type="text" size="30" id="privKeyFile" name="privKeyFile" title="Path to Private Key File" value="<%=editBean.getPrivateKeyFile(curTunnel)%>" class="freetext" />
</td>
</tr>
2013-12-13 17:45:35 +00:00
<%
2017-05-14 05:30:42 +00:00
String destb64 = editBean.getDestinationBase64(curTunnel);
2013-12-13 17:45:35 +00:00
if (destb64.length() > 0) {
2017-05-14 05:30:42 +00:00
%>
2009-03-01 19:25:49 +00:00
2016-07-11 06:54:26 +00:00
<tr>
<td colspan="2">
<b><%=intl._t("Local destination")%></b>
</td>
</tr>
<tr>
<td colspan="2">
<textarea rows="1" style="height: 3em;" cols="60" readonly="readonly" id="localDestination" title="Read Only: Local Destination (if known)" wrap="off" spellcheck="false"><%=destb64%></textarea>
</td>
</tr>
<tr>
<td colspan="2">
<b><%=intl._t("Local Base 32")%>:</b>
<%=editBean.getDestHashBase32(curTunnel)%>
</td>
</tr>
<% } // if destb64 %>
2009-03-01 23:14:38 +00:00
<% } %>
2014-05-25 19:17:36 +00:00
<% if ("httpclient".equals(tunnelType)) { %>
2016-07-11 06:54:26 +00:00
<tr>
<th colspan="2">
<%=intl._t("HTTP Filtering")%>
</th>
</tr>
<tr>
<td>
2017-05-14 05:30:13 +00:00
<label><input value="1" type="checkbox" name="allowUserAgent" title="Do not spoof user agent string when checked"<%=(editBean.getAllowUserAgent(curTunnel) ? " checked=\"checked\"" : "")%> class="tickbox" />
<%=intl._t("Do not spoof User-Agent header")%></label>
2016-07-11 06:54:26 +00:00
</td>
<td>
2017-05-14 05:30:13 +00:00
<label><input value="1" type="checkbox" name="allowReferer" title="Do not block referer header when checked"<%=(editBean.getAllowReferer(curTunnel) ? " checked=\"checked\"" : "")%> class="tickbox" />
<%=intl._t("Do not block Referer header")%></label>
2016-07-11 06:54:26 +00:00
</td>
</tr>
<tr>
<td>
2017-05-14 05:30:13 +00:00
<label><input value="1" type="checkbox" name="allowAccept" title="Do not block accept headers when checked"<%=(editBean.getAllowAccept(curTunnel) ? " checked=\"checked\"" : "")%> class="tickbox" />
<%=intl._t("Do not block Accept headers")%></label>
2016-07-11 06:54:26 +00:00
</td>
<td>
2017-05-14 05:30:13 +00:00
<label><input value="1" type="checkbox" name="allowInternalSSL" title="Allow SSL to I2P addresses when checked"<%=(editBean.getAllowInternalSSL(curTunnel) ? " checked=\"checked\"" : "")%> class="tickbox" />
<%=intl._t("Allow SSL to I2P addresses")%></label>
2016-07-11 06:54:26 +00:00
</td>
</tr>
2014-05-25 19:17:36 +00:00
<% } // if httpclient %>
2016-07-11 06:54:26 +00:00
2014-10-13 16:46:58 +00:00
<% if (true /* editBean.isAdvanced() */ ) {
int currentSigType = editBean.getSigType(curTunnel, tunnelType);
%>
2016-07-11 06:54:26 +00:00
<tr>
<th colspan="2">
<%=intl._t("Signature type")%> (<%=intl._t("Experts only!")%>)
</th>
</tr>
<tr>
<td colspan="2">
<span class="multiOption">
2017-05-14 05:30:13 +00:00
<label><input value="0" type="radio" name="sigType" title="Default"<%=(currentSigType==0 ? " checked=\"checked\"" : "")%> class="tickbox" />
DSA-SHA1</label>
2016-07-11 06:54:26 +00:00
</span>
2014-02-21 17:47:30 +00:00
<% if (editBean.isSigTypeAvailable(1)) { %>
2016-07-11 06:54:26 +00:00
<span class="multiOption">
2017-05-14 05:30:13 +00:00
<label><input value="1" type="radio" name="sigType" title="Advanced users only"<%=(currentSigType==1 ? " checked=\"checked\"" : "")%> class="tickbox" />
ECDSA-P256</label>
2016-07-11 06:54:26 +00:00
</span>
2014-02-21 17:47:30 +00:00
<% }
2016-07-11 06:54:26 +00:00
2014-02-21 17:47:30 +00:00
if (editBean.isSigTypeAvailable(2)) { %>
2016-07-11 06:54:26 +00:00
<span class="multiOption">
2017-05-14 05:30:13 +00:00
<label><input value="2" type="radio" name="sigType" title="Advanced users only"<%=(currentSigType==2 ? " checked=\"checked\"" : "")%> class="tickbox" />
ECDSA-P384</label>
2016-07-11 06:54:26 +00:00
</span>
2014-02-21 17:47:30 +00:00
<% }
if (editBean.isSigTypeAvailable(3)) { %>
2016-07-11 06:54:26 +00:00
<span class="multiOption">
2017-05-14 05:30:13 +00:00
<label><input value="3" type="radio" name="sigType" title="Advanced users only"<%=(currentSigType==3 ? " checked=\"checked\"" : "")%> class="tickbox" />
ECDSA-P521</label>
2016-07-11 06:54:26 +00:00
</span>
2014-04-26 12:11:02 +00:00
<% }
if (editBean.isSigTypeAvailable(7)) { %>
2016-07-11 06:54:26 +00:00
<span class="multiOption">
2017-05-14 05:30:13 +00:00
<label><input value="7" type="radio" name="sigType" title="Advanced users only"<%=(currentSigType==7 ? " checked=\"checked\"" : "")%> class="tickbox" />
Ed25519-SHA-512</label>
2016-07-11 06:54:26 +00:00
</span>
</td>
</tr>
2014-02-21 17:47:30 +00:00
<% } // isAvailable %>
2016-07-11 06:54:26 +00:00
2014-04-02 01:25:47 +00:00
<% } // isAdvanced %>
2014-01-05 16:38:39 +00:00
2010-11-14 14:18:43 +00:00
<% if ("httpclient".equals(tunnelType) || "connectclient".equals(tunnelType) || "sockstunnel".equals(tunnelType) || "socksirctunnel".equals(tunnelType)) { %>
2016-07-11 06:54:26 +00:00
<tr>
<th colspan="2">
<%=intl._t("Local Authorization")%>
</th>
</tr>
<tr>
<td colspan="2">
2017-05-14 05:30:13 +00:00
<label><input value="1" type="checkbox" name="proxyAuth" title="Check to require authorization for this service"<%=(editBean.getProxyAuth(curTunnel) ? " checked=\"checked\"" : "")%> class="tickbox" />
<%=intl._t("Require local authorization for this service")%></label>
2016-07-11 06:54:26 +00:00
</td>
</tr>
<tr>
<td>
<b><%=intl._t("Username")%>:</b>
<input type="text" name="proxyUsername" title="Set username for this service" value="" class="freetext username" />
</td>
<td>
<b><%=intl._t("Password")%>:</b>
<input type="password" name="nofilter_proxyPassword" title="Set password for this service" value="" class="freetext password" />
</td>
</tr>
<tr>
<th colspan="2">
<%=intl._t("Outproxy Authorization")%>
</th>
</tr>
<tr>
<td colspan="2">
2017-05-14 05:30:13 +00:00
<label><input value="1" type="checkbox" id="startOnLoad" name="outproxyAuth" title="Check if the outproxy requires authorization"<%=(editBean.getOutproxyAuth(curTunnel) ? " checked=\"checked\"" : "")%> class="tickbox" />
<%=intl._t("Outproxy requires authorization")%></label>
2016-07-11 06:54:26 +00:00
</td>
</tr>
<tr>
<td>
<b><%=intl._t("Username")%>:</b>
<input type="text" name="outproxyUsername" title="Enter username required by outproxy" value="<%=editBean.getOutproxyUsername(curTunnel)%>" class="freetext username" />
</td>
<td>
<b><%=intl._t("Password")%>:</b>
<input type="password" name="nofilter_outproxyPassword" title="Enter password required by outproxy" value="<%=editBean.getOutproxyPassword(curTunnel)%>" class="freetext password" />
</td>
</tr>
2010-11-14 14:18:43 +00:00
<% } // httpclient || connect || socks || socksirc %>
2010-12-15 01:06:08 +00:00
<% if ("httpclient".equals(tunnelType)) { %>
2016-07-11 06:54:26 +00:00
<tr>
<th colspan="2">
<%=intl._t("Jump URL List")%>
</th>
</tr>
<tr>
<td colspan="2">
<textarea rows="2" style="height: 8em;" cols="60" id="hostField" name="jumpList" title="List of helper URLs to offer when a host is not found in your addressbook" wrap="off" spellcheck="false"><%=editBean.getJumpList(curTunnel)%></textarea>
</td>
</tr>
2010-12-15 01:06:08 +00:00
<% } // httpclient %>
2016-07-11 06:54:26 +00:00
<tr>
<th colspan="2">
<%=intl._t("Custom options")%>
</th>
</tr>
<tr>
<td colspan="2">
<input type="text" id="customOptions" name="nofilter_customOptions" size="60" title="Custom Options" value="<%=editBean.getCustomOptions(curTunnel)%>" class="freetext" spellcheck="false"/>
</td>
</tr>
<tr>
<td class="buttons" colspan="2">
2005-11-12 02:38:55 +00:00
<input type="hidden" value="true" name="removeConfirm" />
2015-09-25 19:55:36 +00:00
<button id="controlCancel" class="control" type="submit" name="action" value="" title="Cancel"><%=intl._t("Cancel")%></button>
2016-07-11 06:54:26 +00:00
<button id="controlDelete" <%=(editBean.allowJS() ? "onclick=\"if (!confirm('Are you sure you want to delete?')) { return false; }\" " : "")%>accesskey="D" class="control" type="submit" name="action" value="Delete this proxy" title="Delete this Proxy"><%=intl._t("Delete")%></button>
<button id="controlSave" accesskey="S" class="control" type="submit" name="action" value="Save changes" title="Save Changes"><%=intl._t("Save")%></button>
</td>
</tr>
</table>
</div>
</form>
2012-10-27 18:51:50 +00:00
<%
} else {
2016-07-11 06:54:26 +00:00
%><div id="notReady"><%=intl._t("Tunnels are not initialized yet, please reload in two minutes.")%></div><%
2012-10-27 18:51:50 +00:00
} // isInitialized()
%>
2005-11-12 02:38:55 +00:00
</body>
2008-02-19 15:20:42 +00:00
</html>