Commit graph

108 commits

Author SHA1 Message Date
abraunegg dfd1d1aa4a
Implement #2414 to allow HTTP session timeout(s) tuning via config (#2425)
* Implement #2414 to allow HTTP session timeout(s) tuning via config (taken from v2.5.x)
2023-06-20 09:28:17 +10:00
NigelVanHattum 52b1276282
Fix for extra encoded quotation marks surrounding Docker environment variables (#2319)
* Fix for extra encoded quotation marks surrounding Docker environment variables

---------

Co-authored-by: Hattum van <Nigel.van.Hattum@rabobank.nl>
Co-authored-by: abraunegg <alex.braunegg@gmail.com>
2023-03-18 09:53:58 +11:00
abraunegg 7daf8797f8
Add performance output for key functions (#2180)
* Add developer option 'display_processing_time' to control if performance timing is outputted or not
* If option is enabled, print performance data around how long key functions are taking to process data to assist with understanding any performance related questions
2022-10-12 13:34:42 +11:00
abraunegg fd0a028276
Align application logging events to actual application defaults (#2170)
* Align application logging events to actual application defaults for --monitor operations
2022-10-07 06:52:38 +11:00
abraunegg 514df625b9
Add option to create a read-write shareable link (#2154)
* Implement Feature Request 2110 to add option to create a read-write shareable link
2022-09-26 17:56:42 +10:00
abraunegg 993770f49a
Fix DMD 2.100.2 depreciation warning (#2156)
DMD 2.100.2 creates a depreciation warning:

Deprecation: `return` statements cannot be in `scope(failure)` bodies.
2022-09-26 14:44:30 +10:00
abraunegg 738be2d150
Add option to cleanup local files regardless of sync state when using --download-only (#2113)
* Add option to cleanup local files regardless of sync state when using --download-only
2022-08-31 06:41:52 +10:00
abraunegg f561bd79a3
Update what application options require an argument (#2082)
* Update what application options require an argument
2022-08-08 10:19:06 +10:00
abraunegg d57a695632
Add option to request readonly access in oauth authorization step (#2065)
* Add option to request readonly access in oauth authorization step
* Add application-security.md to document application security
2022-08-06 08:24:51 +10:00
abraunegg cc3b83afcb
Implement --display-running-config (#2064)
* Implement --display-running-config to display the running configuration as used at application startup
* Add ONEDRIVE_DISPLAY_CONFIG variable to control --display-running-config in Docker environments
2022-08-06 06:25:58 +10:00
abraunegg 031c82922d
Enforce that --confdir must be a directory (#2051)
* Enforce that when we are using --confdir - the path that is passed in has to be a directory and not a file
2022-07-20 10:09:20 +10:00
abraunegg e422adb477
Fix handling of a custom configuration directory (#2029)
* Fix handling of a custom configuration directory
2022-07-04 05:59:00 +10:00
Sebastien Badia 0ab2955bd7
Various little spelling fixes (check with lintian during Debian packaging) (#2027)
* contrib: remove bash hashbang from completion

This file starts with the #! sequence that marks interpreted scripts, but
it is a bash completion script that is merely intended to be sourced.

* src: spelling error (Attemtping => Attempting)

* src: spelling error (reponse => response)

* src: spelling error (sucessfully => successfully)
2022-07-02 05:14:50 +10:00
abraunegg 0e0fdacf7c
Switch to using curl defaults for HTTP/2 operations (#2026)
* Switch to using curl defaults for HTTP/2 operations
2022-07-01 15:09:11 +10:00
abraunegg ca984eba70
Update OneDrive API response handling for National Cloud Deployments (#2023)
* Update OneDrive API response handling for National Cloud Deployments
* Add developer option to allow easy switch between /children and /delta to query OneDrive for changes
2022-06-30 07:08:29 +10:00
abraunegg 0fffb8fbc0
Implement a check to validate local filesystem available space before attempting file download (#1971)
* Implement a check to validate local filesystem available space before attempting file download
* Implement 'space_reservation' config option with a default value of 50 MB
* Prevent the original run-away logging error message 'Failed initialization on handle XXXX' from occurring if the system is out of space
* Update documentation and man page
2022-06-01 05:57:05 +10:00
abraunegg de2bbb5564
Fix application crash if unable to read required hash files (#1963)
* Fix where if the --confdir as specified has incorrect parent permissions, the client is unable to read the required hash files, thus cause an application crash
* When opening files, we should only be opening them as read-only
* When we write out any hash files. they should only be readable|writeable by the userid that is running the application
2022-05-19 16:12:53 +10:00
abraunegg b38fd5c200
Override skip_dir|skip_file through flag to force sync (#1960)
* Force a synchronization of a specific folder, only when using --synchronize --single-directory and ignoring all non-default skip_dir and skip_file rules
2022-05-16 10:16:50 +10:00
abraunegg a52de36d63
Improve when the local database integrity check is performed and on what frequency (#1938)
* Improve when the local database integrity check is performed and on what frequency
2022-04-28 11:51:50 +10:00
abraunegg 3124b2dcf2
Implement feature request --modified-by (#1869)
* Implement --modified-by to display who last modified a file and when the modification was done
2022-03-10 07:00:07 +11:00
abraunegg d68c27fb4f
Add --reauth to allow easy re-authentication of the client (#1867)
* Add --reauth to allow easy re-authentication of the client
2022-03-08 05:35:00 +11:00
abraunegg 1ac5d87d98
Document risk regarding using --resync (#1816)
* Document risk regarding using --resync
* Implement --resync-auth
2022-01-28 08:58:38 +11:00
Kleckkinator 58d40c5174
Add --operation-timeout argument (#1759)
* This change is to create an argument version of the config operation_timeout.

There are many times where one may need to temporarily increase the timeout for an operation of a single large file that takes longer than the configured timeout. The command line argument is an excellent way to override the default or 'config' set option if required.
2021-12-30 11:19:55 +11:00
Yuan Liu 1e2827ad1c
Add Real-Time syncing of remote updates via webhooks (#1718)
* Add Real-Time syncing of remote updates via webhooks

Co-authored-by: abraunegg <alex.braunegg@gmail.com>
2021-11-24 06:54:28 +11:00
abraunegg ac2e07526a
Revert PR #1626 (#1716)
Revert PR #1626 due to deprecation function that needs to be resolved before PR can be merged again
2021-11-23 11:14:29 +11:00
abraunegg 2901534171
Add --disable-download-validation (#1686)
* Add --disable-download-validation to allow downloading files from OneDrive where SharePoint and the OneDrive API mis-represents the values in the API as compared to the actual HTTP server response sent to the client. In the API JSON response we get a "size" value of X, but the HTTP Server Content Length reports a size of Y. When this occurs, the download will report as failed. This was seen as part understanding the cause of https://github.com/abraunegg/onedrive/discussions/1667
2021-11-23 07:34:16 +11:00
Winston R. Milling 5d7e4532ef
Add --auth-response option and expose through entrypoint.sh (#1628)
* This allows for the use of the `--auth-files` switch in the docker environment.

Co-authored-by: abraunegg <alex.braunegg@gmail.com>
2021-11-23 07:08:04 +11:00
Yuan Liu bfeeae91de
Add Real-Time syncing of remote updates via webhooks (#1626)
* Add Real-Time syncing of remote updates via webhooks

Co-authored-by: abraunegg <alex.braunegg@gmail.com>
2021-11-23 07:06:13 +11:00
Kleckkinator 4d25e68c65
Added operation_timeout as a new configuration (#1685)
* Added operation_timeout as a new configuration
2021-11-10 07:46:41 +11:00
abraunegg 7786a17915
Remove depreciated config option 'force_http_11' (#1323)
* Remove depreciated config option 'force_http_11' which was flagged as depreciated by PR #549 in v2.3.6 (June 2019).
2021-03-08 07:17:48 +11:00
abraunegg 66a172d13a
Correctly handle '~' when present in 'log_dir' configuration option (#1258)
* Handle '~' when present in 'log_dir' and expand based on user and shell environment  variables to ensure correct expansion.
2021-02-06 20:46:56 +11:00
abraunegg 96d3e68498
Add new config option to rate limit connection to OneDrive (#1210)
* Add new config option to rate limit connection to OneDrive
2021-01-04 08:28:34 +11:00
abraunegg 550ab4b6dd
Use config set option for 'remove_source_files' and 'skip_dir_strict_match' rather than ignore (#1142)
* Remove items from direct config string update, as they are configurable via config file, thus set option via config file is not used
* Add debugging and application config output for used options
2020-11-14 06:17:53 +11:00
abraunegg 2c80033c89
Correctly set config directory permissions at first start (#1132)
* When ~/.config/onedrive/ gets created for the first time, directory permissions are not set, thus, effective permissions of 'd---------' get applied. This then causes issues attempting to update the 'refresh_token' as permission is denied.
* When permission is denied, the file exception error is not correctly handled
* Set refresh_token file permissions
2020-11-09 08:06:48 +11:00
abraunegg cf4ee5017f
Configure specific File and Folder Permissions (#1108)
* Configure specific File and Folder Permissions, defaults for new items downloaded from OneDrive:
Directories: 700
Files: 600
2020-10-30 08:00:26 +11:00
themoox 2f35a33f4f
Allow config to specify a tenant id for non-multi-tenant applications (#1085)
* Allow config to specify a tenant id for non-multi-tenant applications
* Add instructions on how to find your O365 tenant identifier for National Cloud deployments.

Co-authored-by: Ryan Brown <ryan.brown@avarint.com>
Co-authored-by: abraunegg <alex.braunegg@gmail.com>
2020-10-06 08:06:04 +11:00
abraunegg 19cf656c19
Implement Feature: Multiple skip_dir & skip_file configuration rules (#1068)
* Implement Feature: Multiple skip_dir & skip_file configuration rules
2020-09-19 07:51:49 +10:00
abraunegg 0c770efa96
Implement Feature: Create shareable link (#1061)
* Implement feature request to create a shareable file link. Default is to create a read-only anonymous link

Co-authored-by: Norbert Preining <norbert@preining.info>
2020-09-14 17:49:50 +10:00
abraunegg 9cc72c2396
Implement OneDrive Business Shared Folders Support (Issue #459) (#473)
* Implement OneDrive Business Shared Folders Support
2020-06-27 19:10:37 +10:00
abraunegg d8bfe846c2
Update documentation for --upload-only & --download-only to avoid ambiguity (#960)
* Update wording on --upload-only , --download-only to avoid ambiguity
* Update --upload-only usage example to include --no-remote-delete
2020-06-21 08:09:06 +10:00
abraunegg 1c10effb9b
Implement support for National cloud deployments (Issue #937) (#938)
* Implement support for National cloud deployments as per https://docs.microsoft.com/en-us/graph/deployments
2020-06-17 07:57:14 +10:00
Liran 46c91bac6e
Added support for loading system configs if there's no user config. (#914)
* Added support for loading system configs if there's no user config file supplied. Uses application defaults if corrupt.
* Update documentation to indicate where config files can be stored & read from
2020-06-05 14:49:31 +10:00
abraunegg f9c3ccc311
Add developer option to display sync options (#924)
* It may be desirable to see what options are being passed in to performSync() without enabling the full verbose debug logging. This has been useful when tracking down 'sync_list' / sync issue & other performance related items without having to enable full verbose debugging to see what is going on
2020-05-25 11:30:04 +10:00
abraunegg cd07414e7b
Change monitor interval default to 300 seconds (#923)
* Having a 45 second default between monitor sync loops is too short. If there are a large number of files on the system (30K+) local file integrity checks take longer than 1 minute to complete, thus, it will seem like the system is 'forever' processing. Changing this to 300 seconds between sync loops is a more sane default.
2020-05-21 11:08:07 +10:00
abraunegg fc90ccb425
Implement 'bypass_data_preservation' enhancement (Issue #824) (#831)
* On some Linux distributions, the file system search tool locally modifies certain files after indexing. Even though the file contents has not changed, the file itself has, as the local modified timestamp has been updated. This then causes timestamp checks to be invalid. To ignore this in cases where this is occurring, configure 'bypass_data_preservation' to 'true' in the config file and local data protection rules will be ignored.
* Add warning to application startup if 'bypass_data_preservation' has been enabled
2020-05-21 06:48:02 +10:00
abraunegg 206ab8f516
Resolve issues identified by Valgrind (#910)
* Resolve issues identified by 'valgrind' where possible
2020-05-20 11:37:11 +10:00
abraunegg 9933d459ed
Check if configuration file exists before trying to load it (#909)
* Check if configuration file exists before trying to load it
2020-05-20 11:31:30 +10:00
abraunegg ccbeae4942
Implement resync in config option (Issue #874) (#875)
* Implement the ability to set --resync as a config option, default is false
2020-04-20 13:03:36 +10:00
abraunegg 6f85d539da
Update client identifier and auth scopes (Issue #769) (#770)
* Update the client identifier to 'd50ca740-c83f-4d1b-b616-12c519384f0c'
* Update User Agent identifier to comply with OneDrive traffic decoration requirements
* Provide 'config' file option to modify / update client identifier to override application default
2020-03-23 07:01:51 +11:00
abraunegg b1fcb814c3
Update application output when just authorising application (Issue #820) (#821)
* Update application output to be clearer when just authorising the application and --synchronize or --monitor not passed in
* Update usage.md with updated authorize details and example
2020-03-15 06:29:44 +11:00