Summary: | Webdav kioslave seems to generate wrong auth digest for PUT | ||
---|---|---|---|
Product: | [Unmaintained] kio | Reporter: | Martin van Es <bugs> |
Component: | webdav | Assignee: | kdelibs bugs <kdelibs-bugs> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | adawit |
Priority: | NOR | ||
Version: | unspecified | ||
Target Milestone: | --- | ||
Platform: | Ubuntu | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | 4.7.3 | |
Sentry Crash Report: |
Description
Martin van Es
2011-06-09 22:18:59 UTC
I'm stupified. The internal SabreDAV Digest authentication works for PUT but I can't find the difference in response calculation :/ I switched to SabreDAV's built-int Digest Auth methods and all works like a charm. Regard this bug invalid. After a little inspection on the wire I now know why SabreDav's Digest implementation works: it simply sends a 401 (Unauthorized) on the first PUT attempt after which kio-webdav retries with a correct digest. In a staged test environment I can reproduce the bug easily: kio webdav sends this digest on first PUT: Digest username=\"test1\", realm=\"BigDisk.nl\", nonce=\"4df9c200e8eb5\", uri=\"/test\", algorithm=MD5, qop=auth, cnonce=\"aD7YZtDC7CvnSLsW\", nc=00000001, response=\"7f97744c1fae242c0cc62b4c3efcb6d1\", opaque=\"df58bdff8cf60599c939187d0b5c54de\" Which receives a 401, because it actually is wrong (password for user test1 is test1) Then it resends the complete PUT using the following digest: Digest username=\"test1\", realm=\"BigDisk.nl\", nonce=\"4df9c225e8519\", uri=\"/test\", algorithm=MD5, qop=auth, cnonce=\"qzssX6cI9Moj0Ila\", nc=00000001, response=\"b609e911ea3c508baccc9cee78e5262e\", opaque=\"df58bdff8cf60599c939187d0b5c54de\" Which succeeds because it validates correct (same password). The problem is that kio-webdav sends the complete PUT body containing all data twice, which may result in in severe upload delays for big files. Git commit 27973cd73a614aa0df298676efb3c6fb53a2d378 by Dawit Alemayehu. Committed on 23/10/2011 at 10:24. Pushed by adawit into branch 'KDE/4.7'. When uploading a file to a WebDAV server, regenrate the authentication header after doing the stat BUG: 275307 FIXED-IN: 4.7.3 M +3 -0 kioslave/http/http.cpp http://commits.kde.org/kdelibs/27973cd73a614aa0df298676efb3c6fb53a2d378 |