summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--changes/feature_reintegrate_smtp1
-rw-r--r--changes/improve_displayed_error_messages2
-rw-r--r--src/leap/gui/mainwindow.py27
-rw-r--r--src/leap/services/__init__.py2
-rw-r--r--src/leap/services/soledad/soledadbootstrapper.py2
5 files changed, 25 insertions, 9 deletions
diff --git a/changes/feature_reintegrate_smtp b/changes/feature_reintegrate_smtp
new file mode 100644
index 00000000..3466dc57
--- /dev/null
+++ b/changes/feature_reintegrate_smtp
@@ -0,0 +1 @@
+ o Reintegrate SMTP relay module. Closes #3375 \ No newline at end of file
diff --git a/changes/improve_displayed_error_messages b/changes/improve_displayed_error_messages
new file mode 100644
index 00000000..90f8b7ff
--- /dev/null
+++ b/changes/improve_displayed_error_messages
@@ -0,0 +1,2 @@
+ o Display a more generic error message in the main window, and leave
+ the detailed one for the log. Closes #3373. \ No newline at end of file
diff --git a/src/leap/gui/mainwindow.py b/src/leap/gui/mainwindow.py
index 395b9329..1c1236af 100644
--- a/src/leap/gui/mainwindow.py
+++ b/src/leap/gui/mainwindow.py
@@ -745,11 +745,13 @@ class MainWindow(QtGui.QMainWindow):
download_if_needed=True)
else:
self._login_widget.set_status(
- self.tr("Could not load provider configuration."))
+ self.tr("Unable to login: Problem with provider"))
+ logger.error("Could not load provider configuration.")
self._login_widget.set_enabled(True)
else:
self._login_widget.set_status(
- data[self._provider_bootstrapper.ERROR_KEY])
+ self.tr("Unable to login: Problem with provider"))
+ logger.error(data[self._provider_bootstrapper.ERROR_KEY])
self._login_widget.set_enabled(True)
def _login(self):
@@ -852,7 +854,8 @@ class MainWindow(QtGui.QMainWindow):
self._login_defer = self._srp_auth.authenticate(username, password)
else:
self._login_widget.set_status(
- data[self._provider_bootstrapper.ERROR_KEY])
+ "Unable to login: Problem with provider")
+ logger.error(data[self._provider_bootstrapper.ERROR_KEY])
self._login_widget.set_enabled(True)
def _authentication_finished(self, ok, message):
@@ -863,7 +866,13 @@ class MainWindow(QtGui.QMainWindow):
Once the user is properly authenticated, try starting the EIP
service
"""
+
+ # In general we want to "filter" likely complicated error
+ # messages, but in this case, the messages make more sense as
+ # they come. Since they are "Unknown user" or "Unknown
+ # password"
self._login_widget.set_status(message, error=not ok)
+
if ok:
self._logged_user = self._login_widget.get_user()
self.ui.action_log_out.setEnabled(True)
@@ -982,12 +991,14 @@ class MainWindow(QtGui.QMainWindow):
# TODO: Make the encrypted_only configurable
from leap.mail.smtp import setup_smtp_relay
+ client_cert = self._eip_config.get_client_cert_path(
+ self._provider_config)
setup_smtp_relay(port=1234,
keymanager=self._keymanager,
smtp_host=host,
smtp_port=port,
- smtp_username=".",
- smtp_password=".",
+ smtp_cert=client_cert,
+ smtp_key=client_cert,
encrypted_only=False)
def _get_socket_host(self):
@@ -1274,7 +1285,8 @@ class MainWindow(QtGui.QMainWindow):
self._login_widget.set_cancel(False)
self._login_widget.set_enabled(True)
self._login_widget.set_status(
- data[self._provider_bootstrapper.ERROR_KEY])
+ self.tr("Unable to connect: Problem with provider"))
+ logger.error(data[self._provider_bootstrapper.ERROR_KEY])
def _eip_intermediate_stage(self, data):
"""
@@ -1289,7 +1301,8 @@ class MainWindow(QtGui.QMainWindow):
passed = data[self._provider_bootstrapper.PASSED_KEY]
if not passed:
self._login_widget.set_status(
- data[self._provider_bootstrapper.ERROR_KEY])
+ self.tr("Unable to connect: Problem with provider"))
+ logger.error(data[self._provider_bootstrapper.ERROR_KEY])
self._already_started_eip = False
def _eip_finished(self, exitCode):
diff --git a/src/leap/services/__init__.py b/src/leap/services/__init__.py
index fc4aa416..253359cd 100644
--- a/src/leap/services/__init__.py
+++ b/src/leap/services/__init__.py
@@ -17,7 +17,7 @@
"""
Services module.
"""
-DEPLOYED = ["openvpn"] # for 0.2.2 release
+DEPLOYED = ["openvpn", "mx"]
def get_supported(services):
diff --git a/src/leap/services/soledad/soledadbootstrapper.py b/src/leap/services/soledad/soledadbootstrapper.py
index 6f0c88b4..a952fac5 100644
--- a/src/leap/services/soledad/soledadbootstrapper.py
+++ b/src/leap/services/soledad/soledadbootstrapper.py
@@ -188,7 +188,7 @@ class SoledadBootstrapper(AbstractBootstrapper):
srp_auth = SRPAuth(self._provider_config)
self._keymanager = KeyManager(
address,
- "https://%s:6425" % (self._provider_config.get_domain()),
+ "https://nicknym.%s:6425" % (self._provider_config.get_domain(),),
self._soledad,
#token=srp_auth.get_token(), # TODO: enable token usage
session_id=srp_auth.get_session_id(),