diff --git a/apps/routerconsole/java/src/net/i2p/router/web/helpers/HomeHelper.java b/apps/routerconsole/java/src/net/i2p/router/web/helpers/HomeHelper.java index f2f4ec48d..f1036f48f 100644 --- a/apps/routerconsole/java/src/net/i2p/router/web/helpers/HomeHelper.java +++ b/apps/routerconsole/java/src/net/i2p/router/web/helpers/HomeHelper.java @@ -191,9 +191,19 @@ public class HomeHelper extends HelperBase { for (App app : apps) { String url; if (app.name.equals(website) && app.url.equals("http://127.0.0.1:7658/")) { + PortMapper pm = _context.portMapper(); + int port = pm.getPort(PortMapper.SVC_EEPSITE); + int sslPort = pm.getPort(PortMapper.SVC_HTTPS_EEPSITE); + if (port <= 0 && sslPort <= 0) + continue; // fixup eepsite link - url = "http://" + _context.portMapper().getActualHost(PortMapper.SVC_EEPSITE, "127.0.0.1") + - ':' + _context.portMapper().getPort(PortMapper.SVC_EEPSITE, 7658) + '/'; + if (sslPort > 0) { + url = "https://" + pm.getActualHost(PortMapper.SVC_HTTPS_EEPSITE, "127.0.0.1") + + ':' + sslPort + '/'; + } else { + url = "http://" + pm.getActualHost(PortMapper.SVC_EEPSITE, "127.0.0.1") + + ':' + port + '/'; + } } else { url = app.url; // check for disabled webapps and other things diff --git a/apps/routerconsole/java/src/net/i2p/router/web/helpers/SummaryBarRenderer.java b/apps/routerconsole/java/src/net/i2p/router/web/helpers/SummaryBarRenderer.java index 4761f6188..f86d60f05 100644 --- a/apps/routerconsole/java/src/net/i2p/router/web/helpers/SummaryBarRenderer.java +++ b/apps/routerconsole/java/src/net/i2p/router/web/helpers/SummaryBarRenderer.java @@ -21,7 +21,6 @@ import net.i2p.router.web.Messages; import net.i2p.router.web.NavHelper; import net.i2p.router.web.NewsHelper; import net.i2p.router.web.StatSummarizer; -import net.i2p.router.web.WebAppStarter; import net.i2p.util.PortMapper; import net.i2p.util.SystemVersion; @@ -214,7 +213,8 @@ class SummaryBarRenderer { "
"); - if (WebAppStarter.isWebAppRunning("susimail")) { + PortMapper pm = _context.portMapper(); + if (pm.getPort(PortMapper.SVC_SUSIMAIL) > 0) { buf.append("") @@ -222,7 +222,7 @@ class SummaryBarRenderer { .append("\n"); } - if (WebAppStarter.isWebAppRunning("i2psnark")) { + if (pm.getPort(PortMapper.SVC_I2PSNARK) > 0) { buf.append("") @@ -230,17 +230,29 @@ class SummaryBarRenderer { .append("\n"); } - buf.append(" 0 || port > 0) { + String svc; + if (sslPort > 0) { + buf.append("") .append(nbsp(_t("Web Server"))) - .append("\n") + .append("\n"); + } - .append(NavHelper.getClientAppLinks(_context)) + buf.append(NavHelper.getClientAppLinks(_context)) .append("
\n"); return buf.toString(); @@ -256,7 +268,8 @@ class SummaryBarRenderer { "
\n"); - if (WebAppStarter.isWebAppRunning("susidns")) { + PortMapper pm = _context.portMapper(); + if (pm.getPort(PortMapper.SVC_SUSIDNS) > 0) { buf.append("") @@ -278,7 +291,7 @@ class SummaryBarRenderer { .append(nbsp(_t("Help"))) .append("\n"); - if (WebAppStarter.isWebAppRunning("i2ptunnel")) { + if (pm.getPort(PortMapper.SVC_I2PTUNNEL) > 0) { buf.append("") diff --git a/history.txt b/history.txt index ca03d5225..33af07fc0 100644 --- a/history.txt +++ b/history.txt @@ -1,4 +1,15 @@ +2018-03-14 zzz + * Console: + - Hide links to webapps and eepsite if not running (ticket #2161) + - Hide link to /configplugins if disabled + * i2ptunnel: Hide links to webapps that are not runnning (ticket #2161) + * SusDNS: Translate svg image text (ticket #1749) + +2018-03-12 zzz + * Susimail: Fix up compose.js (ticket #2176) + 2018-03-11 zzz + * Crypto: Add utils for renewing a cert in a keystore * Router: More peer selection fixes for hidden mode 2018-03-10 zzz diff --git a/router/java/src/net/i2p/router/RouterVersion.java b/router/java/src/net/i2p/router/RouterVersion.java index ea17ad55f..e1f87e077 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 = 15; + public final static long BUILD = 16; /** for example "-test" */ public final static String EXTRA = "";