Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sharee (editor role) MOVE a file by file-id into shared sub-folder returns 502 #7617

Open
nabim777 opened this issue Oct 30, 2023 · 2 comments
Labels

Comments

@nabim777
Copy link
Member

nabim777 commented Oct 30, 2023

Describe the bug

When sharee makes API request to move a file from a sub-folder to folder in Shares space , then we get the status code 403 but the share should be able to MOVE the resouce within the shared folder

Steps to reproduce

Steps to reproduce the behavior:

  1. As marie, create a folder folder
  2. As marie creates a sub-folder sub-folder inside folder folder
  3. As marie upload the file file.txt inside folder
  4. As marie, share a folder folder to einstein with permission all
  5. As einstein, move file.txt to sub-folder using curl commands:
curl -kv -XMOVE -ueinstein:relativity 'https://localhost:9200/remote.php/dav/spaces/<file-id>' \
-H 'Destination: https://localhost:9200/remote.php/dav/spaces/<folder-mount-id>/sub-folder/<filename>' | xmllint --format

Expected behavior

The status code 201

Actual behavior

< HTTP/1.1 403 Forbidden
<
<?xml version="1.0" encoding="UTF-8"?>
<d:error
	xmlns:d="DAV"
	xmlns:s="http://sabredav.org/ns">
	<s:exception>Sabre\DAV\Exception\Forbidden</s:exception>
	<s:message>cross storage moves are not permitted, use copy and delete</s:message>
</d:error>
@nabim777 nabim777 changed the title MOVE a file by sharee into same folder returns 502 MOVE a file by sharee into same folder in Share space returns 502 Oct 30, 2023
@saw-jan saw-jan changed the title MOVE a file by sharee into same folder in Share space returns 502 sharee MOVE a file by file-id into same shared folder returns 502 Jan 3, 2024
@saw-jan saw-jan changed the title sharee MOVE a file by file-id into same shared folder returns 502 sharee (editor role) MOVE a file by file-id into same shared folder returns 403 Jan 4, 2024
@saw-jan
Copy link
Member

saw-jan commented Jan 4, 2024

CC @ScharfViktor @micbar

@saw-jan
Copy link
Member

saw-jan commented Aug 5, 2024

Now, it returns 502 but the message is still the same.

curl -XMOVE "https://localhost:9200/dav/spaces/623ed2a4-806e-4bf3-b9be-0fdfec40229a\$b549651d-e1f8-4c30-8351-8396fb18e7b0\!e31cb741-ed30-491e-8e04-541673fb4d62" \
-H"Destination: https://localhost:9200/dav/spaces/a0ca6a90-a365-4782-871e-d44447bbc668\$a0ca6a90-a365-4782-871e-d44447bbc668/myfolder/child/afile.txt" \
-udemo:demo -vk
< HTTP/1.1 502 Bad Gateway
...
<?xml version="1.0" encoding="UTF-8"?>
<d:error xmlns:d="DAV" xmlns:s="http://sabredav.org/ns">
	<s:exception></s:exception>
	<s:message>cross storage moves are not supported, use copy and delete</s:message>
	<s:errorcode></s:errorcode>
</d:error>

@saw-jan saw-jan changed the title sharee (editor role) MOVE a file by file-id into same shared folder returns 403 sharee (editor role) MOVE a file by file-id into shared sub-folder returns 502 Aug 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants