Project

General

Profile

Actions

Bug #2296

closed

Saving file to webdav mapped drive fails

Added by omegaworks almost 14 years ago. Updated over 8 years ago.

Status:
Fixed
Priority:
Normal
Category:
mod_webdav
Target version:
ASK QUESTIONS IN Forums:

Description

Hi Lighty devs.

I'm having an issue with mod_webdav and lighty 1.4.22
I have my site mounted as a Mapped Network Drive in Windows 7, following these instructions. I'm using mod_ssl to provide webdav over ssl.

I'm having an issue saving a file to the mapped drive from Paint.NET. The file I'm saving is named "3-29-2010 2-37-39 PM.png", saving it to the /Connecting/ folder. The server is named MYSERVER.mit.edu

My access log looks like this:

75.34.31.39 MYSERVER.mit.edu test [11/Feb/2011:00:38:49 -0500] "PROPFIND /Connecting/3-29-2010%202-37-39%20PM.png HTTP/1.1" 404 345 "-" "Microsoft-WebDAV-MiniRedir/6.1.7600" 
75.34.31.39 MYSERVER.mit.edu test [11/Feb/2011:00:38:50 -0500] "PUT /Connecting/3-29-2010%202-37-39%20PM.png HTTP/1.1" 201 0 "-" "Microsoft-WebDAV-MiniRedir/6.1.7600" 
75.34.31.39 MYSERVER.mit.edu test [11/Feb/2011:00:38:50 -0500] "PROPPATCH /Connecting/3-29-2010%202-37-39%20PM.png HTTP/1.1" 200 0 "-" "Microsoft-WebDAV-MiniRedir/6.1.7600" 
75.34.31.39 MYSERVER.mit.edu test [11/Feb/2011:00:38:50 -0500] "PROPFIND /Connecting HTTP/1.1" 207 678 "-" "Microsoft-WebDAV-MiniRedir/6.1.7600" 
75.34.31.39 MYSERVER.mit.edu test [11/Feb/2011:00:38:50 -0500] "DELETE /Connecting/3-29-2010%202-37-39%20PM.png HTTP/1.1" 204 0 "-" "Microsoft-WebDAV-MiniRedir/6.1.7600" 
75.34.31.39 MYSERVER.mit.edu test [11/Feb/2011:00:39:00 -0500] "PUT /Connecting/3-29-2010%202-37-39%20PM.png HTTP/1.1" 201 0 "-" "Microsoft-WebDAV-MiniRedir/6.1.7600" 
75.34.31.39 MYSERVER.mit.edu test [11/Feb/2011:00:39:00 -0500] "LOCK /Connecting/3-29-2010%202-37-39%20PM.png HTTP/1.1" 409 343 "-" "Microsoft-WebDAV-MiniRedir/6.1.7600" 
75.34.31.39 MYSERVER.mit.edu test [11/Feb/2011:00:39:21 -0500] "PROPFIND /Connecting%20Off%20Campus.html HTTP/1.1" 207 637 "-" "Microsoft-WebDAV-MiniRedir/6.1.7600" 

Is Paint.NET the issue? Windows? lighttpd? I'm not sure what's supposed to happen during the save-file server-client dance.

I get a generic "An I/O error occurred when writing to the file." message from Paint.NET. The file exists on the server, but it is empty. Server-side, the /Connecting/ folder is chmod 777, so I don't think it's a permissions issue. I've successfully created and saved files into the folder from Notepad.


Related issues 1 (0 open1 closed)

Related to Feature #1953: Improve DAV support to be able to handle git as a clientFixed2009-04-03Actions
Actions #1

Updated by omegaworks almost 14 years ago

I am also having an issue with drag-copying a file (win_step4.png) into the Connecting folder from my desktop.

