[tor-bugs] #29080 [Applications/Tor Browser]: Merge OrbotService and TOPL

Tor Bug Tracker & Wiki blackhole at torproject.org
Tue Mar 19 19:10:19 UTC 2019


#29080: Merge OrbotService and TOPL
-------------------------------------------------+-------------------------
 Reporter:  sisbell                              |          Owner:  tbb-
                                                 |  team
     Type:  defect                               |         Status:
                                                 |  needs_review
 Priority:  Medium                               |      Milestone:
Component:  Applications/Tor Browser             |        Version:
 Severity:  Normal                               |     Resolution:
 Keywords:  tbb-mobile, TBA-a3,                  |  Actual Points:
  TorBrowserTeam201903R, tbb-8.5                 |
Parent ID:  #27609                               |         Points:
 Reviewer:                                       |        Sponsor:
-------------------------------------------------+-------------------------

Comment (by sisbell):

 Replying to [comment:24 eighthave]:
 > One small but important thing to do with this merging is to make
 TorService be an actual Android `Service`.  That will help with the
 lifecycle issues a lot, and is the official Android interface for doing
 something like a UNIX daemon.  I did some quick prototyping, this
 basically means writing a thin Java and JNI shim layer where the Java code
 defines the subclass of `android.app.Service` and the JNI layer maps the
 tor daemon start/stop to the Java class.
 I think this work wouldn't be done in TorService directly. It would be
 done in

 https://github.com/thaliproject/Tor_Onion_Proxy_Library

 The AndroidOnionProxyManager (extends OnionProxyManager) would be where
 the control of Tor is done. It manages the lifecycle events of the tor
 process. Stop is handled through the control connection, while start does
 all of the exec commands that we want to eliminate. So you can just fork
 TOPL and submit a PR. If there are any changes that need to bubble up, we
 can make those in TorService (tor-android-service)

 We have to do something like this for Android Q anyway, since running
 daemons is now fully blocked:
 > *
 https://www.reddit.com/r/androiddev/comments/b2inbu/psa_android_q_blocks_executing_binaries_in_your/
 > * https://android-
 review.googlesource.com/c/platform/system/sepolicy/+/804149
 >
 It looks like this would also hit tor-android-binary dependency that we
 are using.

 > I have some cycles allocated from Guardian Project to work on this kind
 of thing, so I'm wondering how best to integrate into sisbell's work.

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


More information about the tor-bugs mailing list