fix(rclone): replace the forked binary with upstream v1.75.0 - #56
Conversation
The bundled bin/rclone_linux_amd64 was a custom fork build (v1.67.0-beta.8042.483c2feed.kiteworks-backend, Go 1.22.4, built 2024-07-01). Trivy reports 23 HIGH/CRITICAL vulnerabilities against it, 16 of them Go stdlib CVEs, including CVE-2025-68121 (CRITICAL, crypto/tls), CVE-2024-45337 (CRITICAL, x/crypto) and CVE-2026-33186 (CRITICAL, gRPC). Nothing required the fork. The app runs only `rclone sync` and `rclone obscure` against type=webdav,vendor=owncloud remotes, and the fork's kiteworks-backend is never referenced. Upstream v1.75.0 accepts every flag StateMigrateFiles passes, including --webdav-owncloud-exclude-shares and --webdav-owncloud-exclude-mounts (backend/webdav/webdav.go:158,163). The replacement is the official rclone-v1.75.0-linux-amd64.zip artifact, sha256 aa2804e08f48250e71009c727124b6341cd0288465804a9a09d14663cabafbaa, built with Go 1.26.5. It scans clean: no HIGH/CRITICAL findings. Also document why appinfo/install.php still chmods the binary: the exec bit is correct in git and in the app tarball, but the complete tarball normalized it away, which additionally hid the binary from Trivy - its gobinary analyzer only inspects files that have an exec bit. Signed-off-by: Thomas Müller <1005065+DeepDiver1975@users.noreply.github.com>
|
Acceptance suite run locally against this branch ( The file-migration assertions are the ones that exercise upstream rclone rather than just its argument parsing: Users, groups, app roles and all five share shapes (user, group, public link, password-protected link, file-drop, expiring) also migrated clean. So the swap is verified end-to-end, not just at the flag level. |
Upstream rclone v1.75.0 (the newest release, 2026-07-31) is built with go1.26.5. Trivy reports eight HIGH stdlib findings against it that are fixed in go 1.25.13 / 1.26.6 - no rclone release has been built with those yet, so no available binary is free of them. All are DoS/XSS class, none CRITICAL, and none is reachable from how the app drives rclone (`rclone sync` and `rclone obscure` against one trusted ownCloud WebDAV endpoint). Each entry carries expired_at: 2026-11-01 and is scoped to the binary's path, so the acceptance expires by itself and cannot spread to other components. Verified that Trivy stops suppressing an expired entry. Signed-off-by: Thomas Müller <1005065+DeepDiver1975@users.noreply.github.com>
…efile Making apps/*/bin/* executable also makes the bundled rclone binary visible to Trivy's gobinary analyzer for the first time. Once the 11.0.0 tarball ships upstream rclone v1.75.0 (owncloud/migrate_to_ocis#56) the image scan reports eight HIGH go1.26.5 stdlib findings; they are fixed in go 1.25.13 / 1.26.6, which no rclone release has been built with yet. Converts v24.04/11.0.0/.trivyignore to the YAML format so each entry can carry expired_at (2026-11-01) and a path scope - the acceptance expires by itself instead of being buried, and cannot spread to other components. Plain and YAML ignore files cannot be mixed in one scan, so the existing CVE-2024-51736 entry moves across with its justification. v22.04/10.16.4 is untouched: it does not bundle migrate_to_ocis. Signed-off-by: Thomas Müller <1005065+DeepDiver1975@users.noreply.github.com>
CI evidence for the swap, from the new Trivy scanRan the reusable Trivy workflow (owncloud/reusable-workflows#92) against both sides, in real CI with a current vulnerability DB:
(48 rather than the 23 I reported earlier: my local Trivy DB is frozen at 2026-06-05, so those numbers were a lower bound.) Why an ignorefile is still neededv1.75.0 is the newest rclone release (2026-07-31) and upstream built it with go1.26.5. The eight remaining findings are all fixed in go 1.25.13 / 1.26.6 — no rclone release exists today that does not report them. All are denial-of-service / XSS class, none CRITICAL, and none is reachable from how this app drives rclone ( So The structural point, worth its own issueVendoring a prebuilt third-party Go binary means the stdlib in this repo is always as old as the upstream release, so every Go security release turns this scan red until rclone cuts a new build. Two ways out, both bigger than this PR:
Happy to file (1) as a follow-up if you want it pursued. |
…efile Making apps/*/bin/* executable also makes the bundled rclone binary visible to Trivy's gobinary analyzer for the first time. Once the 11.0.0 tarball ships upstream rclone v1.75.0 (owncloud/migrate_to_ocis#56) the image scan reports eight HIGH go1.26.5 stdlib findings; they are fixed in go 1.25.13 / 1.26.6, which no rclone release has been built with yet. Converts v24.04/11.0.0/.trivyignore to the YAML format so each entry can carry expired_at (2026-11-01) and a path scope - the acceptance expires by itself instead of being buried, and cannot spread to other components. Plain and YAML ignore files cannot be mixed in one scan, so the existing CVE-2024-51736 entry moves across with its justification. v22.04/10.16.4 is untouched: it does not bundle migrate_to_ocis. Signed-off-by: Thomas Müller <1005065+DeepDiver1975@users.noreply.github.com>
Ship the upstream rclone v1.75.0 binary from #56 in a tagged release. The fix has been on master since #56 but nothing consumes master: the ownCloud Server 11 distribution assembles its apps from tagged GitHub releases, and the pinned v3.0.0 still carries the old custom rclone fork build (v1.67.0-beta, Go 1.22.4) with 23 HIGH/CRITICAL findings. Releasing 3.0.1 is what lets the Server 11 image stop reporting them. Roll the rclone-1.75.0 changelog fragment into changelog/3.0.1_2026-08-20/, regenerate CHANGELOG.md with calens, and bump appinfo/info.xml to 3.0.1 - the release workflow refuses to build when the tag and info.xml version disagree. Signed-off-by: Thomas Müller <1005065+DeepDiver1975@users.noreply.github.com> Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
Why
bin/rclone_linux_amd64was a custom fork build —v1.67.0-beta.8042.483c2feed.kiteworks-backend, Go 1.22.4, built 2024-07-01. Trivy reports 23 HIGH/CRITICAL vulnerabilities against it, 16 of them Go stdlib CVEs, including:CVE-2025-68121— CRITICAL,crypto/tlscertificate validationCVE-2024-45337— CRITICAL,golang.org/x/cryptoCVE-2026-33186— CRITICAL, gRPCNone of this showed up in CI or in the
owncloud/serverimage scan, for a separate reason fixed in owncloud/server-release#52: the complete tarball normalized the binary to0644, and Trivy's gobinary analyzer only inspects files with an exec bit set, so it was never analyzed at all.Why upstream is safe here
The fork was not needed:
rclone sync(lib/MigrationState/StateMigrateFiles.php:172) andrclone obscure(:255), againsttype=webdav,vendor=owncloudremotes.kiteworks-backendis never referenced anywhere in the app.--webdav-owncloud-exclude-shares/--webdav-owncloud-exclude-mounts(backend/webdav/webdav.go:158,163).Verified by running the exact flag set from
StateMigrateFilesagainst v1.75.0:What
Replace the binary with the official
rclone-v1.75.0-linux-amd64.zipartifact:sha256 of the downloaded zip:
aa2804e08f48250e71009c727124b6341cd0288465804a9a09d14663cabafbaa(checked against the releaseSHA256SUMS).Also documents why
appinfo/install.phpkeeps its runtimechmod 0755— it is a safety net for installs from tarballs built before owncloud/server-release#52.Testing
(
rootfs, notfs— thefsscanner does not run the gobinary analyzer.)php -l appinfo/install.phpclean.Still to run before merge: the acceptance suite (
make test-acceptance, ownCloud Classic → oCIS) — the flag check above covers argument parsing, but an end-to-end migration is the real confirmation for a binary swap.Follow-up (not in this PR)
An 85 MB binary in git is avoidable — fetching it at
make disttime with a pinned checksum would keep the repo small and make future bumps trivial.🤖 Generated with Claude Code