Skip to content

Feature: Autoupdate #275

Open

Description

@overheadhunter

If possible in a multi-platform manner, it would be nice, if the application can update itself. However there might be security considerations. To be discussed.

Activity

  1. added this to the Backlog milestone on May 26, 2016
  2. changed the title [-]Autoupdate[/-] [+]Feature: Autoupdate[/+] on Oct 7, 2016
  3. jellemdekker commented on Jul 6, 2018

    @jellemdekker
    Contributor

    I'm interested in working on this feature. What kind of implementation is preferred? I propose the following options:

    1. Instead of opening https://cryptomator.org/, the following code is expanded to open the appropriate download URL for the current operating system's latest version. Example for macOS: opening https://bintray.com/cryptomator/cryptomator/download_file?file_path=Cryptomator-1.3.2.dmg.
    2. Instead of opening browser windows, Cryptomator downloads the appropriate installation file and presents it to the user by showing the folder where it was downloaded to (opening a window in Windows Explorer, Finder, Linux file browsers, or simply linking to the file's location in a dialog box).
    3. Expanding on option 2: open the downloaded installation file and close Cryptomator, so the user can proceed with installing the latest version (might be more complex because of platform dependent code for starting an installation, also needs to account for portable installations).

    Please let me know what your thoughts are on these options and feel free to make suggestions for different approaches.

  4. overheadhunter commented on Jul 6, 2018

    @overheadhunter
    MemberAuthor

    @jellemdekker Thanks for your interest in helping us here!

    To be honest, I no longer prefer a multi-platform solution. Instead I want to get rid of the update check within the JavaFX application and would propose the following:

  5. albertopasqualetto commented on Oct 20, 2021

    @albertopasqualetto

    I think the biggest problem for now is that when I download and open the installer it doesn't just update or uninstall the previous version and then install the updated version, but first of all it asks to uninstall Cryptomator manually...

  6. infeo commented on Oct 20, 2021

    @infeo
    Member

    This is due to a change in technology (we migrated from exe installer to msi installer) and is not related to a possible auto update.

  7. albertopasqualetto commented on Oct 20, 2021

    @albertopasqualetto

    I understand👍🏻

  8. purejava commented on Sep 6, 2022

    @purejava
    Contributor

    Hi,

    I thought I'd play around with AppImageUpdate and found that everything required in this repo to enable AppImageUpdate already seems to be in place:

    ./squashfs-root/AppRun Cryptomator.AppDir cryptomator-${{ steps.versions.outputs.semVerStr }}-x86_64.AppImage
    -u 'gh-releases-zsync|cryptomator|cryptomator|latest|cryptomator-*-x86_64.AppImage.zsync'
    --sign --sign-key=615D449FE6E6A235 --sign-args="--batch --pinentry-mode loopback"

    When I update a downloaded cryptomator-1.6.12-x86_64.AppImage with AppImageUpdate, it states, that it did the update, but the AppImage is unchanged after the update. When I start it, it misses the features of 1.6.14.

    ralph@fusion Downloads % ./AppImageUpdate-x86_64.AppImage cryptomator-1.6.12-x86_64.AppImage
    AppImageUpdate version 1-alpha (commit 20a6450), build 93 built on 2022-01-24 18:35:10 UTC
    Fetching latest release information from GitHub API
    Updating from GitHub Releases via ZSync
    Fetching latest release information from GitHub API
    zsync2: Target file: /home/ralph/Downloads/cryptomator-1.6.14-x86_64.AppImage
    zsync2: Reading seed file: /home/ralph/Downloads/cryptomator-1.6.12-x86_64.AppImage
    zsync2: Usable data from seed files: 49,375158%
    zsync2: Renaming temp file
    zsync2: Fetching remaining blocks
    zsync2: Downloading from https://objects.githubusercontent.com/github-production-release-asset-2e65be/16446099/366e220d-6e46-4376-a9bb-1d7781e93d4e?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIWNJYAX4CSVEH53A%2F20220906%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20220906T161459Z&X-Amz-Expires=300&X-Amz-Signature=596a4ba8fb5663cf4bdead51bec6c45b8d98abe4da3d27911d9ffe7faa396c5f&X-Amz-SignedHeaders=host&actor_id=0&key_id=0&repo_id=16446099&response-content-disposition=attachment%3B%20filename%3Dcryptomator-1.6.14-x86_64.AppImage&response-content-type=application%2Foctet-stream
    zsync2: optimized ranges, old requests count 78, new requests count 7
    
    zsync2: Verifying downloaded file
    zsync2: checksum matches OK
    zsync2: used 27916288 local, fetched 30223552
    gpg: Schlüssel 615D449FE6E6A235: 2 Beglaubigungen wegen fehlender Schlüssel nicht geprüft
    gpg: Schlüssel 615D449FE6E6A235: Öffentlicher Schlüssel "Cryptobot <[email protected]>" importiert
    gpg: Anzahl insgesamt bearbeiteter Schlüssel: 1
    gpg:                              importiert: 1
    gpg: keine ultimativ vertrauenswürdigen Schlüssel gefunden
    gpg: Schlüssel 615D449FE6E6A235: 2 Beglaubigungen wegen fehlender Schlüssel nicht geprüft
    gpg: Schlüssel 615D449FE6E6A235: "Cryptobot <[email protected]>" nicht geändert
    gpg: Anzahl insgesamt bearbeiteter Schlüssel: 1
    gpg:                             unverändert: 1
    Signature validation passed
    ralph@fusion Downloads %

    I am a little lost now. @infeo, @overheadhunter: do your have more experience with this, e.g. if this should work already or what I am missing here?

  9. overheadhunter commented on Sep 7, 2022

    @overheadhunter
    MemberAuthor

    AppImage is unchanged after the update

    Ummm not sure how this is supposed to work... The log suggests that it does not update the original file, but rather creates a new one:

    zsync2: Target file: /home/ralph/Downloads/cryptomator-1.6.14-x86_64.AppImage
    zsync2: Reading seed file: /home/ralph/Downloads/cryptomator-1.6.12-x86_64.AppImage
    

    which is admittedly a little pointless... I guess we have to look for answers in AppImage/AppImageUpdate

  10. purejava commented on Sep 8, 2022

    @purejava
    Contributor

    Ummm not sure how this is supposed to work... The log suggests that it does not update the original file, but rather creates a new one:

    You are right.
    I looked into the C++ source code. The moment it executes a zsync2::ZSyncClient was when I decided to ask the devs on their IRC channel, instead of finding out what it does myself. 😀

    This works as designed. It creates the latest AppImage and pulls only that portion of data over the wire, that is not already contained in the referenced file / file that is forseen for the update.

    So you end up with two AppImages: the old one and the latest released one.

    From reading the AppImage docs, I was under the impression that "updating the Applmage" means, that the origin file itself is being updated, but that’s wrong.

    which is admittedly a little pointless...

    I agree. It’s less effort to download the latest AppImage right away.

  11. purejava commented on Sep 8, 2022

    @purejava
    Contributor

    I bet that means that we can rule out AppImageUpdate.

  12. overheadhunter commented on Sep 9, 2022

    @overheadhunter
    MemberAuthor

    I bet that means that we can rule out AppImageUpdate.

    Maybe not, when combined with AppImageLauncher, which integrates the update process into the context menu of the application launcher. Did you give this a try?

  13. purejava commented on Sep 9, 2022

    @purejava
    Contributor

    No, I wasn't aware of AppImageLauncher, thanks for the hint.

    Indeed, it is quite neat. You have to install AppImageLauncher. It creates an Applications directory and when you move an AppImage, that contains update information, into that directory (like Cryptomator does), you can manage the AppImage / Cryptomator seamlessly with your UI.

    You see here updating a non latest AppImage and deleting the updated AppImage afterwards:

    Bildschirmfoto 2022-09-25 um 10 46 58

    Screenshot from 2022-09-25 10-49-06
    Screenshot from 2022-09-25 10-50-12
    Screenshot from 2022-09-25 10-53-46

    EDIT: changed screenshots to English

  14. purejava commented on Nov 27, 2022

    @purejava
    Contributor

    I created Java bindings for WinSparkle with jextract and added WinSparkle to a fork of our project for testing purposes.
    The update mechanism works. You can give it a try with this MSI installer. The code is identical to Cryptomator 1.6.15, but initializes WinSparkle. Just start Cryptomator two times after each other to trigger WinSparkle.

    The Java bindings do work fine. Unfortunately it's not possible right now to use the callbacks provided by the WinSparkle.dll. The JVM crashes on using them.

  15. 14 remaining items

  16. purejava commented on Feb 5, 2023

    @purejava
    Contributor

    Regarding Linux:

    This downloads the latest Cryptmator AppImage next to the running one. So far, so good, but it refuses to start the newly downloaded AppImage from within the running one. I know, that there is the IPC check for other running instances, but it not even executes the ProcessBuilder to run the AppImage. Right now, I do not know, what's missing.

    I experimented a litte more on this one. The IPC check is not causing trouble. The code works when started from the IDE, but not when started as / from within an AppImage. The self-contained JRE makes the difference, I guess. To get this working, we'd need to find a way to launch the new AppImage, while the old one was shut down already.

  17. mraht commented on Nov 20, 2024

    @mraht

    Is this coming any time soon? Could you please push the development of this feature?

  18. purejava commented on Nov 22, 2024

    @purejava
    Contributor

    Is this coming any time soon? Could you please push the development of this feature?

    It is not a lack of interest in this feature or a low prioritization @mraht.

    If you would've bothered to read this issue, you would have noticed, that they are technical issues that couldn't be ruled out, namely, a problem to restart an updated AppImage on Linux and WinSparkle on Windows being insecure.

    Even App installer from Microsoft is considered insecure.

    Suggestions for alternative routes are welcome.

  19. mraht commented on Nov 25, 2024

    @mraht

    Hi @purejava, wouldn't it be possible to "just" determine the latest release from GitHub via HTTP request, then compare that with the current release, download the suitable executable installation file based on the OS and trigger/execute the installation - maybe even in background without or with minimum user interaction? Why focus on using AppImage or WinSparkle if it's considered insecure?

    Oh, and please don't interpret my message above as a reproach but instead as factual questions :).

  20. purejava commented on Nov 25, 2024

    @purejava
    Contributor

    Hi @purejava, wouldn't it be possible to "just" determine the latest release from GitHub via HTTP request, then compare that with the current release, download the suitable executable installation file based on the OS and trigger/execute the installation - maybe even in background without or with minimum user interaction? Why focus on using AppImage or WinSparkle if it's considered insecure?

    A request over the network to check, whether an update is available is already implemented. The app can be run as an AppImage on Linux or can bei installed via the package management system or as a Flatpak. We do not need to take care about the two latter ones.

    For Windows, you need to think of on how to handle updates, once your app does not come from the App Store. Same on Mac.

    An update - maybe in background - without or with minimum user interaction or consent is the goal.

  21. overheadhunter commented on Feb 12, 2025

    @overheadhunter
    MemberAuthor

    We discussed a new approach today: #3740

  22. purejava commented on Mar 27, 2025

    @purejava
    Contributor

    WinSparkle supports EdDSA signatures now. This previously prevented an integration into Cryptomator and makes WinSparkle an additional considerable candidate - besides #3740 - again.

  23. claell commented on Oct 31, 2026

    @claell

    Thanks for working on this. On Windows, the current update process involves several manual steps: following the update notification to the website, downloading and launching the installer, and quitting Cryptomator before installation can proceed. With frequent releases, repeating this becomes quite cumbersome.

    An in-app update action that handles the download and application shutdown would be very helpful. Is there an updated plan for Windows, whether through the external update mechanism proposed in #3740 or a built-in updater?

  24. infeo commented on Nov 1, 2026

    @infeo
    Member

    We are currently working on an Autoupdater for WIndows: cryptomator/integrations-win#164 and plan to release it with the next version 😉

  25. modified the milestones: Backlog, 1.20.0 on Nov 1, 2026
  26. removed this from the 1.20.0 milestone on Nov 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions