Bug #9146
Remove workaround for localized Tor Browser search plugins
100%
Description
(The workaround (enable_localized_searchplugins()
, in /usr/loca/bin/tor-browser
was added for Bug #8036.)
Some background: we install the Tor Browser to /usr/local/lib/tor-browser
($TB_INSTALL
from now on) and start it with /usr/loca/bin/tor-browser
(it sources /usr/local/lib/tails-shell-library/tor-browser.sh
which is key in how we use Tor Browser’s firefox
binary). In $TB_INSTALL/distribution/searchplugins/locale
we add some localized search plugins, namely those from Debian’s iceweasel localization packages).
However, the localized search plugins are not used (if the enable_localized_searchplugins()
workaround is disabled). E.g. LANG=de_DE.UTF-8 tor-browser
results in a Tor Browser with the search plugins from $TB_INSTALL/browser/searchplugins
(i.e. Tor Browser’s default) only.
If I install strace
(and echo 0 > /proc/sys/kernel/yama/ptrace_scope
to make it available for non-root users) and run LANG=de_DE.UTF-8 strace tor-browser
I can see that it access
:es $TB_INSTALL/distribution/searchplugins/locale/de
successfully, but that’s it, it doesn’t use the contents. I got the idea that $TB_INSTALL/browser/searchplugins
perhaps overrides the usage of $TB_INSTALL/distribution/searchplugins
, so I moved them into $TB_INSTALL/distribution/searchplugins/common
, but that gives the same result again. Removing both results in no search plugins.
So, how can we make our Tor Browser use our localized search plugins without the ugly enable_localized_searchplugins()
workaround?
Subtasks
Related issues
Related to Tails - |
Resolved | 2014-10-09 |
History
#1 Updated by anonym 2015-04-01 14:27:13
- related to
Bug #8036: Localized search plugins are not used by the Tor Browser added
#2 Updated by anonym 2015-04-01 14:32:19
Asked the tbb-dev@ for help: https://lists.torproject.org/pipermail/tbb-dev/2015-April/000252.html
#3 Updated by intrigeri 2015-05-09 04:17:09
I guess this is still relevant even after Bug #9309 is resolved, right? Perhaps the ticket description will need an update, then.
#4 Updated by anonym 2015-05-09 14:24:32
intrigeri wrote:
> I guess this is still relevant even after Bug #9309 is resolved, right?
Yes.
> Perhaps the ticket description will need an update, then.
Nothing really changes. The search plugins are still in the old directories, and are not automatically used. Nothing has changed.
#5 Updated by anonym 2015-05-14 13:40:45
- Target version changed from Tails_1.4 to Tails_1.4.1
Delaying again.
#6 Updated by anonym 2015-07-01 11:54:38
- Target version changed from Tails_1.4.1 to Tails_1.5
#7 Updated by anonym 2015-08-03 11:01:23
- Target version changed from Tails_1.5 to Tails_1.6
#8 Updated by anonym 2015-09-08 10:07:46
- Status changed from Confirmed to In Progress
Applied in changeset commit:aff37533fcbc6a6efb8094a6ef8ba09e21242d84.
#9 Updated by anonym 2015-09-08 10:09:32
- Assignee deleted (
anonym) - % Done changed from 0 to 50
- QA Check set to Ready for QA
- Feature Branch set to bugfix/9146-remove-localized-search-plugin-workaround
Woo, this seems to have fixed itself.
I tested my fix by running this, and making sure that the expected Wikipedia plugin was present for each locale:
cp -a .tor-browser .tor-browser.orig
LANGS="ar_EG.utf8 de_DE.utf8 es_ES.utf8 en_US.utf8 fa_IR fr_FR.utf8
it_IT.utf8 ko_KR.utf8 nl_NL.utf8 pl_PL.utf8 pt_PT.utf8
ru_RU.utf8 tr_TR.utf8 vi_VN zh_CN.utf8"
for lang in $LANGS; do
echo
echo "Testing locale: $lang"
rm -r .tor-browser && \
cp -a .tor-browser.orig/ .tor-browser && \
LANG=$lang tor-browser
done
#11 Updated by intrigeri 2015-09-17 02:50:44
Code review passes, building.
#12 Updated by intrigeri 2015-09-17 12:20:18
- Status changed from In Progress to Fix committed
- % Done changed from 50 to 100
Applied in changeset commit:f589800b174f5f23854739d26d8ee2026b81e129.
#13 Updated by intrigeri 2015-09-17 12:21:30
- Assignee deleted (
intrigeri) - QA Check changed from Ready for QA to Pass
Not 100% convinced that it is worth the risk in a stabilization release, but I trust anonym’s testing + mine + the code makes sense and is nicer :)
#14 Updated by bertagaz 2015-09-22 15:09:48
- Status changed from Fix committed to Resolved
- QA Check deleted (
Pass)