[Pkg-privacy-commits] [torbrowser-launcher] 07/07: add patch for 797337 as debian patch…

Holger Levsen holger at moszumanska.debian.org
Tue Mar 1 16:05:41 UTC 2016


This is an automated email from the git hooks/post-receive script.

holger pushed a commit to branch debian/proposed
in repository torbrowser-launcher.

commit 40c7a56d46b9b5e5a5d16087b1e5340f8385a791
Author: Holger Levsen <holger at layer-acht.org>
Date:   Tue Mar 1 17:02:46 2016 +0100

    add patch for 797337 as debian patch…
---
 ...-message-for-socks-failures-Closes-797337.patch | 40 ++++++++++++++++++++++
 debian/patches/series                              |  1 +
 2 files changed, 41 insertions(+)

diff --git a/debian/patches/0005-error-message-for-socks-failures-Closes-797337.patch b/debian/patches/0005-error-message-for-socks-failures-Closes-797337.patch
new file mode 100644
index 0000000..c71088d
--- /dev/null
+++ b/debian/patches/0005-error-message-for-socks-failures-Closes-797337.patch
@@ -0,0 +1,40 @@
+From bcfcd7af072cdcf5576fca3af86a7bde8484e94b Mon Sep 17 00:00:00 2001
+From: Holger Levsen <holger at layer-acht.org>
+Date: Tue, 1 Mar 2016 16:59:42 +0100
+Subject: [PATCH] error message for socks failures (Closes: #797337)
+
+thanks to Michael Gold <michael at bitplane.org>
+---
+ torbrowser_launcher/launcher.py | 9 ++++++++-
+ 1 file changed, 8 insertions(+), 1 deletion(-)
+
+diff --git a/torbrowser_launcher/launcher.py b/torbrowser_launcher/launcher.py
+index 9049cd9..f3ae614 100644
+--- a/torbrowser_launcher/launcher.py
++++ b/torbrowser_launcher/launcher.py
+@@ -34,7 +34,7 @@ from twisted.web.iweb import IPolicyForHTTPS
+ from twisted.internet.protocol import Protocol
+ from twisted.internet.ssl import CertificateOptions
+ from twisted.internet._sslverify import ClientTLSOptions
+-from twisted.internet.error import DNSLookupError
++from twisted.internet.error import DNSLookupError, ConnectionRefusedError
+ from zope.interface import implementer
+ 
+ import xml.etree.ElementTree as ET
+@@ -385,6 +385,13 @@ class Launcher:
+                     else:
+                         self.set_gui('error', _('The SSL certificate served by https://www.torproject.org is invalid! You may be under attack.'), [], False)
+ 
++        elif isinstance(f.value, ConnectionRefusedError) and self.common.settings['download_over_tor']:
++            # If we're using Tor, we'll only get this error when we fail to
++            # connect to the SOCKS server.  If the connection fails at the
++            # remote end, we'll get txsocksx.errors.ConnectionRefused.
++            addr = self.common.settings['tor_socks_address']
++            self.set_gui('error', _("Error connecting to Tor at {0}").format(addr), [], False)
++
+         else:
+             self.set_gui('error', _("Error starting download:\n\n{0}\n\nAre you connected to the internet?").format(f.value), [], False)
+ 
+-- 
+1.9.1
+
diff --git a/debian/patches/series b/debian/patches/series
index 604392b..ecbe45d 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -2,3 +2,4 @@ Include-local-overrides-file-in-AppArmor-profiles.-C.patch
 Set-torbrowser.start-tor-browser-and-usr.bin.torbrow.patch
 0003-fix-apparmor-profile-to-support-self-upgrade.patch
 0004-make-socks4-port-configurable.-Closes-797339.patch
+0005-error-message-for-socks-failures-Closes-797337.patch

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-privacy/packages/torbrowser-launcher.git



More information about the Pkg-privacy-commits mailing list