diff --git a/lib/private/Files/Cache/Updater.php b/lib/private/Files/Cache/Updater.php index 1c1fc8b992659..823e32fab78c5 100644 --- a/lib/private/Files/Cache/Updater.php +++ b/lib/private/Files/Cache/Updater.php @@ -119,6 +119,12 @@ public function update($path, $time = null, ?int $sizeDifference = null) { if (isset($data['encrypted']) && (bool)$data['encrypted']) { $sizeDifference = null; } + + // skip E2E encryption metadata files to avoid interfering with internal encryption handling + $appDataPath = 'appdata_' . \OC_Util::getInstanceId() . '/end_to_end_encryption/meta-data'; + if (str_starts_with($path, $appDataPath)) { + return; + } // scanner didn't provide size info, fallback to full size calculation if ($this->cache instanceof Cache && $sizeDifference === null) { @@ -147,6 +153,12 @@ public function remove($path) { $this->cache->remove($path); + // skip E2E encryption metadata files to avoid interfering with internal encryption handling + $appDataPath = 'appdata_' . \OC_Util::getInstanceId() . '/end_to_end_encryption/meta-data'; + if (str_starts_with($path, $appDataPath)) { + return; + } + $this->correctParentStorageMtime($path); if ($entry instanceof ICacheEntry) { $this->propagator->propagateChange($path, time(), -$entry->getSize());