Tech News

Sync-in 2.7 Adds Chunked Uploads to Fix Large File Transfers Behind Reverse Proxies and Cloudflare

Sync-in 2.7 is now available, and this new release adds support for chunked uploads, making it possible to work around the limits imposed when the instance is placed behind certain reverse proxies or Cloudflare. This version also fixes three security flaws, including one rated high severity. Here is what you need to know before upgrading.

As a reminder, Sync-in is an open source file storage, sharing, and synchronization platform, often presented as an alternative to Nextcloud. It includes online document editing (OnlyOffice, Collabora Online, Euro-Office), WebDAV access, and synchronization clients for Windows, macOS, and Linux. In early November, I also published a full overview of the changes introduced in Sync-in 2.4 through 2.6. This time, it is version 2.7 that has been released.

Let’s start with a new conflict-handling option: Sync-in 2.7 also adds the “Keep both” option. When a file with the same name already exists at the destination (during an upload, copy, or move), the new file is automatically given a different name instead of replacing the existing one. Since my previous article, two intermediate releases have also been published. Version 2.6.3 added 40 languages to the interface (more than 50 in total), and version 2.6.4 reworked lock handling, with an announced 15% to 30% performance gain on common file operations.

Chunked uploads: what changes, and what needs to be configured

The headline feature in this release is server-side support for chunked uploads in Sync-in. The idea is simple: instead of sending a large file in a single HTTP request, the client splits it into chunks. Each chunk is sent in its own request, and the server reassembles the file on arrival. In everyday use, nothing changes for files smaller than a chunk: they are still uploaded in one go. However, this chunking comes into play when files are large.

Why is this useful? Because a reverse proxy often enforces a maximum size per request, and Cloudflare caps request bodies at 100 MB on its Free and Pro plans (according to the documentation). So if you place Sync-in behind Cloudflare or a reverse proxy, you may run into problems uploading large files. Finally, this change applies on the server side and in the web interface, because the Sync-in Desktop client and the command-line client have already been able to chunk uploads since version 2.4.0.

For those administering a Sync-in instance, this setting is located in a new applications.files.transfers block in the environment.yaml file. It contains two new parameters:

  • Maximum file size: maxUploadSize, set to 5 GiB by default.
  • Chunk size: maxChunkSize, set to 95 MiB by default (enough to stay below Cloudflare’s limit). With 0 or null, files are no longer split into chunks, which lets you keep control if you do not want to adopt this feature. If a reverse proxy is in place, the chunk size must remain below the limit it applies to each request.

Note that there is another benefit as well: an interrupted upload can resume where it left off.

Note: the legacy applications.files.maxUploadSize key and the SYNCIN_APPLICATIONS_FILES_MAXUPLOADSIZE environment variable, which previously defined the maximum file size accepted by the server, still work in 2.7, even though they are deprecated. If you configure the Sync-in server through environment variables (in a Docker container, for example) rather than in the environment.yaml file, the maximum file size is now set with SYNCIN_APPLICATIONS_FILES_TRANSFERS_MAXUPLOADSIZE, and the chunk size with SYNCIN_APPLICATIONS_FILES_TRANSFERS_MAXCHUNKSIZE.

Three vulnerabilities fixed

On the security side, Sync-in 2.7 fixes three vulnerabilities documented in advisories published on GitHub:

  • GHSA-8rmv-4f4p-v9jg, high severity: a member of a shared space who only had sharing rights could add a public link with permissions they did not actually have themselves (add, edit, delete). A link can no longer exceed the rights the user has on that share.
  • GHSA-wfx5-p4q9-x8pj, medium severity: a copy or sync operation could replace existing content without checking the required permissions. Edit rights are now required to replace a file, and add and delete rights on the destination are required to replace a folder.
  • GHSA-r53r-qpv5-9p7g, medium severity: during the first association of an OIDC identity with a local account, email address comparison was too permissive, which could attach the identity to the wrong account. It now ignores case while still distinguishing accented characters.

Before these vulnerabilities were fixed, version 2.6.3 had already introduced two security improvements: WebSocket connections are closed when the authentication token expires, and the password for a protected link is no longer included in notification emails by default (the applications.files.links.sendPasswordByEmail option can be used to restore the previous behavior).

What do you think?

author avatar
Florian Burnel Co-founder of IT-Connect
Systems and network engineer, co-founder of IT-Connect and Microsoft MVP "Cloud and Datacenter Management". I'd like to share my experience and discoveries through my articles. I'm a generalist with a particular interest in Microsoft solutions and scripting. Enjoy your reading.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.