@@ -41,6 +41,7 @@ Global $g_aTorVersion[0]
4141Global Const $CONFIG_INI = @ScriptDir & ' \config.ini'
4242
4343Global $g_sTorPath = IniReadWrite($CONFIG_INI , " tor" , " path" , ' Tor\tor.exe' )
44+ Global $g_sObfs4Path = IniReadWrite($CONFIG_INI , " tor" , " obfs4_path" , ' Tor\PluggableTransports\obfs4\obfs4proxy.exe' )
4445Global $g_sTorConfigFile = IniReadWrite($CONFIG_INI , " tor" , " config_file" , ' config.torrc' )
4546Global $g_sTorDataDirPath = IniReadWrite($CONFIG_INI , " tor" , " data_dir" , ' Tor Data' )
4647Global $g_sTorGeoIPv4File = IniReadWrite($CONFIG_INI , " tor" , " geoip4_file" , ' Tor\geoip' )
@@ -592,7 +593,9 @@ Func Core_GenTorrc()
592593 If $g_bTorConfig_BridgesEnabled Then
593594 FileWriteLine ($hTorrc , ' ## Bridges' )
594595 FileWriteLine ($hTorrc , ' UseBridges 1' )
595- FileWriteLine ($hTorrc , ' ClientTransportPlugin obfs2,obfs3,obfs4,scramblesuit exec Tor\PluggableTransports\obfs4\obfs4proxy' )
596+ If FileExists ($g_sObfs4Path ) Then
597+ FileWriteLine ($hTorrc , ' ClientTransportPlugin obfs2,obfs3,obfs4,scramblesuit exec ' & $g_sObfs4Path )
598+ EndIf
596599 Local $aBridges = StringSplit (StringStripCR (GUICtrlRead ($g_idBridgesEdit )), @LF )
597600 For $iBridge = 1 To $aBridges [0 ]
598601 If Not StringIsSpace ($aBridges [$iBridge ]) Then FileWriteLine ($hTorrc , ' Bridge ' & $aBridges [$iBridge ]) ; Skip blank lines
0 commit comments