diff --git a/extensions/chromium/runet-censorship-bypass/src/extension-common/35-pac-kitchen-api.js b/extensions/chromium/runet-censorship-bypass/src/extension-common/35-pac-kitchen-api.js index 2ee7f23..95138d6 100644 --- a/extensions/chromium/runet-censorship-bypass/src/extension-common/35-pac-kitchen-api.js +++ b/extensions/chromium/runet-censorship-bypass/src/extension-common/35-pac-kitchen-api.js @@ -174,7 +174,8 @@ } } if (self.ifUseLocalTor) { - customProxyArray.push('SOCKS5 localhost:9050', 'SOCKS5 localhost:9150'); + self.torPoints = ['SOCKS5 localhost:9150', 'SOCKS5 localhost:9050']; + customProxyArray.push(...self.torPoints); } self.filteredCustomsString = ''; @@ -248,6 +249,16 @@ /******/ return "DIRECT"; /******/ } /******/ +/******/ `; + } + if (pacMods.ifUseLocalTor) { + + res += ` +/******/ +/******/ if (host.endsWith(".onion")) { +/******/ return "${pacMods.torPoints.join('; ')}"; +/******/ } +/******/ /******/ `; } res += `