diff --git a/apps/i2ptunnel/java/src/net/i2p/i2ptunnel/web/EditBean.java b/apps/i2ptunnel/java/src/net/i2p/i2ptunnel/web/EditBean.java index e328f64aec..4c9d3f1264 100644 --- a/apps/i2ptunnel/java/src/net/i2p/i2ptunnel/web/EditBean.java +++ b/apps/i2ptunnel/java/src/net/i2p/i2ptunnel/web/EditBean.java @@ -8,6 +8,7 @@ package net.i2p.i2ptunnel.web; * */ +import java.io.File; import java.io.IOException; import java.util.List; import java.util.Set; @@ -79,7 +80,10 @@ public class EditBean extends IndexBean { return ""; String keyFile = tun.getPrivKeyFile(); if (keyFile != null && keyFile.trim().length() > 0) { - PrivateKeyFile pkf = new PrivateKeyFile(keyFile); + File f = new File(keyFile); + if (!f.isAbsolute()) + f = new File(_context.getConfigDir(), keyFile); + PrivateKeyFile pkf = new PrivateKeyFile(f); try { Destination d = pkf.getDestination(); if (d == null) @@ -87,8 +91,9 @@ public class EditBean extends IndexBean { SigningPrivateKey privKey = pkf.getSigningPrivKey(); if (privKey == null) return ""; - //System.err.println("Signing " + spoof + " with " + Base64.encode(privKey.getData())); Signature sig = _context.dsa().sign(spoof.getBytes("UTF-8"), privKey); + if (sig == null) + return ""; return Base64.encode(sig.getData()); } catch (I2PException e) { } catch (IOException e) {} diff --git a/apps/i2ptunnel/jsp/editServer.jsp b/apps/i2ptunnel/jsp/editServer.jsp index cc85904d32..77f7171743 100644 --- a/apps/i2ptunnel/jsp/editServer.jsp +++ b/apps/i2ptunnel/jsp/editServer.jsp @@ -226,26 +226,49 @@ input.default { width: 1px; height: 1px; visibility: hidden; } <%=intl._t("Local destination")%>(L): - <% String b64 = editBean.getDestinationBase64(curTunnel); - if (!"".equals(b64)) { - String name = editBean.getSpoofedHost(curTunnel); - if (name == null || name.equals("")) - name = editBean.getTunnelName(curTunnel); - if (!"".equals(name)) { %> - <%=intl._t("Add to local addressbook")%> - <% } - } %> <% if (("httpserver".equals(tunnelType)) || ("httpbidirserver".equals(tunnelType))) { + String sig = editBean.getNameSignature(curTunnel); + if (sig.length() > 0) { %>
- +
- <% } %> + <% + } // sig + } // type + String b64 = editBean.getDestinationBase64(curTunnel); + if (!"".equals(b64)) { + %> +
+ <% + b64 = b64.replace("=", "%3d"); + String name = editBean.getSpoofedHost(curTunnel); + if (name == null || name.equals("")) + name = editBean.getTunnelName(curTunnel); + if (name != null && !name.equals("") && !name.contains(" ") && name.endsWith(".i2p")) { + %> + + <%=intl._t("Add to local addressbook")%> + <% + } else { + %> + + <%=intl._t("Set name with .i2p suffix to enable QR code generation")%> + <% + } // name + %> +
+ <% + } // b64 + + %> diff --git a/history.txt b/history.txt index be605796a7..db335f671d 100644 --- a/history.txt +++ b/history.txt @@ -1,3 +1,14 @@ +2016-02-26 zzz + * Console: + - Add X-Content-Type-Options header everywhere (ticket #1763) + - Don't display error after clicking restart on /graph page (ticket #1582) + * i2ptunnel: + - Fix default shouldBundleReplyInfo for non-HTTP servers + - Fix display of hostname signature + - Add QR code generation + * Router: Log full path to wrapper.log when dumping threads + * Transports: Increase connection limits for class N and higher + 2016-02-22 zzz * Console: Improve news CSS (ticket #1710) * Crypto: Blacklist certificates by SHA1 hash, not by serial/CN/OU @@ -327,7 +338,7 @@ Prop from i2p.i2p.zzz.test2: * SSU: - Support extended options - Add support for requesting a relay tag via - Session Request extended options (ticket #1465) + Session Request extended options (tickets #1465, #1656) * Tunnels: - Locking fixes - Don't set stats in our own profile diff --git a/router/java/src/net/i2p/router/RouterVersion.java b/router/java/src/net/i2p/router/RouterVersion.java index a6204817e3..f2522cd4ed 100644 --- a/router/java/src/net/i2p/router/RouterVersion.java +++ b/router/java/src/net/i2p/router/RouterVersion.java @@ -18,7 +18,7 @@ public class RouterVersion { /** deprecated */ public final static String ID = "Monotone"; public final static String VERSION = CoreVersion.VERSION; - public final static long BUILD = 8; + public final static long BUILD = 9; /** for example "-test" */ public final static String EXTRA = "";