webdav: fix proppatch handling

also respect login delay for cached webdav users and check the home dir as
soon as the user authenticates

Fixes #239
This commit is contained in:
Nicola Murino
2020-12-06 08:19:41 +01:00
parent 4a88ea5c03
commit 034d89876d
7 changed files with 81 additions and 30 deletions

View File

@@ -143,7 +143,8 @@ func (c *Connection) OpenFile(ctx context.Context, name string, flag int, perm o
if err != nil {
return nil, c.GetFsError(err)
}
if flag == os.O_RDONLY {
if flag == os.O_RDONLY || c.request.Method == "PROPPATCH" {
// Download, Stat, Readdir or simply open/close
return c.getFile(p, name)
}