From 3db267a03b74a3ddb8a525d239e3003620919f50 Mon Sep 17 00:00:00 2001 From: Kevin Ottens Date: Thu, 18 Jun 2020 13:34:47 +0200 Subject: [PATCH] Ensure GetFolderEncryptStatusJob gets all the folders We ensure the PROPFIND Depth is infinity by explicitly specifying the header (turns out our implementation just doesn't assume infinity otherwise). This way we have a clear picture about *all* the folders of the user, otherwise ClientSideEncryption couldn't be a trustable oracle on the encryption state for any folder not on the root and all the encryption code assumes it has a full picture of encryption. Signed-off-by: Kevin Ottens --- src/libsync/clientsideencryptionjobs.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/libsync/clientsideencryptionjobs.cpp b/src/libsync/clientsideencryptionjobs.cpp index 5c8876206..707612413 100644 --- a/src/libsync/clientsideencryptionjobs.cpp +++ b/src/libsync/clientsideencryptionjobs.cpp @@ -35,6 +35,7 @@ void GetFolderEncryptStatusJob::start() req.setPriority(QNetworkRequest::HighPriority); req.setRawHeader("OCS-APIREQUEST", "true"); req.setHeader(QNetworkRequest::ContentTypeHeader, QByteArrayLiteral("application/xml")); + req.setRawHeader("Depth", "infinity"); QByteArray xml = R"( )"; auto *buf = new QBuffer(this); -- 2.30.2