gumblex / ptproxy

Turn any pluggable transport for Tor into an obfuscating TCP tunnel.
MIT License
161 stars 43 forks source link

using in windows #2

Closed fudingyu closed 9 years ago

fudingyu commented 9 years ago

Hey guys thx your share code

I'm using your code running windows.

Setp1 Download tor and enter xxx\Tor Browser\Browser\TorBrowser\Tor\PluggableTransports Copy obfs4proxy.exe to ptproxy currently directory.

Setp2 change ptproxy code to "ptexec": "./obfs4proxy.exe

Work it!

gumblex commented 9 years ago

So what's the point of this issue?

EkkoG commented 8 years ago

What does Step2 mean? Modify the file's extension name?

gumblex commented 8 years ago

Change "ptexec" in config file.

EkkoG commented 8 years ago

I haven't change config file, but it run successfuly...

EkkoG commented 8 years ago

Now,I'm looking for a method to run this python script as a daemon.

gumblex commented 8 years ago

use pythonw.exe on Windows

EkkoG commented 8 years ago

pythonw ptproxy.py local.json like this?

EkkoG commented 8 years ago

I get it,but after use pythonw,there is no longer a cmd windows with python script running,but there is a obfs4proxy.exe windows like this...and it can't be closed,if click the 'close' button,there will be another window appear... image

gumblex commented 8 years ago

Try the new commit, it should hide the obfs4 console now.

EkkoG commented 8 years ago

On window 10 system,it run well,but on windows7,if run ptproxy.py with python the obfs4proxy.exe be awakened,and all is well,but if run with pythonw, the obfs4proxy.exe can't be awakened,only ptproxy.py running.I will install another virtual system to test it.

EkkoG commented 8 years ago

I just install a new windows7 Virtual Machine,run ptproxy.py with pythonw, obfs4proxy.exe does not be awakened,but python does.

gumblex commented 8 years ago

What does 'awaken' mean? Is obfs4 not running or not showing the black window? Try open a console and run pythonw.exe ptproxy.py yourconfig.json > log.txt and paste the log.

EkkoG commented 8 years ago

Sorry for my poor English...in normal state,after run pythonw ptproxy.py local.json the obfs4proxy.exe should be open,but on windows7 there only have a python progress runing. image

but if run with python not pythonw,there will have a obfs4proxy.exe progress. image

gumblex commented 8 years ago

Try the new commit, it should be fixed.

EkkoG commented 8 years ago

OK,it works.Thank you!

didila commented 8 years ago

我在Debian Server端设置iat-mode=1 可是运行后的Server information却显示iat-mode=0 然后我将运行的Server information整段复制到client 接着在Windows client端iat-mode无论设置1或0在obfs4proxy.log都出现handshake failed: handshake: MAC mismatch: Dervied......的信息 我的问题是 1.iat-mode的设置1或0有关系吗?为什么Debian Server端原本设置iat-mode=1运行后Server information显示iat-mode=0? 2.握手失败是iat-mode的关系还是哪边设置错误?我很确定将server端运行后的Server information完整复制贴上 Traceback (most recent call last): File "D:\Python35-32\lib\socketserver.py", line 628, in process_request_threadself.finish_request(request, client_address) File "D:\Python35-32\lib\socketserver.py", line 357, in finish_requestself.RequestHandlerClass(request, client_address, self) File "D:\Python35-32\lib\socketserver.py", line 684, in initself.handle() File "ptproxy.py", line 82, in handlerl, wl, xl = select.select([self.request, ptsock], [], [], 300) ValueError: file descriptor cannot be a negative integer (-1)

2015/09/29 07:06:43 [NOTICE]: obfs4proxy-0.0.5 - launched 2015/09/29 07:06:58 [ERROR]: obfs4([scrubbed]:7788) - handshake failed: handshake: MAC mismatch: Dervied: db555cdfdad3e2dc552bbf4947ac995f Received: f130234869573eb66619afd6cb83538a.

gumblex commented 8 years ago
  1. iat-mode 是混淆发包时间特征,1 和 2 对速度有影响。你需要在服务端 obfs4_state.json 里改。
  2. 试试改了之后再从服务端复制一遍。"server" 的 IP 要用服务端的 IP。

InvalidMacError is the error returned when the handshake MACs do not match. This error is fatal and the connection MUST be dropped.