richard pushed to branch tor-browser-102.12.0esr-12.5-1 at The Tor Project / Applications / Tor Browser
Commits:
-
e6cc145a
by Pier Angelo Vendrame at 2023-06-05T19:46:15+00:00
1 changed file:
Changes:
... | ... | @@ -1176,7 +1176,7 @@ function makeBridgeId(bridgeString) { |
1176 | 1176 | }
|
1177 | 1177 | |
1178 | 1178 | function parseBridgeLine(line) {
|
1179 | - const re = /^([^\s]+\s+)?([0-9a-fA-F\.\[\]\:]+:[0-9]{1,5})\s*([0-9a-fA-F]{40})(\s+.+)?/;
|
|
1179 | + const re = /^\s*(\S+\s+)?([0-9a-fA-F\.\[\]\:]+:\d{1,5})(\s+[0-9a-fA-F]{40})?(\s+.+)?/;
|
|
1180 | 1180 | const matches = line.match(re);
|
1181 | 1181 | if (!matches) {
|
1182 | 1182 | return null;
|
... | ... | @@ -1186,7 +1186,7 @@ function parseBridgeLine(line) { |
1186 | 1186 | bridge.transport = matches[1].trim();
|
1187 | 1187 | }
|
1188 | 1188 | if (matches[3] !== undefined) {
|
1189 | - bridge.id = matches[3].toUpperCase();
|
|
1189 | + bridge.id = matches[3].trim().toUpperCase();
|
|
1190 | 1190 | }
|
1191 | 1191 | if (matches[4] !== undefined) {
|
1192 | 1192 | bridge.args = matches[4].trim();
|