Welcome to mirror list, hosted at ThFree Co, Russian Federation.

dev.gajim.org/gajim/gajim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'src/dialogs.py')
-rw-r--r--src/dialogs.py19
1 files changed, 13 insertions, 6 deletions
diff --git a/src/dialogs.py b/src/dialogs.py
index 4b1c1dd5b..24f93d126 100644
--- a/src/dialogs.py
+++ b/src/dialogs.py
@@ -3809,23 +3809,30 @@ class ESessionInfoWindow:
self.xml = gtkgui_helpers.get_glade('esession_info_window.glade')
self.xml.signal_autoconnect(self)
+ self.security_image = self.xml.get_widget('security_image')
self.update_info()
self.window = self.xml.get_widget('esession_info_window')
+
self.window.show_all()
def update_info(self):
- labeltext = _('''Your chat session with %(jid)s is encrypted.\n\nThis session's Short Authentication String is: %(sas)s''') % {'jid': self.session.jid, 'sas': self.session.sas}
+ labeltext = _('''Your chat session with %(jid)s is encrypted.\n\nThis session's Short Authentication String is %(sas)s.''') % {'jid': self.session.jid, 'sas': self.session.sas}
+ dir = os.path.join(gajim.DATA_DIR, 'pixmaps')
if self.session.verified_identity:
labeltext += '\n\n' + _('''You have already verified this contact's identity.''')
- w = self.xml.get_widget('verification_info')
- w.set_no_show_all(True)
- w.hide()
-
+ security_image = 'security-high-big.png'
if self.session.control:
self.session.control._show_lock_image(True, 'E2E', True,
self.session.is_loggable(), True)
+ else:
+ labeltext += '\n\n' + _('''To be certain that only the expected person can read your messages or send you messages, you need to verify their identity.''')
+ security_image = 'security-low-big.png'
+
+ path = os.path.join(dir, security_image)
+ filename = os.path.abspath(path)
+ self.security_image.set_from_file(filename)
self.xml.get_widget('info_display').set_text(labeltext)
@@ -3834,7 +3841,7 @@ class ESessionInfoWindow:
def on_verify_now_button_clicked(self, widget):
pritext = _('''Have you verified the remote contact's identity?''')
- sectext = _('''To prevent a man-in-the-middle attack, you should speak to %(jid)s directly (in person or on the phone) and verify that they see the same Short Authentication String (SAS) as you.\n\nThis session's Short Authentication String: <b>%(sas)s</b>''') % {'jid': self.session.jid, 'sas': self.session.sas}
+ sectext = _('''To prevent a man-in-the-middle attack, you should speak to %(jid)s directly (in person or on the phone) and verify that they see the same Short Authentication String (SAS) as you.\n\nThis session's Short Authentication String is <b>%(sas)s</b>.''') % {'jid': self.session.jid, 'sas': self.session.sas}
sectext += '\n\n' + _('Did you talk to the remote contact and verify the SAS?')
def on_yes(checked):