Summary: | WebDAV shared files all show "Jan 1 1970" as modification time since 6.0 upgrade | ||
---|---|---|---|
Product: | [Frameworks and Libraries] frameworks-kio | Reporter: | Jens <jens-bugs.kde.org> |
Component: | WebDAV | Assignee: | KIO Bugs <kio-bugs-null> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | code-bugs, fabian, kdelibs-bugs, kfm-devel, nate |
Priority: | NOR | ||
Version: | 6.0.0 | ||
Target Milestone: | --- | ||
Platform: | Other | ||
OS: | Linux | ||
Latest Commit: | https://invent.kde.org/frameworks/kio/-/commit/a4d7b335d61e32993c90fa1a6ee143b860219f4f | Version Fixed In: | Frameworks 6.2 |
Sentry Crash Report: |
Description
Jens
2024-03-28 16:22:56 UTC
Same on openSUSE Tumbleweed A curl PROPFIND confirms that the WebDAV server correctly reports <d:getlastmodified> tags. > [ben@skylab:~]% kioclient stat webdavs://myserver.domain/remote.php/dav/files/myuser/Docs > NAME Docs > FILE_TYPE 0040000 > ACCESS 0700 > MODIFICATION_TIME Thu Jan 1 00:00:00 1970 > CREATION_TIME Thu Jan 1 01:00:00 1970 > [ben@skylab:~]% kioclient stat webdavs://myserver.domain/remote.php/dav/files/myuser/Docs/myfile.pdf > NAME myfile.pdf > SIZE 23199 > FILE_TYPE 0100000 > MIME_TYPE application/pdf > ACCESS 0600 > MODIFICATION_TIME Thu Jan 1 00:00:00 1970 > CREATION_TIME Thu Jan 1 01:00:00 1970 > [ben@skylab:~]% curl -s -u myuser:myapppass -X PROPFIND https://myserver.domain/remote.php/dav/files/myuser/Docs/myfile.pdf | xmlformat > <?xml version="1.0"?> > <d:multistatus xmlns:d="DAV:" xmlns:s="http://sabredav.org/ns" xmlns:oc="http://owncloud.org/ns" xmlns:nc="http://nextcloud.org/ns"> > <d:response> > <d:href>/remote.php/dav/files/myuser/Docs/myfile.pdf</d:href> > <d:propstat> > <d:prop> > <d:getlastmodified>Mon, 04 Dec 2023 20:55:42 GMT</d:getlastmodified> > <d:getcontentlength>23199</d:getcontentlength> > <d:resourcetype/> > <d:getetag>"c9bfb90c5430b5bc2883b21527045dac"</d:getetag> > <d:getcontenttype>application/pdf</d:getcontenttype> > </d:prop> > <d:status>HTTP/1.1 200 OK</d:status> > </d:propstat> > </d:response> > </d:multistatus> > A cross check with a smb:// url show fine: [ben@skylab:~]% kioclient stat smb://mysambaserv/ben > NAME ben > SIZE 0 > FILE_TYPE 0040000 > MODIFICATION_TIME Fri Mar 22 20:17:44 2024 > ACCESS_TIME Sat Mar 23 16:43:54 2024 > Information for package kio-core: > --------------------------------- > Repository : Haupt-Repository (OSS) > Name : kio-core > Version : 5.115.0-1.1 > Arch : x86_64 > Vendor : openSUSE > Installed Size : 2.7 MiB > Installed : Yes > Status : up-to-date > Source package : kio-5.115.0-1.1.src > Upstream URL : https://www.kde.org > Summary : Network transparent access to files and data > Description : > This framework implements almost all the file management functions you > will ever need. In fact, the KDE file manager (Dolphin) and the KDE > file dialog also uses this to provide its network-enabled file management. > KIO core libraries, ioslave and daemons. > A possibly relevant merge request was started @ https://invent.kde.org/frameworks/kio/-/merge_requests/1606 Bug in Qt: https://bugreports.qt.io/browse/QTBUG-114681 I opened a MR with a workaround. Git commit a4d7b335d61e32993c90fa1a6ee143b860219f4f by Fabian Vogt. Committed on 07/04/2024 at 11:15. Pushed by fvogt into branch 'master'. http: Fix parsing DAV:getlastmodified It's defined as a rfc1123 date which always has a "GMT" suffix (which means UTC). The Qt::RFC2822Date parser in Qt no longer accepts timezones declared as obsolete in RFC2822, even though that RFC says it MUST be accepted... Also add some error handling to avoid spitting out invalid UDS values. M +21 -6 src/kioworkers/http/http.cpp https://invent.kde.org/frameworks/kio/-/commit/a4d7b335d61e32993c90fa1a6ee143b860219f4f |