From 596c819957d6e74db397e55a2f0c4dcb2b1cc65d Mon Sep 17 00:00:00 2001 From: Micah Lee Date: Tue, 19 Oct 2021 08:53:52 -0700 Subject: [PATCH] Allow custom snowflake bridges --- desktop/src/onionshare/tor_settings_dialog.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/desktop/src/onionshare/tor_settings_dialog.py b/desktop/src/onionshare/tor_settings_dialog.py index adad6931..38ff512a 100644 --- a/desktop/src/onionshare/tor_settings_dialog.py +++ b/desktop/src/onionshare/tor_settings_dialog.py @@ -809,10 +809,14 @@ class TorSettingsDialog(QtWidgets.QDialog): meek_lite_pattern = re.compile( "(meek_lite)(\s)+([0-9]+\.[0-9]+\.[0-9]+\.[0-9]+:[0-9]+)(\s)+([0-9A-Z]+)(\s)+url=(.+)(\s)+front=(.+)" ) + snowflake_pattern = re.compile( + "(snowflake)(\s)+([0-9]+\.[0-9]+\.[0-9]+\.[0-9]+:[0-9]+)(\s)+([0-9A-Z]+)" + ) if ( ipv4_pattern.match(bridge) or ipv6_pattern.match(bridge) or meek_lite_pattern.match(bridge) + or snowflake_pattern.match(bridge) ): new_bridges.append(bridge) bridges_valid = True