Skip to content

x/net/webdav: microsoft miniredirector fails setting properties of directories #43929

Open
golang/net
#94
@klarose

Description

@klarose

What version of Go are you using (go version)?

$ go version
go version go1.15 linux/amd64

Does this issue reproduce with the latest release?

Yes

What operating system and processor architecture are you using (go env)?

go env Output
$ go env
GO111MODULE=""
GOARCH="amd64"
GOBIN=""
GOCACHE="/home/kyle/.cache/go-build"
GOENV="/home/kyle/.config/go/env"
GOEXE=""
GOFLAGS=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOINSECURE=""
GOMODCACHE="/home/kyle/pkg/mod"
GONOPROXY=""
GONOSUMDB=""
GOOS="linux"
GOPATH="/home/kyle/"
GOPRIVATE=""
GOPROXY="https://proxy.golang.org,direct"
GOROOT="/usr/local/go"
GOSUMDB="sum.golang.org"
GOTMPDIR=""
GOTOOLDIR="/usr/local/go/pkg/tool/linux_amd64"
GCCGO="gccgo"
AR="ar"
CC="gcc"
CXX="g++"
CGO_ENABLED="1"
GOMOD=""
CGO_CFLAGS="-g -O2"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-g -O2"
CGO_FFLAGS="-g -O2"
CGO_LDFLAGS="-g -O2"
PKG_CONFIG="pkg-config"
GOGCCFLAGS="-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build009155035=/tmp/go-build -gno-record-gcc-switches"

What did you do?

Ran a simple wrapper around x/net/webdav. Pointed the windows mini redirector (from windows 10) at it, then tried to clone golang/net: git clone https://github.com/golang/net.git

What did you expect to see?

The git clone succeed.

What did you see instead?

Z:\>git clone https://github.com/golang/net.git
Cloning into 'net'...
//files.kyle-shares.agilicus.cloud@SSL/DavWWWRoot/agent/net/.git: Input/output error

Digging in, it's clear that the issue is due to windows trying to set properties directories such as ./.git.

I added some logging to the proppatch handler and found it doing these operations:

2021/01/26 12:16:21 Patching /net {urn:schemas-microsoft-com: Win32CreationTime}
2021/01/26 12:16:21 Patching /net {urn:schemas-microsoft-com: Win32LastAccessTime}
2021/01/26 12:16:21 Patching /net {urn:schemas-microsoft-com: Win32LastModifiedTime}
2021/01/26 12:16:21 Patching /net {urn:schemas-microsoft-com: Win32FileAttributes}
2021/01/26 12:16:21 Fail on patch: open /home/kyle/shared/net: is a directory

Metadata

Metadata

Assignees

No one assigned

    Labels

    NeedsDecisionFeedback is required from experts, contributors, and/or the community before a change can be made.

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions