Skip to content

Handle failing to apply tor settings

On desktop if you edit your bridges to include the broken bridge line 0:0 the settings will fail to be passed on to the tor process.

Moreover, the application is all-or-nothing, which means that if you subsequently change a different tor setting, like your firewall, the new settings will not be passed on either.

We could try and ensure that all settings are verified before being passed on to tor. E.g. #41913 (moved). However, I'm not sure we can 100% guarantee tor will accept it.

Therefore, we would likely still need a fallback to give feedback to users that their settings have failed to apply, on both android and desktop. Some notification like "Your Tor connection settings could not be applied. Please verify them." Maybe with the technical error from tor, but I'm not sure how useful that would be.

Note for UX team: since this occurs after applying the settings, the notification could only be shown after the setting has been saved. E.g. for the bridge dialogs (likely only needed for the user provided bridge dialog), we could only show an error message after the user presses the final "OK" or "Connect". In principle we could hold the bridge dialog open whilst we show the warning, but it would likely give the false impression that the settings were not saved, i.e. that the user could "Cancel" to reverse the problematic change. Therefore, I imagine it would make more sense to have the bridge dialog close and then show the warning. It wouldn't be a nice experience, but that is probably why we want better pre-verification as in #41913 (moved).

@donuts @felicia. Feel free to assign to yourself if you want to spend time on this.

Regardless of the above, we should probably make the application of the bridge, proxy and firewall settings independent, rather than all-or-nothing. I could make this change in a separate issue if UX needs time to work on this.

@pierov do you know if tor provides a way to verify settings before applying them?

@pierov is it ok to make separate calls to setConf to the instance?

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information