diff --git a/apps/i2ptunnel/java/src/net/i2p/i2ptunnel/ui/TunnelConfig.java b/apps/i2ptunnel/java/src/net/i2p/i2ptunnel/ui/TunnelConfig.java index 8f8a92f3a..509d55b98 100644 --- a/apps/i2ptunnel/java/src/net/i2p/i2ptunnel/ui/TunnelConfig.java +++ b/apps/i2ptunnel/java/src/net/i2p/i2ptunnel/ui/TunnelConfig.java @@ -942,7 +942,7 @@ public class TunnelConfig { if (!_addClientAuth) { _addClientAuth = true; if (_newClientName == null || _newClientName.length() == 0) - _newClientName = Base64.encode(DataHelper.getUTF8(GeneralHelper._t("Client", _context) + " 1")); + _newClientName = GeneralHelper._t("Client", _context) + " 1"; } } } @@ -962,6 +962,11 @@ public class TunnelConfig { name = Base64.encode(DataHelper.getUTF8(GeneralHelper._t("Client", _context) + ' ' + (i + 1))); clientAuth.add(name + ':' + key); } + if (clientAuth.isEmpty() && !_addClientAuth) { + // if we revoked all of them, add a new one + _addClientAuth = true; + _newClientName = GeneralHelper._t("Client", _context) + " 1"; + } } if (_addClientAuth && _newClientName != null) { String name = _newClientName;