Commit Graph
201 Commits
Author SHA1 Message Date
Kenneth Skovhede 5a4fcaa6d7 Added tool to work with remote sources 2025-02-21 11:51:45 +01:00
Kenneth Skovhede 0260a061bb Made the synctool an executable 2025-02-10 21:37:52 +01:00
Kenneth Skovhede f0f79418d8 Fixed logic so the permissions are always applied, unless the user specifically opts out by placing a file named insecure-permissions.txt in the data folder. 2025-02-06 17:09:18 +01:00
Kenneth Skovhede 1af6e2b1d6 Experiment with CommonProgramData on Windows in favor of users folder. 2025-02-06 16:57:44 +01:00
Kenneth Skovhede aab91eb0df Added protection to newly create data folder and databases 2025-02-06 16:56:06 +01:00
Kenneth Skovhede de00eee3de Changed logic so overrides to server-datafolder will affect any operation, including CLI, Agent, and ServerUtil 2025-01-28 13:23:57 +01:00
Kenneth Skovhede fac12ba772 Further consolidated the data folder.
Added support for `--portable-mode` and `--server-datafolder` for the CLI, ServerUtil, and Agent.

Fixed a few places where file reads were not cached properly.

Moved some responsibilities of UpdaterManager into DataFolderManager.

This now supports storing `machineid.txt` and `installation.txt` inside the path pointed to by `--server-datafolder` or alternatively with `--portable-mode`.

It is possible that some fringe backwards compatibility is lost with this update.

Fixed an issue with AutoUpdater crashing on check/download.