75.34.31.39 MYSERVER.mit.edu test [11/Feb/2011:01:33:13 -0500] "PROPFIND /.git HTTP/1.1" 404 345 "-" "Microsoft-WebDAV-MiniRedir/6.1.7600" 
75.34.31.39 MYSERVER.mit.edu test [11/Feb/2011:01:33:13 -0500] "PROPFIND / HTTP/1.1" 207 7976 "-" "Microsoft-WebDAV-MiniRedir/6.1.7600" 
75.34.31.39 MYSERVER.mit.edu test [11/Feb/2011:01:33:13 -0500] "PROPFIND /Connecting/win_step4.png HTTP/1.1" 207 630 "-" "Microsoft-WebDAV-MiniRedir/6.1.7600" 
75.34.31.39 MYSERVER.mit.edu test [11/Feb/2011:01:33:13 -0500] "LOCK /Connecting/win_step4.png HTTP/1.1" 409 343 "-" "Microsoft-WebDAV-MiniRedir/6.1.7600" 
75.34.31.39 MYSERVER.mit.edu test [11/Feb/2011:01:33:20 -0500] "PROPFIND / HTTP/1.1" 207 7976 "-" "Microsoft-WebDAV-MiniRedir/6.1.7600" 

I think it has to do with the 409 error issued with the LOCK request.
It may be related to issue #1953, as I suspect that Windows is sending these LOCK requests without specifying a Depth header. For regular files, lighty can handle Depth: Infinity like it handles Depth 0, and should do that instead of erroring out. I think there's a patch mentioned in that issue. Has that been merged into newer versions of 1.4?

Most of my users are using Windows as their DAV client, so this is kind of a showstopper for me.

Actions #2

Updated by Olaf-van-der-Spek almost 14 years ago

omegaworks wrote:

I'm having an issue with mod_webdav and lighty 1.4.22

You might want to try 1.4.28.

Actions #3

Updated by omegaworks almost 14 years ago

lighttpd/1.4.28 (ssl) - a light and fast webserver
Build-Date: Nov 21 2010 06:41:02

Updated to 1.4.28 offered by latest ubuntu release, still having problems with saving and drag-copy.

Actions #4

Updated by gstrauss over 8 years ago

@omegaworks, as you pointed out, the problem looks to be the Depth: infinity lock requests.
lighttpd mod_webdav.c does not support Depth: infinity, and if Depth header is not provided, Depth: infinity is the default.

Since this ticket is many years old, I presume you have found a different solution, presumably using a more RFC compliant webdav server.

For those that might find this ticket, one alternative is to build lighttpd without --with-webdav-locks. Of course, that means that files won't be protected by webdav locks. For a number of usage scenarios, this is acceptable, but for others, that behavior is not. This is not a generic solution, of course.

Another possibility is that this issue might be addressed by the lighttpd-git-infinite-locks-regular-files.patch in https://redmine.lighttpd.net/issues/1953

Actions #5

Updated by gstrauss over 8 years ago

Submitted pull request https://github.com/lighttpd/lighttpd1.4/pull/34 to support Depth: Infinity locks on files.

That should fix this issue in this ticket where Depth header was missing in LOCK request from Microsoft-WebDAV-MiniRedir/6.1.7600. Hopefully Microsoft-WebDAV-MiniRedir was been updated in the meantime to include a Depth header, as immediately prior to the LOCK request, Microsoft-WebDAV-MiniRedir makes a PROPFIND request (in the trace provided further above) and knows whether the target is a file or a directory (webdav collection).

Actions #6

Updated by gstrauss over 8 years ago

  • Target version changed from 1.4.x to 1.4.40
Actions #7

Updated by gstrauss over 8 years ago

  • Category set to mod_webdav
Actions #8

Updated by stbuehler over 8 years ago

  • Related to Feature #1953: Improve DAV support to be able to handle git as a client added
Actions #9

Updated by stbuehler over 8 years ago

  • Status changed from New to Fixed
  • % Done changed from 0 to 100

Applied in changeset r3133.

Actions

Also available in: Atom