source: apps/routerconsole/jsp/config.jsp @ b80cbbdd

Last change on this file since b80cbbdd was b80cbbdd, checked in by z3d <z3d@…>, 12 years ago

Return of the mia <hr>'s.

  • Property mode set to 100644
File size: 16.5 KB
1<%@page contentType="text/html" %>
2<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
5<title>I2P Router Console - config networking</title>
6<%@include file="css.jsp" %>
9<%@include file="summary.jsp" %>
11<jsp:useBean class="net.i2p.router.web.ConfigNetHelper" id="nethelper" scope="request" />
12<jsp:setProperty name="nethelper" property="contextId" value="<%=(String)session.getAttribute("i2p.contextId")%>" />
13<h1>I2P Network Configuration</h1>
14<div class="main" id="main">
15 <%@include file="confignav.jsp" %>
17 <jsp:useBean class="net.i2p.router.web.ConfigNetHandler" id="formhandler" scope="request" />
18 <jsp:setProperty name="formhandler" property="*" />
19 <jsp:setProperty name="formhandler" property="contextId" value="<%=(String)session.getAttribute("i2p.contextId")%>" />
20 <jsp:getProperty name="formhandler" property="allMessages" />
21<div class="configure">
22 <form action="config.jsp" method="POST">
23 <% String prev = System.getProperty("net.i2p.router.web.ConfigNetHandler.nonce");
24    if (prev != null) System.setProperty("net.i2p.router.web.ConfigNetHandler.noncePrev", prev);
25    System.setProperty("net.i2p.router.web.ConfigNetHandler.nonce", new java.util.Random().nextLong()+""); %>
26 <input type="hidden" name="nonce" value="<%=System.getProperty("net.i2p.router.web.ConfigNetHandler.nonce")%>" />
27 <input type="hidden" name="action" value="blah" />
28 <h3>Bandwidth limiter</h3><p>
29 <b>I2P will work best if you configure your rates to match the speed of your internet connection.</b>
30 </p><p>
31   <div class="wideload"><table><tr><td><input style="text-align: right; width: 5em;" name="inboundrate" type="text" size="5" maxlength="5" value="<jsp:getProperty name="nethelper" property="inboundRate" />" /> KBps In
32        </td><td>(<jsp:getProperty name="nethelper" property="inboundRateBits" />)</td>
33<!-- let's keep this simple...
34 bursting up to
35    <input name="inboundburstrate" type="text" size="5" value="<jsp:getProperty name="nethelper" property="inboundBurstRate" />" /> KBps for
36    <jsp:getProperty name="nethelper" property="inboundBurstFactorBox" /><br>
38    </tr><tr>
39        <td><input style="text-align: right; width: 5em;" name="outboundrate" type="text" size="5" maxlength="5" value="<jsp:getProperty name="nethelper" property="outboundRate" />" /> KBps Out
40        </td><td>(<jsp:getProperty name="nethelper" property="outboundRateBits" />)</td>
41<!-- let's keep this simple...
42 bursting up to
43    <input name="outboundburstrate" type="text" size="2" value="<jsp:getProperty name="nethelper" property="outboundBurstRate" />" /> KBps for
44  <jsp:getProperty name="nethelper" property="outboundBurstFactorBox" /><br>
45 <i>KBps = kilobytes per second = 1024 bytes per second = 8192 bits per second.<br>
46    A negative rate sets the default.</i><br>
48    </tr><tr>
49        <td><jsp:getProperty name="nethelper" property="sharePercentageBox" /> Share</td>
50        <td>(<jsp:getProperty name="nethelper" property="shareRateBits" />)
52 <% int share = nethelper.getShareBandwidth();
53    if (share < 12) {
54        out.print("<b>NOTE</b>: You have configured I2P to share only " + share + "KBps. ");
55        out.print("I2P requires at least 12KBps to enable sharing. ");
56        out.print("Please enable sharing (participating in tunnels) by configuring more bandwidth. ");
57        out.print("It improves your anonymity by creating cover traffic, and helps the network.<br>");
58    } else {
59        out.print("You have configured I2P to share<b> " + share + "KBps</b>. ");
60        out.print("The higher the share bandwidth the more you improve your anonymity and help the network.<hr>");
61    }
62 %>
63</p><div class="formaction">
64<input type="submit" name="save" value="Save changes" /> <input type="reset" value="Cancel" /></div>
65 <!--
66 <b>Enable load testing: </b>
67<input type="checkbox" class="optbox" name="enableloadtesting" value="true" <jsp:getProperty name="nethelper" property="enableLoadTesting" /> />
68 <p>If enabled, your router will periodically anonymously probe some of your peers
69 to see what sort of throughput they can handle.  This improves your router's ability
70 to pick faster peers, but can cost substantial bandwidth.  Relevant data from the
71 load testing is fed into the profiles as well as the
72 <a href="oldstats.jsp#test.rtt">test.rtt</a> and related stats.</p>
73 <br>
75 <h3>IP and Transport Configuration</h3><p>
76 <b>The default settings will work for most people. There is <a href="#chelp">help below</a>.</b>
77 </p><p><b>UPnP Configuration:</b><br>
78    <input type="checkbox" class="optbox" name="upnp" value="true" <jsp:getProperty name="nethelper" property="upnpChecked" /> />
79    Enable UPnP to open firewall ports - <a href="peers.jsp#upnp">UPnP status</a>
80 </p><p><b>IP Configuration:</b><br>
81 Externally reachable hostname or IP address:<br>
82    <input type="radio" class="optbox" name="udpAutoIP" value="local,upnp,ssu" <%=nethelper.getUdpAutoIPChecked(3) %> />
83    Use all auto-detect methods<br>
84    <input type="radio" class="optbox" name="udpAutoIP" value="local,ssu" <%=nethelper.getUdpAutoIPChecked(4) %> />
85    Disable UPnP IP address detection<br>
86    <input type="radio" class="optbox" name="udpAutoIP" value="upnp,ssu" <%=nethelper.getUdpAutoIPChecked(5) %> />
87    Ignore local interface IP address<br>
88    <input type="radio" class="optbox" name="udpAutoIP" value="ssu" <%=nethelper.getUdpAutoIPChecked(0) %> />
89    Use SSU IP address detection only<br>
90    <input type="radio" class="optbox" name="udpAutoIP" value="fixed" <%=nethelper.getUdpAutoIPChecked(1) %> />
91    Specify hostname or IP:
92    <input name ="udpHost1" type="text" size="16" value="<jsp:getProperty name="nethelper" property="udphostname" />" />
93    <% String[] ips = nethelper.getAddresses();
94       if (ips.length > 0) {
95           out.print(" or <select name=\"udpHost2\"><option value=\"\" selected=\"true\">Select Interface</option>\n");
96           for (int i = 0; i < ips.length; i++) {
97               out.print("<option value=\"");
98               out.print(ips[i]);
99               out.print("\">");
100               out.print(ips[i]);
101               out.print("</option>\n");
102           }
103           out.print("</select>\n");
104       }
105    %>
106    <br>
107    <input type="radio" class="optbox" name="udpAutoIP" value="hidden" <%=nethelper.getUdpAutoIPChecked(2) %> />
108    Hidden mode - do not publish IP <i>(prevents participating traffic)</i><br>
109 </p><p><b>UDP Configuration:</b><br>
110 UDP port:
111 <input name ="udpPort" type="text" size="5" maxlength="5" value="<jsp:getProperty name="nethelper" property="configuredUdpPort" />" /><br>
112<!-- let's keep this simple...
113<input type="checkbox" class="optbox" name="requireIntroductions" value="true" <jsp:getProperty name="nethelper" property="requireIntroductionsChecked" /> />
114 Require SSU introductions
115 <i>(Enable if you cannot open your firewall)</i>
116 </p><p>
117 Current External UDP address: <i><jsp:getProperty name="nethelper" property="udpAddress" /></i><br>
119 </p><p>
120 <b>TCP Configuration:</b><br>
121 Externally reachable hostname or IP address:<br>
122    <input type="radio" class="optbox" name="ntcpAutoIP" value="true" <%=nethelper.getTcpAutoIPChecked(2) %> />
123    Use auto-detected IP address
124    <i>(currently <jsp:getProperty name="nethelper" property="udpIP" />)</i>
125    if we are not firewalled<br>
126    <input type="radio" class="optbox" name="ntcpAutoIP" value="always" <%=nethelper.getTcpAutoIPChecked(3) %> />
127    Always use auto-detected IP address (Not firewalled)<br>
128    <input type="radio" class="optbox" name="ntcpAutoIP" value="false" <%=nethelper.getTcpAutoIPChecked(1) %> />
129    Specify hostname or IP:
130    <input name ="ntcphost" type="text" size="16" value="<jsp:getProperty name="nethelper" property="ntcphostname" />" /><br>
131    <input type="radio" class="optbox" name="ntcpAutoIP" value="false" <%=nethelper.getTcpAutoIPChecked(0) %> />
132    Disable inbound (Firewalled)<br>
133    <input type="radio" class="optbox" name="ntcpAutoIP" value="disabled" <%=nethelper.getTcpAutoIPChecked(4) %> />
134    Completely disable <i>(select only if behind a firewall that throttles or blocks outbound TCP)</i><br>
135 </p><p>
136 Externally reachable TCP port:<br>
137    <input type="radio" class="optbox" name="ntcpAutoPort" value="2" <%=nethelper.getTcpAutoPortChecked(2) %> />
138    Use the same port configured for UDP
139    <i>(currently <jsp:getProperty name="nethelper" property="udpPort" />)</i><br>
140    <input type="radio" class="optbox" name="ntcpAutoPort" value="1" <%=nethelper.getTcpAutoPortChecked(1) %> />
141    Specify Port:
142    <input name ="ntcpport" type="text" size="5" maxlength="5" value="<jsp:getProperty name="nethelper" property="ntcpport" />" /><br>
143 </p><p><b>Note: Changing these settings will restart your router.</b></p>
144<hr><div class="formaction">
145 <input type="submit" name="save" value="Save changes" /> <input type="reset" value="Cancel" />
146</div><h3><a name="chelp">Configuration Help:</a></h3><div align="justify"><p>
147 While I2P will work fine behind most firewalls, your speeds and network integration will generally improve
148 if the I2P port (generally 8887) is forwarded for both UDP and TCP.
149 </p><p>
150 If you can, please poke a hole in your firewall to allow unsolicited UDP and TCP packets to reach
151    you.  If you can't, I2P supports UPnP (Universal Plug and Play) and UDP hole punching
152    with "SSU introductions" to relay traffic. Most of the options above are for special situations,
153    for example where UPnP does not work correctly, or a firewall not under your control is doing
154    harm. Certain firewalls such as symmetric NATs may not work well with I2P.
155 </p>
156<!-- let's keep this simple...
157<input type="submit" name="recheckReachability" value="Check network reachability..." />
161 UPnP is used to communicate with Internet Gateway Devices (IGDs) to detect the external IP address
162 and forward ports.
163 UPnP support is beta, and may not work for any number of reasons:
165<li class="tidylist">No UPnP-compatible device present
166<li class="tidylist">UPnP disabled on the device
167<li class="tidylist">Software firewall interference with UPnP
168<li class="tidylist">Bugs in the device's UPnP implementation
169<li class="tidylist">Multiple firewall/routers in the internet connection path
170<li class="tidylist">UPnP device change, reset, or address change
172 Reviewing the <a href="peers.jsp#upnp">UPnP status</a> may help.
173 UPnP may be enabled or disabled above, but a change requires a router restart to take effect.
174</p><p>Hostnames entered above will be published in the network database.
175    They are <b>not private</b>.
176    Also, <b>do not enter a private IP address</b> like or
177    If you specify the wrong IP address or
178    hostname, or do not properly configure your NAT or firewall, your network performance will degrade
179    substantially.  When in doubt, leave the settings at the defaults.
181<h3><a name="help">Reachability Help:</a></h3><p>
182 While I2P will work fine behind most firewalls, your speeds and network integration will generally improve
183 if the I2P port (generally 8887) to both UDP and TCP.
184 If you think you have opened up your firewall and I2P still thinks you are firewalled, remember
185 that you may have multiple firewalls, for example both software packages and external hardware routers.
186 If there is an error, the <a href="logs.jsp">logs</a> may also help diagnose the problem.
187 <ul>
188<li class="tidylist"><b>OK</b> - Your UDP port does not appear to be firewalled.
189<li class="tidylist"><b>Firewalled</b> - Your UDP port appears to be firewalled.
190     As the firewall detection methods are not 100% reliable, this may occasionally be displayed in error.
191     However, if it appears consistently, you should check whether both your external and internal
192     firewalls are open on port 8887. I2P will work fine when firewalled, there is no reason for concern.
193     When firewalled, the router uses "introducers" to relay inbound connections.
194     However, you will get more participating traffic and help the network more if you can open your
195     firewall(s). If you think you have already done so, remember that you may have both a hardware
196     and a software firewall, or be behind an additional, institutional firewall you cannot control.
197     Also, some routers cannot correctly forward both TCP and UDP on a single port, or may have other
198     limitations or bugs that prevent them from passing traffic through to I2P.
199<li class="tidylist"><b>Testing</b> - The router is currently testing whether your UDP port is firewalled.
200<li class="tidylist"><b>Hidden</b> - The router is not configured to publish its address,
201     therefore it does not expect incoming connections.
202<li class="tidylist"><b>WARN - Firewalled and Fast</b> - You have configured I2P to share more than 128KBps of bandwidth,
203     but you are firewalled. While I2P will work fine in this configuration, if you really have
204     over 128KBps of bandwidth to share, it will be much more helpful to the network if
205     you open your firewall.
206<li class="tidylist"><b>WARN - Firewalled and Floodfill</b> - You have configured I2P to be a floodfill router, but
207     you are firewalled. For best participation as a floodfill router, you should open your firewall.
208<li class="tidylist"><b>WARN - Firewalled with Inbound TCP Enabled</b> - You have configured inbound TCP, however
209     your UDP port is firewalled, and therefore it is likely that your TCP port is firewalled as well.
210     If your TCP port is firewalled with inbound TCP enabled, routers will not be able to contact
211     you via TCP, which will hurt the network. Please open your firewall or disable inbound TCP above.
212<li class="tidylist"><b>WARN - Firewalled with UDP Disabled</b> -
213     You have configured inbound TCP, however
214     you have disabled UDP. You appear to be firewalled on TCP, therefore your router cannot
215     accept inbound connections.
216     Please open your firewall or enable UDP.
217<li class="tidylist"><b>ERR - Clock Skew</b> - Your system's clock is skewed, which will make it difficult
218     to participate in the network. Correct your clock setting if this error persists.
219<li class="tidylist"><b>ERR - Private TCP Address</b> - You must never advertise an unroutable IP address such as
220 or as your external address. Correct the address or disable inbound TCP above.
221<li class="tidylist"><b>ERR - SymmetricNAT</b> - I2P detected that you are firewalled by a Symmetric NAT.
222     I2P does not work well behind this type of firewall. You will probably not be able to
223     accept inbound connections, which will limit your participation in the network.
224<li class="tidylist"><b>ERR - UDP Port In Use - Set i2np.udp.internalPort=xxxx in advanced config and restart</b> -
225     I2P was unable to bind to port 8887 or other configured port.
226     Check to see if another program is using port 8887. If so, stop that program or configure
227     I2P to use a different port. This may be a transient error, if the other program is no longer
228     using the port. However, a restart is always required after this error.
229<li class="tidylist"><b>ERR - UDP Disabled and Inbound TCP host/port not set</b> -
230     You have not configured inbound TCP with a hostname and port above, however
231     you have disabled UDP. Therefore your router cannot accept inbound connections.
232     Please configure a TCP host and port above or enable UDP.
233<li class="tidylist"><b>ERR - Client Manager I2CP Error - check logs</b> -
234     This is usually due to a port 7654 conflict. Check the logs to verify. Do you have another I2P instance running?
235     Stop the conflicting program and restart I2P.
236 </ul></p><br>
237      <!--
238 <b>Dynamic Router Keys: </b>
239 <input type="checkbox" class="optbox" name="dynamicKeys" value="true" <jsp:getProperty name="nethelper" property="dynamicKeysChecked" /> /><br>
240 <p>
241 This setting causes your router identity to be regenerated every time your IP address
242 changes. If you have a dynamic IP this option can speed up your reintegration into
243 the network (since people will have shitlisted your old router identity), and, for
244 very weak adversaries, help frustrate trivial
245 <a href="">intersection
246 attacks</a> against the NetDB.  Your different router identities would only be
247 'hidden' among other I2P users at your ISP, and further analysis would link
248 the router identities further.</p>
249 <p>Note that when I2P detects an IP address change, it will automatically
250 initiate a restart in order to rekey and to disconnect from peers before they
251 update their profiles - any long lasting client connections will be disconnected,
252 though such would likely already be the case anyway, since the IP address changed.
253 </p>
254 <br>
Note: See TracBrowser for help on using the repository browser.