Page MenuHomeSolus

Update protonmail-bridge to 1.6.9
ClosedPublic

Authored by FriesischScott on Mar 4 2021, 5:52 PM.
Tags
None
Referenced Files
F11016049: D10644.id25694.diff
Sat, Aug 5, 4:17 PM
F11004963: D10644.diff
Tue, Aug 1, 4:38 AM
F10985163: D10644.id.diff
Sun, Jul 23, 8:33 PM
F10895970: D10644.diff
Jul 1 2023, 8:44 PM
F10846099: D10644.id25694.diff
Jun 11 2023, 3:36 AM
F10844934: D10644.id25695.diff
Jun 10 2023, 10:30 PM
F10844289: D10644.id26419.diff
Jun 10 2023, 8:34 PM
F10842454: D10644.id25639.diff
Jun 10 2023, 12:16 PM

Details

Summary

Summarized changelog:

  • 1.6.9
    • Revise storage locations for the config files, preferences and cache
    • Improved parsing of embedded messages
    • GUI bug fixes
  • 1.6.6
    • Allow to choose which keychain is used by Bridge on Linux
    • Improved performance during slow connection
    • Added IMAP requests to the logs for easier debugging

Full changelog: https://protonmail.com/download/bridge/stable_releases.html

Test Plan

Synced and sent mail through Thunderbird.

Diff Detail

Repository
R5138 protonmail-bridge
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

By any chance are you modifying the spacing by hand or have an outdated common?

I think I accidentally had format on save active in vscode. Do you want me to revert the whitespace changes?

Update formatting of package.yml

I aligned the formatting with the other repos. Hopefully, I got it right.

Actually commit the whole file this time...

In the package.yml file, you have to fix the description too, from:

description: ProtonMail Bridge enable...

to:

description: |
    ProtonMail Bridge enable...

Fix formatting for description

I found out that the ProtonMail Bridge application includes a launcher that allows it to update itself. From the ReadMe:

Official distributions of the ProtonMail Bridge and Import-Export apps contain both a launcher and the app itself. The launcher is installed in a protected area of the system (i.e. an area accessible only with admin privileges) and is used to run the app. The launcher ensures that nobody tampered with the app's files by verifying their signature using a hardcoded public key. App files are placed in regular userspace and are signed by Proton's private key. This feature enables the app to securely update itself automatically without asking the user for a password.

I tested building the launcher and it works perfectly. I installed an older version of the app and it prompted me for an update. After a restart it loaded the up-to-date application from my home directory. I would love to include this launcher in Solus if you agree. However, I am not entirely sure how to call the two resulting binaries. Currently I have:

  • protonmail-bridge: The launcher and basically the only application the user needs to know about. This is also the current name of the binary.
  • proton-bridge: The actual application with the default name from the build.

Any thoughts? It would be great if we can include this as updates can sometimes take a while (this one has been in progress since March 4th) and this would also allow for urgent fixes by ProtonMail to be deployed to the users on short notice.

Obviously I would still regularly update the package.

DataDrake added a subscriber: DataDrake.

If I understand this correctly, we only need to ship the launcher, not the app. The launcher will download the app (presumably in the user's homedir) on its own, facilitating its auto-update and verification process. Normally, we would try to disable the automatic updater, but the signing process won't allow us to do it that way.

This revision now requires changes to proceed.Apr 23 2021, 1:15 PM

The launcher (https://github.com/ProtonMail/proton-bridge/blob/master/cmd/launcher/main.go) only runs either the system wide install or a newer version from the user's home directory if present. The downloading is done by the app itself. Building only the launcher leads to:

time="Apr 23 16:19:42.932" level=fatal msg="Failed to find any launchable executable" error="no executable found"

Edit: I thought I had it working loading the prebuilt binary but now it doesn't. I'll have another look.

While I figure out the launcher business I think we should still push the latest stable release 1.6.9.

FriesischScott retitled this revision from Update protonmail-bridge to 1.6.6 to Update protonmail-bridge to 1.6.9.Apr 29 2021, 5:32 PM
FriesischScott edited the summary of this revision. (Show Details)

I got the launcher working. The least hacky approach would be as I proposed before. Have the launcher as protonmail-bridge the binary that everyone uses (and the current name so nothing changes for users not relying on the desktop file) and proton-bridge as the default app that we ship. This way I don't have to patch any make or desktop files.

I tried updating to a pre-release using the launcher and it works flawlessly. If you agree I can include the launcher in the 1.6.9 release.

This revision is now accepted and ready to land.May 14 2021, 1:38 PM