[tor-bugs] #31650 [Applications]: pre-crunch and pre-strip PNG in tor-service-android to make it reproducible

Tor Bug Tracker & Wiki blackhole at torproject.org
Thu Sep 5 14:17:39 UTC 2019


#31650: pre-crunch and pre-strip PNG in tor-service-android to make it reproducible
-------------------------+------------------------------
 Reporter:  eighthave    |          Owner:  (none)
     Type:  enhancement  |         Status:  new
 Priority:  Medium       |      Component:  Applications
  Version:               |       Severity:  Normal
 Keywords:  tbb-mobile   |  Actual Points:
Parent ID:  #31042       |         Points:
 Reviewer:               |        Sponsor:
-------------------------+------------------------------
 PNG crunching is not a deterministic process, especially the way aapt does
 it.  This makes the builds not reproducible.  The easy solution to this is
 to pre-crunch the PNGs and commit them to git.  This also uses exiftool to
 strip any metadata from the PNG.  This then disables running the crunch as
 part of the gradle build process.

 https://medium.com/@duhroach/smaller-pngs-and-android-s-aapt-tool-
 4ce38a24019d

 I have submitted this upstream to Orbot:
 https://github.com/guardianproject/orbot/pull/252

 And it is here in my tor-android-service-fork:
 https://gitlab.com/eighthave/tor-android-service/commits/png-pre-compress

 Once it is merged, someone will need to do:
 {{{
 $ sudo apt install exiftool zopfli
 $ cd /path/to/tor-android-service
 $ ./tools/png-pre-compress
 }}}

 Then commit all the changed PNGs.

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


More information about the tor-bugs mailing list