This fixes #5902
2025-01-28 13:01:35 +01:00
Kenneth SkovhedeandGitHub 039e1a08fb Merge branch 'master' into feature/prevent-windows-subfolder-storage 2025-01-28 08:58:26 +01:00
Kenneth SkovhedeandGitHub 610f3b47d1 Update reporting module (#5910)
* Updated reporting values.

The reporter module can now emit the following extra values:
- operating-system
- installation-type
- destination-type
- next-scheduled-run

When running from the built-in scheduler, it will automatically set `--next-scheduled-run` so it is applied to the reporting data.

* Implemented an improved machine name reader.
This fixes #5907

* Added a guard against sending too much of the destination url as the destination.

* Fixed reading Windows Machine name

* Removed extra Windows logic as it has no effect
2025-01-28 08:56:42 +01:00
Kenneth Skovhede 27f0bb4ea0 Unified code to find the data folder.
The `machineid.txt` and `installation.txt` files are now default located in same folder where the database is default located.
2025-01-27 22:51:45 +01:00
Kenneth SkovhedeandGitHub 997891525a Updated license-updater to update csproj files (#5898)
* Updated license-updater to update csproj files

* License updates
2025-01-22 21:04:19 +01:00
Kenneth SkovhedeandGitHub 6bbd64a655 Fixed nullability warnings in Utility.cs (#5861)
* Fixed nullability warnings in `Utility.cs`

* Fixed a number of nullability issues and warnings

* More nullable fixes

* Fixed the overwrite issue

* Fixed additional nullability issues

* Removed additional nullability issues

* More nullability fixes and added some xmldoc

* Added more xmldocs and removed an unused argument

* Removed more warnings
2025-01-14 14:03:48 +01:00
Kenneth SkovhedeandGitHub 9464caf622 Feature/update license 2025 (#5851)
* Fixed some minor whitespace issues

* Updated all copyright to 2025
2025-01-07 09:40:39 +01:00
Kenneth Skovhede b610e412d7 Updated preload probing logic.
This updates the logic to not emit any console messags unless the environment variable `DUPLICATI_PRELOAD_SETTINGS_DEBUG=1` is set.
This changes the paths used on MacOS to not use the `/usr/share/Duplicati` folder which is write procted, but rather the `/usr/share/local/Duplicati`.

Added the `/usr/share/local/Duplicati` path for Linux as well.

Added detection for portable mode and only using relative/specific paths for preload in portable mode.

Added support for also probing `%LOCALAPPDATA% folder, which is where other settings are loaded, to allow "all settings in one place". Note that it is possible to use the preload to choose a different folder for anything but the `preload.json` file.

Added an option for specifying `DUPLICATI_PRELOAD_SETTINGS=!<path to file>`, where the leading `!` signifies that **only** that file is loaded and all other locations are ignored.
2024-12-13 11:07:40 +01:00
Kenneth Skovhede 42c4e50482 Fixed issues with update detection.
This fixes a case where the update checker keeps an old reference to the previous updated version, despite running a newer version.

It also removes some use of `Assembly.GetExecutingAssembly().GetName().Version` with the information from `UpdaterManager.SelfVersion.Version` as that should follow the update info.

This fixes #5698
This fixes #5252
2024-11-25 17:27:50 +01:00
Kenneth Skovhede 3bac3dbae3 Added package type ids when sending usage reports to track individual package type usage.
Added package type id to download checker header for future use.
2024-11-09 23:00:20 +01:00
Kenneth Skovhede 4b84135622 Merge remote-tracking branch 'origin/master' into feature/add-secret-provider 2024-10-24 16:11:41 +02:00
Kenneth Skovhede 34d13a20e2 Initial version of the external secret provider 2024-10-24 16:06:59 +02:00
Kenneth Skovhede f251d34b57 Implemented support for including the machine hostname in reports for simpler identification. 2024-10-16 16:22:47 +02:00
Kenneth Skovhede ef0ca64d52 Merge remote-tracking branch 'origin/master' into feature/remote-control-support 2024-10-03 14:49:07 +02:00
Kenneth Skovhede 669e90704d Initial work on supporting a secure remote control connection. 2024-09-18 11:07:59 +02:00
Kenneth Skovhede f3e2a0a902 Avoid setting Thread.CurrentCulture
Avoids setting deprecated `Thread.CurrentCulture` and `Thread.CurrentUICulture`, using `CultureInfo.CurrentCulture` instead.
Fixed a few legacy places where incorrect string compares were used.
2024-09-18 09:24:55 +02:00
Marcelo Ceccon 331960a3c5 Timeout corrections for Updatemanager & Report Uploader 2024-09-06 17:02:04 +02:00
Marcelo Ceccon c7c46aed7d Replacing deprecated WebClient for HttpClient
This is a proposal for replacing the deprecated WebClient with the HttpClient.

This commit implements the core functionality following the HttpClientFactory pattern as suggested by the framework. It also supports an alternative approach in areas where the HttpClient pattern is not desirable.

The first backend component to be migrated is WebDav, and the HttpClient pattern is also applied to the update downloader.

Once merged, other backend components can be migrated, eventually removing the deprecated WebClient from the codebase.

Additionally, the debug-profind-file option from webdav, which was a remnant from early development, is removed as it is no longer useful for debugging different webdav server responses.
2024-09-06 10:46:46 +02:00
Kenneth Skovhede 71053c6b94 Improved debugging support for preload 2024-08-28 09:45:37 +02:00
Kenneth Skovhede 3548475360 Implemented preload support.
This commit adds the option to provide preload/preset options that change the default values for Duplicati's commandline or environment variables.
This fixes #5480
2024-08-28 00:18:55 +02:00
Kenneth Skovhede 4f332ea075 Added the missing duplicati-service binary 2024-08-28 00:15:53 +02:00
Kenneth Skovhede 735b4020eb Implemented duplicati-server-util for sending various commands to a running server.
This tool replaces `ConfigurationImporter` and partially replaces `duplicati_client`.
This fixes #5474
2024-08-26 20:00:13 +02:00
Grzegorz Łagocki 9b19bac7da Add Copyright Property to *.csproj files 2024-07-09 00:37:18 +02:00
Jojo-1000 917e2cd0c4 Remove obsolete custom platform detection. 2024-05-30 02:14:05 +02:00
Kenneth Skovhede 95b040d386 Added ConfigurationImporter to the package helper 2024-05-21 12:09:05 +02:00
Kenneth Skovhede afc34e00be Merge remote-tracking branch 'origin/master' into feature/add-missing-executables 2024-05-21 12:08:14 +02:00
Kenneth Skovhede 84d7a56ab1 Added executables for SharpAESCrypt and Snapshots 2024-05-21 09:54:01 +02:00
Kenneth Skovhede 05e5fbcf80 Fixed issue with recovery-tool help.
Cleaned up some loading of embedded resourse to rely on type instead of assembly name.
Implemented installed executable name instead of using Windows executable names.
2024-05-21 08:26:40 +02:00
Kenneth Skovhede 6caa01f051 Micro fixes to release builder logic.
Added example manifest
Fixed not signing pkg files if disabled
2024-05-06 09:43:51 +02:00
Kenneth Skovhede b8f9a634e3 Fixed issues with checking signed manifest 2024-05-04 08:01:01 +02:00
Kenneth Skovhede 0e60bf4ca5 Fixed crash in autoupdater help text 2024-05-04 07:34:45 +02:00
Kenneth Skovhede ebd34c853e Safguard against reading older update config 2024-05-04 07:26:54 +02:00
Kenneth Skovhede fa73849783 Rename part 2 2024-04-29 21:43:28 +02:00
Kenneth Skovhede cbf98657d3 Rename part 1 2024-04-29 21:43:07 +02:00
Kenneth Skovhede 5b9e294dec Revisiting the machine-id concept.
Removed the text from the update folder as it is no longer being used.
Added a new `machineid.txt` file that controls the machine-id.
De-coupled the machine-id from the installationid as the latter is used for usage reporting, and should not be connected to the machine-id
2024-04-29 17:58:00 +02:00
Kenneth Skovhede b6ca526ee7 Implemented the new manifest format
Fixed some issues with the manifest urls.
Changed to records and nullable in some places.
Regenerated the test-keys to use RSA208.
Changed to using built-in JSON for manifest.
This fixes #5145
2024-04-23 13:41:59 +02:00
Kenneth Skovhede a0c0cbf3d5 Removed mentions of Mono in code, and fixed some entry paths pointing to the dll instead of the exe 2024-04-15 13:20:39 +02:00
Kenneth Skovhede 847be2d00a More fixes to support transistions to new updater 2024-04-06 10:27:33 +02:00
Kenneth Skovhede d15ed599d9 Prevent crashes on debug builds 2024-04-05 16:50:21 +02:00
Kenneth Skovhede f1e767b9cc Work on creating the signed manifests 2024-03-27 19:52:40 +01:00
Kenneth Skovhede cc091f06fe Minor fix to increase compatibility with older clients 2024-03-27 11:25:16 +01:00
Kenneth Skovhede a1a4042198 Added support for having multiple valid keys for a manifest 2024-03-27 11:24:49 +01:00
Kenneth Skovhede 115e887802 Implemented new updater logic that supports multi-arch distributions. 2024-03-15 14:18:56 +01:00
Kenneth Skovhede 2303f9151f Cleanup after merge 2024-03-04 14:00:55 +01:00