Opened 10 months ago

Last modified 19 hours ago

#28763 new defect

Create Tor-Android Project

Reported by: sisbell Owned by: tbb-team
Priority: Medium Milestone:
Component: Applications/Tor Browser Version:
Severity: Normal Keywords: tbb-mobile, tbb-rbm, TorBrowserTeam201901, tbb-parity
Cc: sisbell Actual Points:
Parent ID: #28704 Points: .5
Reviewer: Sponsor:

Description

The tor-android repo contains a TorResourceInstaller. This is an Android/Java library that Orbot uses. We need this.

The tor-android repo also contains the native Tor libraries. We don't want to use these. So the Tor-Android project will need to depend on our own versions of these native libraries.

https://github.com/n8fr8/tor-android

Child Tickets

Change History (6)

comment:1 Changed 10 months ago by sisbell

The projects that tor-android is dependent on are:

  1. libevent (included patch)
  2. openssl
  3. tor
  4. zstd -https://github.com/facebook/zstd (not sure how the project is using this)
  5. lzma (not sure how the project is using this)

The first 3 we already have tor-browser-build projects for.

https://github.com/n8fr8/tor-android/tree/master/external

comment:2 in reply to:  1 Changed 10 months ago by gk

Replying to sisbell:

The projects that tor-android is dependent on are:

  1. libevent (included patch)
  2. openssl
  3. tor
  4. zstd -https://github.com/facebook/zstd (not sure how the project is using this)
  5. lzma (not sure how the project is using this)

We have the last two on our radar for desktop platforms, see #22341. But there has not been done any work to tackle that bug. As I said in that ticket starting with zstd sounds good. I am fine supporting lzma right from the beginning, too. (What about zlib support which we currently have on desktop?)

comment:3 Changed 9 months ago by gk

Keywords: TorBrowserTeam201901 added; TorBrowserTeam201812 removed

Moving tickets to Jan 2019.

comment:4 Changed 7 months ago by gk

Keywords: tbb-parity added

tbb-parity items.

comment:5 Changed 37 hours ago by sysrqb

Points: .5

comment:6 Changed 19 hours ago by eighthave

I highly recommend getting rid of all the asset unpacking code from Orbot. It is ancient and long unneeded, and indeed problematic. The libtor.so created by https://github.com/guardianproject/tor-android/pull/21 can be directly included in the TBB APKs by putting them in the right place on the file system before building. In tor-android, this is done in tor-android-binary/src/main/libs with tor-android-binary/src/main/jniLibs a symlink to that.

Then Android will automatically handle all the unpacking in a much more secure way. And it can be either loaded as a shared library without setting any paths, e.g. System.load("tor") or directly executed as a daemon from /data/data/org.torproject.torbrowser/lib/libtor.so.

If you still need to unpack other assets like torrc, geoip, etc., those should be put into the projects assets/ folder, then there is a standard Android method for getting those asset files. I think Orbot was already doing that.

Then TBB will need nothing from the https://github.com/guardianproject/tor-android project anymore.

Note: See TracTickets for help on using tickets.