Just created a ticket in the help desk, maybe this helps that they understand the problem:
Caching using WebDAV doesn’t work with mailbox.org because you’re not responding the correct HTTP status codes according to the RFCs https://tools.ietf.org/html/rfc7234#section-4.3.2 and https://tools.ietf.org/html/rfc7232#section-6. Here you can also find a short summery: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/If-None-Match
The response from the server when an “If-None-Match” header is set in the GET request MUST be 200
if the content has been changed and 302
if unmodified when the ETag is provided. Your server return 412
instead of 302
. See the following snippets to reproduce the problem:
curl -I -X GET "https://dav.mailbox.org/servlet/webdav.infostore/Userstore/xxx/asdf/masterkey.cryptomator" -u xxx@mailbox.org
Enter host password for user 'xxx@mailbox.org':
HTTP/1.1 200 OK
Date: Tue, 02 Feb 2021 14:09:11 GMT
Server: Openexchange WebDAV
X-Robots-Tag: none
Content-Disposition: attachment
ETag: 8035586-1-1-1612264501136
Accept-Ranges: bytes
Last-Modified: Tue, 02 Feb 2021 11:15:01 GMT
Content-Type: application/octet-stream
Content-Length: 327
Strict-Transport-Security: max-age=15768000
curl -I -H 'If-None-Match: "8035586-1-1-1612264501136"' -X GET "https://dav.mailbox.org/servlet/webdav.infostore/Userstore/xxx/asdf/masterkey.cryptomator" -u xxx@mailbox.org
Enter host password for user 'xxx@mailbox.org':
HTTP/1.1 412 Precondition Failed
Date: Tue, 02 Feb 2021 14:10:44 GMT
Server: Openexchange WebDAV
X-Robots-Tag: none
Content-Length: 0
Strict-Transport-Security: max-age=15768000
but the file didn’t even changed, see
curl -I -X GET "https://dav.mailbox.org/servlet/webdav.infostore/Userstore/xxx/asdf/masterkey.cryptomator" -u xxx@mailbox.org
Enter host password for user 'xxx@mailbox.org':
HTTP/1.1 200 OK
Date: Tue, 02 Feb 2021 14:35:20 GMT
Server: Openexchange WebDAV
X-Robots-Tag: none
Content-Disposition: attachment
ETag: 8035586-1-1-1612264501136
Accept-Ranges: bytes
Last-Modified: Tue, 02 Feb 2021 11:15:01 GMT
Content-Type: application/octet-stream
Content-Length: 327
Strict-Transport-Security: max-age=15768000
and
curl -I -H 'If-Match: "8035586-1-1-1612264501136"' -X GET "https://dav.mailbox.org/servlet/webdav.infostore/Userstore/xxx/asdf/masterkey.cryptomator" -u xxx@mailbox.org
Enter host password for user 'xxx@mailbox.org':
HTTP/1.1 200 OK
Date: Tue, 02 Feb 2021 14:39:13 GMT
Server: Openexchange WebDAV
X-Robots-Tag: none
Content-Disposition: attachment
ETag: 8035586-1-1-1612264501136
Accept-Ranges: bytes
Last-Modified: Tue, 02 Feb 2021 11:15:01 GMT
Content-Type: application/octet-stream
Content-Length: 327
Strict-Transport-Security: max-age=15768000
Please use as defined in the RFC, 200
if the content has been changed and 302
if unmodified when the “If-None-Match” header is set and the valid ETag
is provided.
If you need further information, please let me know.