Repository navigation
Closed
Description
Describe the bug
RemoteItemId doesn't match with shared resource id of share drive propfind
Steps to reproduce
einsteinuser share foldersharedWithAdminadminuser sends listShareWithMe api request
curl -XGET -uadmin:admin https://localhost:9200/graph/v1beta1/me/drive/sharedWithMe
{
"value": [
{
"@UI.Hidden": false,
"@client.synchronize": false,
"createdBy": {
"user": {
"displayName": "Albert Einstein",
"id": "4c510ada-c86b-4815-8820-42cdf82c3d51"
}
},
"eTag": "\"e1814f22a63e241cfc523befa7a82e07\"",
"folder": {},
"id": "a0ca6a90-a365-4782-871e-d44447bbc668$a0ca6a90-a365-4782-871e-d44447bbc668!fd0ef83b-87d2-436d-8951-24dc7f57dc29:4c510ada-c86b-4815-8820-42cdf82c3d51:119ffb99-c559-4bad-acc0-b406d6c9a396",
"lastModifiedDateTime": "2024-02-09T14:25:40.436634666+05:45",
"name": "sharedWithAdmin",
"parentReference": {
"driveId": "a0ca6a90-a365-4782-871e-d44447bbc668$a0ca6a90-a365-4782-871e-d44447bbc668",
"driveType": "virtual",
"id": "a0ca6a90-a365-4782-871e-d44447bbc668$a0ca6a90-a365-4782-871e-d44447bbc668!a0ca6a90-a365-4782-871e-d44447bbc668"
},
"remoteItem": {
"createdBy": {
"user": {
"displayName": "Albert Einstein",
"id": "4c510ada-c86b-4815-8820-42cdf82c3d51"
}
},
"eTag": "\"e1814f22a63e241cfc523befa7a82e07\"",
"folder": {},
"id": "fd0ef83b-87d2-436d-8951-24dc7f57dc29$4c510ada-c86b-4815-8820-42cdf82c3d51!119ffb99-c559-4bad-acc0-b406d6c9a396",
"lastModifiedDateTime": "2024-02-09T14:25:40.436634666+05:45",
"name": "sharedWithAdmin",
"parentReference": {
"driveId": "fd0ef83b-87d2-436d-8951-24dc7f57dc29$4c510ada-c86b-4815-8820-42cdf82c3d51!4c510ada-c86b-4815-8820-42cdf82c3d51",
"driveType": "personal"
},
"permissions": [
{
"grantedToV2": {
"user": {
"displayName": "Admin",
"id": "7fe42e72-47b7-479e-b053-640db050593e"
}
},
"id": "fd0ef83b-87d2-436d-8951-24dc7f57dc29:4c510ada-c86b-4815-8820-42cdf82c3d51:51191bbe-9b8f-4d70-91ae-7abfa3c9d59b",
"invitation": {
"invitedBy": {
"user": {
"displayName": "Albert Einstein",
"id": "4c510ada-c86b-4815-8820-42cdf82c3d51"
}
}
},
"roles": [
"fb6c3e19-e378-47e5-b277-9732f9de6e21"
]
}
]
}
}
]
}
adminuser send propfind request on share drive
curl -XPROPFIND -uadmin:admin https://localhost:9200/dav/spaces/a0ca6a90-a365-4782-871e-d44447bbc668$a0ca6a90-a365-4782-871e-d44447bbc668
Response
<d:multistatus xmlns:s="http://sabredav.org/ns" xmlns:d="DAV:" xmlns:oc="http://owncloud.org/ns">
......
<d:response>
<d:href>/dav/spaces/a0ca6a90-a365-4782-871e-d44447bbc668$a0ca6a90-a365-4782-871e-d44447bbc668/sharedWithAdmin/</d:href>
<d:propstat>
<d:prop>
<oc:id>a0ca6a90-a365-4782-871e-d44447bbc668$a0ca6a90-a365-4782-871e-d44447bbc668!fd0ef83b-87d2-436d-8951-24dc7f57dc29:4c510ada-c86b-4815-8820-42cdf82c3d51:51191bbe-9b8f-4d70-91ae-7abfa3c9d59b</oc:id>
<oc:fileid>a0ca6a90-a365-4782-871e-d44447bbc668$a0ca6a90-a365-4782-871e-d44447bbc668!fd0ef83b-87d2-436d-8951-24dc7f57dc29:4c510ada-c86b-4815-8820-42cdf82c3d51:51191bbe-9b8f-4d70-91ae-7abfa3c9d59b</oc:fileid>
<oc:spaceid>a0ca6a90-a365-4782-871e-d44447bbc668$a0ca6a90-a365-4782-871e-d44447bbc668</oc:spaceid>
<oc:file-parent>fd0ef83b-87d2-436d-8951-24dc7f57dc29$4c510ada-c86b-4815-8820-42cdf82c3d51!4c510ada-c86b-4815-8820-42cdf82c3d51</oc:file-parent>
<oc:shareid></oc:shareid>
<oc:name>sharedWithAdmin</oc:name>
<d:displayname>sharedWithAdmin</d:displayname>
<d:getetag>"e1814f22a63e241cfc523befa7a82e07"</d:getetag>
<oc:permissions>SRDNVCK</oc:permissions>
<d:resourcetype>
<d:collection/>
</d:resourcetype>
<oc:size>0</oc:size>
<d:getlastmodified>Fri, 09 Feb 2024 08:40:40 GMT</d:getlastmodified>
<oc:tags></oc:tags>
<oc:favorite>0</oc:favorite>
</d:prop>
<d:status>HTTP/1.1 200 OK</d:status>
</d:propstat>
<d:propstat>
<d:prop>
<oc:audio></oc:audio>
<oc:location></oc:location>
</d:prop>
<d:status>HTTP/1.1 404 Not Found</d:status>
</d:propstat>
</d:response>
</d:multistatus>
Expected behavior
RemoteItemId should match with shared item id from propfind
Actual behavior
shared item id during propfind is different than listsharedWithme request
<oc:id>a0ca6a90-a365-4782-871e-d44447bbc668$a0ca6a90-a365-4782-871e-d44447bbc668!fd0ef83b-87d2-436d-8951-24dc7f57dc29:4c510ada-c86b-4815-8820-42cdf82c3d51:51191bbe-9b8f-4d70-91ae-7abfa3c9d59b</oc:id>
doesn't matches with
"remoteItem": {
......
"id": "fd0ef83b-87d2-436d-8951-24dc7f57dc29$4c510ada-c86b-4815-8820-42cdf82c3d51!119ffb99-c559-4bad-acc0-b406d6c9a396",
}
...
Setup
Please describe how you started the server and provide a list of relevant environment variables or configuration files.
Details
OCIS_XXX=5.1.0-prealpha+5f57740976
OCIS_YYY=somevalue
PROXY_XXX=somevalueNeed Clarification
- DriveItemId , PermissionId and RemoteItemId on listShareWithMe response?
- Is DriveItemId, share-id or not?
- Is permissionId, shared-resource-id or share-id?
- Is RemoteItemId, shared-resource-id or resource-id ?
Metadata
Metadata
Assignees
Labels
Type
Projects
- StatusShow more project fieldsDone
Activity
rhafer commentedon Feb 14, 2024
It's not the
share-id. The driveItemId does currently have the resourceId of the shared resource encoded into it. But clients should never rely on that.The
permissionIdis theshareidThe
idof theremoteItemis theresourceIdof the shared resource.rhafer commentedon Feb 15, 2024
Once we have the fix for #8080 (cs3org/reva#4517) merged and bumped in to ocis. We can adjust the sharedWithMe endpoint to return the same ids on the driveItems that are also returned by the PROPFIND on the sharejail root. 🤞
[wip] Align driveItem its of sharedWithMe response with propfind
fix(sharing-ng): align sharedWithMe driveItem IDs
fix(sharing-ng): align sharedWithMe driveItem IDs
[-]RemoteItemId from listSharedWithMe doesn't match with shared resource id[/-][+]DriveItemId from listSharedWithMe doesn't match with shared resource id[/+][-]DriveItemId from listSharedWithMe doesn't match with shared resource id[/-][+]DriveItem ID from listSharedWithMe doesn't match with shared resource id[/+]fix(sharing-ng): align sharedWithMe driveItem IDs
fix(sharing-ng): align sharedWithMe driveItem IDs
fix(sharing-ng): align sharedWithMe driveItem IDs
[full-ci] fix(sharing-ng): align sharedWithMe driveItem IDs with PROP…
[full-ci] fix(sharing-ng): align sharedWithMe driveItem IDs with PROP…