[tor-bugs] #10006 [Pluggable transport]: Build an obfs-flash PT bundle

Tor Bug Tracker & Wiki blackhole at torproject.org
Thu Oct 24 04:58:04 UTC 2013


#10006: Build an obfs-flash PT bundle
-------------------------------------+-------------------
     Reporter:  dcf                  |      Owner:  dcf
         Type:  task                 |     Status:  new
     Priority:  normal               |  Milestone:
    Component:  Pluggable transport  |    Version:
   Resolution:                       |   Keywords:
Actual Points:                       |  Parent ID:  #7167
       Points:                       |
-------------------------------------+-------------------

Comment (by dcf):

 With the patch in #10017, I got the Windows build running and bootstrapped
 over obfs-flash proxies. Hooray!

 However, I am having trouble with subprocesses continuing to run after
 Vidalia and Tor stop running. I consistently see obfsproxy.exe continuing
 to run, using the configuration that is currently in the obfs-flash bundle
 branch, where Tor invokes obfs-flash-client.exe directly, without an
 intermediate batch file. One process (obfsproxy.exe) is the fewest
 surviving processes I've been able to get; with other configuration I get
 some more; see below. The extra process stops Vidalia from being launched
 a second time.

 [http://technet.microsoft.com/en-us/sysinternals/bb896653.aspx Process
 Explorer] is the tool I'm using to look at the process trees.

 === Vidalia, no batch file ===

 This is what happen with the [https://gitweb.torproject.org/pluggable-
 transports/bundle.git/commit/fbf5d5ac2c3b7f843ae83414a2e2b283292c2d05 code
 currently in the obfs-flash branch] of the bundle repo. Here is the
 process tree after Tor is fully bootstrapped and the browser window is
 open:

 [[Image(proctree-7.png)]]

 Here is the process tree after closing the browser and exiting Vidalia.
 Notice that obfsproxy.exe is unparented and now its own root. All the
 other processes disappeared.

 [[Image(proctree-8.png)]]

 If I try to relaunch Vidalia while obfsproxy.exe is still running, it
 enters a "Not Responding" state and I have to forcibly kill it. It remains
 that way until I manually kill the old obfsproxy.exe process.

 [[Image(vidalia-notresponding.png)]]

 === Vidalia with batch file ===

 Originally I had a batch file wrapper invoking obfs-flash-client.exe. That
 turned out [https://gitweb.torproject.org/pluggable-
 transports/bundle.git/commit/fbf5d5ac2c3b7f843ae83414a2e2b283292c2d05 not
 to be necessary], but it may help to see how the processes looked in that
 configuration.

 Here cmd.exe is the batch file.

 [[Image(proctree-1.png)]]

 obfs-flash-client.exe and obfsproxy.exe survive. Interestingly,
 flashproxy-client.exe was killed, even though it was also started by obfs-
 flash-client.exe.

 [[Image(proctree-2.png)]]

 This situation is presumably a little worse than when only obfsproxy.exe
 survives, because obfs-flash-client.exe will still have bound the local
 port 2334.

 I also tried a little Python wrapper instead of a batch file, and it made
 no difference.

 === Invoking obfs-flash-client.exe directly ===

 You can reproduce it without building a full bundle. Here is how I tried
 running obfs-flash-client directly from a Cygwin shell.

 {{{
 TOR_PT_STATE_LOCATION=. TOR_PT_MANAGED_TRANSPORT_VER=1
 TOR_PT_CLIENT_TRANSPORTS=obfs3_flashproxy ./App/obfs-flash-client --fp-
 arg=--facilitator=http://siteb.fp-facilitator.org/fac/ --fp-arg
 =--register-methods=http 2334 :9000
 }}}

 [[Image(proctree-5.png)]]

 This is how it looks after ctrl-C. This time obfs-flash-client.exe was
 killed, but flashproxy-client.exe survived alongside obfsproxy.exe. (They
 are now both root processes without a parent.)

 [[Image(proctree-6.png)]]

 === Invoking batch file directly ===

 Finally, here is how it is slightly different if you call the batch file
 from the shell. The batch process is killed, but obfs-flash-client.exe and
 its two descendants survive.

 {{{
 TOR_PT_STATE_LOCATION=. TOR_PT_MANAGED_TRANSPORT_VER=1
 TOR_PT_CLIENT_TRANSPORTS=obfs3_flashproxy ./App/obfs-flash-client-env.bat
 --fp-arg=--facilitator=http://siteb.fp-facilitator.org/fac/ --fp-arg
 =--register-methods=http 2334 :9000
 }}}

 [[Image(proctree-3.png)]]

 After ctrl-C:

 [[Image(proctree-4.png)]]

 ----

 Are you able to reproduce the result of obfsproxy.exe surviving using one
 of the shell commands above? Do you have any ideas why obfsproxy.exe is
 surviving and flashproxy-client.exe is being killed? Maybe as a stopgap
 workaround, we could have obfs-flash-client be more forcible about killing
 its children after the first time it gets a signal.

-- 
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/10006#comment:5>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online


More information about the tor-bugs mailing list