Skip to content

[master] WebDAV MOVE from root into shared folder as non owner 403 forbidden #12538

Closed

Description

@PVince81

Steps to reproduce

  1. Create two users "user1" and "user2"
  2. Login as "user1"
  3. Create a folder "test"
  4. Share "test" with "user2"
  5. Using a WebDAV client (I used cadaver), login as "user2"
  6. Upload a file "file.txt" into root
  7. Move "file.txt" from root into "/test" (the shared folder)

Expected result

Move succeeded

Actual result

403 Forbidden

Versions

Happens on OC 8 pre-alpha git master (8db4dd7)
Does NOT happen on stable7, so it's a regression.
openSUSE Factory x86_64
PHP 5.6.1
Apache 2.4

Logs

{"reqId":"114b0873faf06b24dedbdfc08cc640f1","remoteAddr":"::1","app":"PHP","message":"Undefined index: storage_mtime at \/srv\/www\/htdocs\/owncloud\/lib\/private\/files\/cache\/watcher.php#67","level":0,"time":"2014-12-02T09:57:02+00:00","method":"MOVE","url":"\/owncloud\/remote.php\/webdav\/test.txt"}
{"reqId":"114b0873faf06b24dedbdfc08cc640f1","remoteAddr":"::1","app":"PHP","message":"filemtime(): stat failed for \/srv\/www\/htdocs\/owncloud\/data\/root\/files\/oc\/test.txt at \/srv\/www\/htdocs\/owncloud\/lib\/private\/files\/storage\/local.php#137","level":0,"time":"2014-12-02T09:57:02+00:00","method":"MOVE","url":"\/owncloud\/remote.php\/webdav\/test.txt"}
{"reqId":"114b0873faf06b24dedbdfc08cc640f1","remoteAddr":"::1","app":"PHP","message":"Undefined index: mimetype at \/srv\/www\/htdocs\/owncloud\/lib\/private\/files\/fileinfo.php#97","level":0,"time":"2014-12-02T09:57:02+00:00","method":"MOVE","url":"\/owncloud\/remote.php\/webdav\/test.txt"}
{"reqId":"114b0873faf06b24dedbdfc08cc640f1","remoteAddr":"::1","app":"PHP","message":"Undefined index: storage_mtime at \/srv\/www\/htdocs\/owncloud\/lib\/private\/files\/cache\/watcher.php#67","level":0,"time":"2014-12-02T09:57:02+00:00","method":"MOVE","url":"\/owncloud\/remote.php\/webdav\/test.txt"}
{"reqId":"114b0873faf06b24dedbdfc08cc640f1","remoteAddr":"::1","app":"PHP","message":"filemtime(): stat failed for \/srv\/www\/htdocs\/owncloud\/data\/root\/files\/oc\/test.txt at \/srv\/www\/htdocs\/owncloud\/lib\/private\/files\/storage\/local.php#137","level":0,"time":"2014-12-02T09:57:02+00:00","method":"MOVE","url":"\/owncloud\/remote.php\/webdav\/test.txt"}
{"reqId":"114b0873faf06b24dedbdfc08cc640f1","remoteAddr":"::1","app":"PHP","message":"Undefined index: storage_mtime at \/srv\/www\/htdocs\/owncloud\/lib\/private\/files\/cache\/watcher.php#67","level":0,"time":"2014-12-02T09:57:02+00:00","method":"MOVE","url":"\/owncloud\/remote.php\/webdav\/test.txt"}
{"reqId":"114b0873faf06b24dedbdfc08cc640f1","remoteAddr":"::1","app":"PHP","message":"filemtime(): stat failed for \/srv\/www\/htdocs\/owncloud\/data\/root\/files\/oc\/test.txt at \/srv\/www\/htdocs\/owncloud\/lib\/private\/files\/storage\/local.php#137","level":0,"time":"2014-12-02T09:57:02+00:00","method":"MOVE","url":"\/owncloud\/remote.php\/webdav\/test.txt"}
{"reqId":"114b0873faf06b24dedbdfc08cc640f1","remoteAddr":"::1","app":"PHP","message":"Undefined index: storage_mtime at \/srv\/www\/htdocs\/owncloud\/lib\/private\/files\/cache\/watcher.php#67","level":0,"time":"2014-12-02T09:57:02+00:00","method":"MOVE","url":"\/owncloud\/remote.php\/webdav\/test.txt"}
{"reqId":"114b0873faf06b24dedbdfc08cc640f1","remoteAddr":"::1","app":"PHP","message":"filemtime(): stat failed for \/srv\/www\/htdocs\/owncloud\/data\/root\/files\/oc\/test.txt at \/srv\/www\/htdocs\/owncloud\/lib\/private\/files\/storage\/local.php#137","level":0,"time":"2014-12-02T09:57:02+00:00","method":"MOVE","url":"\/owncloud\/remote.php\/webdav\/test.txt"}
{"reqId":"114b0873faf06b24dedbdfc08cc640f1","remoteAddr":"::1","app":"PHP","message":"Undefined index: storage_mtime at \/srv\/www\/htdocs\/owncloud\/lib\/private\/files\/cache\/watcher.php#67","level":0,"time":"2014-12-02T09:57:02+00:00","method":"MOVE","url":"\/owncloud\/remote.php\/webdav\/test.txt"}
{"reqId":"114b0873faf06b24dedbdfc08cc640f1","remoteAddr":"::1","app":"PHP","message":"filemtime(): stat failed for \/srv\/www\/htdocs\/owncloud\/data\/root\/files\/oc\/test.txt at \/srv\/www\/htdocs\/owncloud\/lib\/private\/files\/storage\/local.php#137","level":0,"time":"2014-12-02T09:57:02+00:00","method":"MOVE","url":"\/owncloud\/remote.php\/webdav\/test.txt"}
{"reqId":"114b0873faf06b24dedbdfc08cc640f1","remoteAddr":"::1","app":"PHP","message":"Undefined index: storage_mtime at \/srv\/www\/htdocs\/owncloud\/lib\/private\/files\/cache\/watcher.php#67","level":0,"time":"2014-12-02T09:57:02+00:00","method":"MOVE","url":"\/owncloud\/remote.php\/webdav\/test.txt"}
{"reqId":"114b0873faf06b24dedbdfc08cc640f1","remoteAddr":"::1","app":"PHP","message":"filemtime(): stat failed for \/srv\/www\/htdocs\/owncloud\/data\/root\/files\/oc\/test.txt at \/srv\/www\/htdocs\/owncloud\/lib\/private\/files\/storage\/local.php#137","level":0,"time":"2014-12-02T09:57:02+00:00","method":"MOVE","url":"\/owncloud\/remote.php\/webdav\/test.txt"}
{"reqId":"114b0873faf06b24dedbdfc08cc640f1","remoteAddr":"::1","app":"webdav","message":"Exception: {\"Message\":\"\",\"Code\":0,\"Trace\":\"#0 \\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/3rdparty\\\/sabre\\\/dav\\\/lib\\\/Sabre\\\/DAV\\\/Tree.php(102): OC_Connector_Sabre_File->delete()\\n#1 \\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/3rdparty\\\/sabre\\\/dav\\\/lib\\\/Sabre\\\/DAV\\\/Server.php(1000): Sabre\\\\DAV\\\\Tree->delete('oc\\\/test.txt')\\n#2 [internal function]: Sabre\\\\DAV\\\\Server->httpMove('test.txt')\\n#3 \\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/3rdparty\\\/sabre\\\/dav\\\/lib\\\/Sabre\\\/DAV\\\/Server.php(474): call_user_func(Array, 'test.txt')\\n#4 \\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/3rdparty\\\/sabre\\\/dav\\\/lib\\\/Sabre\\\/DAV\\\/Server.php(214): Sabre\\\\DAV\\\\Server->invokeMethod('MOVE', 'test.txt')\\n#5 \\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/apps\\\/files\\\/appinfo\\\/remote.php(60): Sabre\\\\DAV\\\\Server->exec()\\n#6 \\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/remote.php(54): require_once('\\\/srv\\\/www\\\/htdocs...')\\n#7 {main}\",\"File\":\"\\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/lib\\\/private\\\/connector\\\/sabre\\\/file.php\",\"Line\":192}","level":4,"time":"2014-12-02T09:57:02+00:00","method":"MOVE","url":"\/owncloud\/remote.php\/webdav\/test.txt"}

@schiesbn @icewind1991

Activity

  1. added this to the milestone on Dec 2, 2014
  2. icewind1991 commented on Dec 2, 2014

    @icewind1991
    Contributor

    Looking into it

  3. self-assigned this
    on Dec 2, 2014
  4. locked as resolved and limited conversation to collaborators on Aug 14, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions