flathub / com.brave.Browser

https://flathub.org/apps/details/com.brave.Browser
Mozilla Public License 2.0
41 stars 17 forks source link

Tor bridges are still broken #577

Closed hogsmead closed 4 months ago

hogsmead commented 4 months ago

I reported this problem last year (https://github.com/flathub/com.brave.Browser/issues/352) but the person who closed the issue doesn't have this problem apparently. I've noticed that Brave has verified badge on Flathub now, so I ask you to take a look at this issue again because the bridges are still broken for me. When I try to connect to Tor, Brave spams this into the console:

Apr 19 09:34:43.000 [warn] Managed proxy "../../apfggiafobakjahnkchiecbomjgigkkn/1.0.3/tor-obfs4-brave" process terminated with status code 31
Apr 19 09:34:43.000 [err] tor_assertion_failed_(): Bug: src/feature/client/transports.c:519: proxy_prepare_for_restart: Assertion mp->conf_state == PT_PROTO_COMPLETED failed; aborting. (on Tor 0.4.8.10 )
Apr 19 09:34:43.000 [err] Bug: Tor 0.4.8.10: Assertion mp->conf_state == PT_PROTO_COMPLETED failed in proxy_prepare_for_restart at src/feature/client/transports.c:519: . Stack trace: (on Tor 0.4.8.10 )
Apr 19 09:34:43.000 [err] Bug:     [0x4784bb] (on Tor 0.4.8.10 )
Apr 19 09:34:43.000 [err] Bug:     [0x48355c] (on Tor 0.4.8.10 )
Apr 19 09:34:43.000 [err] Bug:     [0x455c42] (on Tor 0.4.8.10 )
Apr 19 09:34:43.000 [err] Bug:     [0x45692b] (on Tor 0.4.8.10 )
Apr 19 09:34:43.000 [err] Bug:     [0x48d4df] (on Tor 0.4.8.10 )
Apr 19 09:34:43.000 [err] Bug:     [0x48ef07] (on Tor 0.4.8.10 )
Apr 19 09:34:43.000 [err] Bug:     [0x5d172a] (on Tor 0.4.8.10 )
Apr 19 09:34:43.000 [err] Bug:     [0x5d1fe7] (on Tor 0.4.8.10 )
Apr 19 09:34:43.000 [err] Bug:     [0x409ee3] (on Tor 0.4.8.10 )
Apr 19 09:34:43.000 [err] Bug:     [0x405245] (on Tor 0.4.8.10 )
Apr 19 09:34:43.000 [err] Bug:     [0x4032fd] (on Tor 0.4.8.10 )
Apr 19 09:34:43.000 [err] Bug:     [0x402dfd] (on Tor 0.4.8.10 )
Apr 19 09:34:43.000 [err] Bug:     [0x899d2a] (on Tor 0.4.8.10 )
Apr 19 09:34:43.000 [err] Bug:     [0x89b5c7] (on Tor 0.4.8.10 )
Apr 19 09:34:43.000 [err] Bug:     [0x402ec5] (on Tor 0.4.8.10 )

Please don't recommend me to use a different browser this time. Thanks.

mihaiplesa commented 4 months ago

@fmarier would you know more about this?

fmarier commented 4 months ago

It's hitting an assertion in the tor daemon: https://gitlab.torproject.org/tpo/core/tor/-/blob/main/src/feature/client/transports.c?ref_type=heads#L519

which suggests that the proxy (i.e. bridge) wasn't configured properly. Maybe we lack some permissions in the Flatpak.

Does Tor without a bridge actually work?

rany2 commented 4 months ago

@fmarier The cause is actually straightforward, Flatpak prevents 32-bit binaries from running which the obfs4proxy you're distributing is. If you distribute a 64-bit obfs4proxy binary it will work. There is no reason that Brave is shipping a 32-bit binary in the first place IMO.

Most likely when I closed the issue last time, I was on an older flatpak version which didn't have this restriction.

fmarier commented 4 months ago

Thanks @rany2. We'll test the 64-bit binaries out and update our build pipeline.

fmarier commented 4 months ago

We are now building and shipping 64-bit binaries for the bridges.

rany2 commented 4 months ago

When would be the right time to drop multiarch support then? Does the update propagate immediately?

fmarier commented 4 months ago

I think these components are generally updated once a day. So we could probably drop multiarch support tomorrow (or the day after to be extra-careful).