[tor-bugs] #13788 [Tor Browser]: Meek bridges don't work in TB 4.5alpha1

Tor Bug Tracker & Wiki blackhole at torproject.org
Mon Nov 24 23:39:36 UTC 2014


#13788: Meek bridges don't work in TB 4.5alpha1
-----------------------------+----------------------
     Reporter:  cypherpunks  |      Owner:  tbb-team
         Type:  defect       |     Status:  new
     Priority:  normal       |  Milestone:
    Component:  Tor Browser  |    Version:
   Resolution:               |   Keywords:  meek
Actual Points:               |  Parent ID:
       Points:               |
-----------------------------+----------------------

Comment (by dcf):

 Here are the essential debugging patches.

 This one makes the headless browser not headless, so you can Ctrl+J and
 view the Browser Console. To apply it, you need to first unzip the xpi.
 {{{
 cd Browser/TorBrowser/Data/Browser/profile.meek-http-helper/extensions
 mkdir meek-http-helper at bamsoftware.com
 cd meek-http-helper at bamsoftware.com
 unzip ../meek-http-helper at bamsoftware.com.xpi
 rm ../meek-http-helper at bamsoftware.com
 # Now edit meek-http-helper at bamsoftware.com/components/main.js.
 }}}
 {{{
 --- a/components/main.js
 +++ b/components/main.js
 @@ -83,13 +83,17 @@ MeekHTTPHelper.prototype = {

              // Block forever.
              // https://developer.mozilla.org/en-US/Add-
 ons/Code_snippets/Threads#Waiting_for_a_background_task_to_complete
 +            /*
              var thread = Components.classes["@mozilla.org/thread-
 manager;1"].getService().currentThread;
              while (true)
                  thread.processNextEvent(true);
 +            */
          } finally {
 +            /*
              var app = Components.classes["@mozilla.org/toolkit/app-
 startup;1"]
                  .getService(Components.interfaces.nsIAppStartup);
              app.quit(app.eForceQuit);
 +            */
          }
      },
 }}}

 Unfortunately I don't know of a way to view the browser dump messages out
 of the box, but you can do it by patching meek-client-torbrowser to log
 those messages. You also have to enable logging by adding the --log option
 to the ClientTransportPlugin line (note meek-client-torbrowser and meek-
 client have separate logs). The log will be written to Browser/meek-
 client-torbrowser.log.
 {{{
 ClientTransportPlugin meek exec ./TorBrowser/Tor/PluggableTransports/meek-
 client-torbrowser --log meek-client-torbrowser.log --
 ./TorBrowser/Tor/PluggableTransports/meek-client
 }}}
 {{{
 --- a/meek-client-torbrowser/meek-client-torbrowser.go
 +++ b/meek-client-torbrowser/meek-client-torbrowser.go
 @@ -102,6 +102,7 @@ func grepHelperAddr(r io.Reader) (string, error) {
         scanner := bufio.NewScanner(r)
         for scanner.Scan() {
                 line := scanner.Text()
 +               log.Print(line)
                 if m := helperAddrPattern.FindStringSubmatch(line); m !=
 nil {
                         helperAddr = m[1]
                         break
 @@ -116,7 +117,12 @@ func grepHelperAddr(r io.Reader) (string, error) {
                 return "", io.EOF
         }
         // Keep reading from the browser to avoid its output buffer
 filling.
 -       go io.Copy(ioutil.Discard, r)
 +       go func() {
 +               for scanner.Scan() {
 +                       line := scanner.Text()
 +                       log.Print(line)
 +               }
 +       }()
         return helperAddr, nil
  }
 }}}
 I usually just symlink Browser/TorBrowser/Tor/PluggableTransports/meek-
 client-torbrowser to my development build of meek-client-torbrowser when
 I'm testing something like this. To build meek-client-torbrowser,
 {{{
 export GOPATH=~/go
 cd meek/meek-client-torbrowser
 go build
 }}}
 There are also some commented log.Printf calls in meek-client itself that
 log when it tries to make a request. However I think the error happening
 somewhere inside Firefox; none of the meek code changed since 4.0.

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


More information about the tor-bugs mailing list