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

Cannot get ocs:share-permissions via WebDAV #1326

Closed
individual-it opened this issue Jan 28, 2020 · 7 comments
Closed

Cannot get ocs:share-permissions via WebDAV #1326

individual-it opened this issue Jan 28, 2020 · 7 comments

Comments

@individual-it
Copy link
Member

request

PROPFIND /remote.php/webdav/home/tmp.txt HTTP/1.1
<?xml version="1.0"?>
<d:propfind xmlns:d="DAV:" xmlns:oc="http://owncloud.org/ns" xmlns:ocs="http://open-collaboration-services.org/ns">
  <d:prop>
    <ocs:share-permissions/>
  </d:prop>
</d:propfind>

response

<?xml version="1.0" encoding="utf-8"?>
<d:multistatus xmlns:d="DAV:" xmlns:s="http://sabredav.org/ns" xmlns:oc="http://owncloud.org/ns">
    <d:response>
        <d:href>/remote.php/webdav/home/tmp.txt</d:href>
        <d:propstat>
            <d:prop></d:prop>
            <d:status>HTTP/1.1 200 OK</d:status>
        </d:propstat>
        <d:propstat>
            <d:prop><http://open-collaboration-services.org/ns:share-permissions></http://open-collaboration-services.org/ns:share-permissions></d:prop>
            <d:status>HTTP/1.1 404 Not Found</d:status>
        </d:propstat>
    </d:response>
</d:multistatus>
@individual-it
Copy link
Member Author

possible related to owncloud/ocis-reva#57

@C0rby C0rby self-assigned this May 28, 2020
@C0rby
Copy link
Contributor

C0rby commented May 28, 2020

I get the following response. Is that the expected one?

> curl -s -u einstein:relativity -X PROPFIND http://localhost:9140/remote.php/webdav/asdf.png | xmllint --format -
<?xml version="1.0" encoding="utf-8"?>
<d:multistatus xmlns:d="DAV:" xmlns:s="http://sabredav.org/ns" xmlns:oc="http://owncloud.org/ns">
  <d:response>
    <d:href>/remote.php/webdav/asdf.png</d:href>
    <d:propstat>
      <d:prop>
        <oc:id>MTI4NGQyMzgtYWE5Mi00MmNlLWJkYzQtMGIwMDAwMDA5MTYyOmVkZWEwZDY4LTdmNWQtNDM3My1hNjRlLTVlMmU5YTUwOTczNg==</oc:id>
        <oc:fileid>MTI4NGQyMzgtYWE5Mi00MmNlLWJkYzQtMGIwMDAwMDA5MTYyOmVkZWEwZDY4LTdmNWQtNDM3My1hNjRlLTVlMmU5YTUwOTczNg==</oc:fileid>
        <d:getetag>"4b4af2a1114f2c33b9ef29299a943518"</d:getetag>
        <oc:permissions>WCKDNVR</oc:permissions>
        <d:getcontentlength>21509</d:getcontentlength>
        <d:getcontenttype>image/png</d:getcontenttype>
        <d:getlastmodified>Thu, 28 May 2020 10:59:52 UTC</d:getlastmodified>
        <oc:favorite>0</oc:favorite>
      </d:prop>
      <d:status>HTTP/1.1 200 OK</d:status>
    </d:propstat>
  </d:response>
</d:multistatus>

@individual-it
Copy link
Member Author

@C0rby that response looks better, need to enable tests and recheck different edge-cases.
QA-team can take care of that next week

@haribhandari07 haribhandari07 self-assigned this Jun 1, 2020
@individual-it
Copy link
Member Author

@C0rby I was wrong this issue is about ocs:share-permissions that field also is not showing up in your request
see also owncloud/core#37477

@individual-it
Copy link
Member Author

tests added in owncloud/core#37477 removing QA-team label

@C0rby
Copy link
Contributor

C0rby commented Jun 15, 2020

Added the attribute to the response in this PR cs3org/reva#836.

I keep this issue open because the attribute is now in the response but the content of the attribute is hardcoded to 5.
In pkg/storage/fs/owncloud/owncloud.go#convertToResourceInfo we need to implement the permissionset properly.

@butonic butonic transferred this issue from owncloud/ocis-reva Jan 18, 2021
@refs refs changed the title cannot get ocs:share-permissions via WebDAV Cannot get ocs:share-permissions via WebDAV Jan 19, 2021
@refs refs unassigned C0rby Jan 19, 2021
@refs
Copy link
Member

refs commented Jan 19, 2021

This has been done with the correct permissionSet PR on reva 👍

@refs refs closed this as completed Jan 19, 2021
@exalate-issue-sync exalate-issue-sync bot reopened this Feb 10, 2021
@settings settings bot removed the p3-medium label Apr 7, 2021
@C0rby C0rby closed this as completed Apr 9, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants