Fix create share API permissions for links#29143
Conversation
I mean, that seems logical, no? |
|
@skjnldsv Hmmm the minimum yes, but there it's forced to |
|
Can you give more details about the issue you faced? |
|
@skjnldsv Sorry for the lack of details. When creating a share link for a file (publicUpload is false) by calling Afterwards, you can still edit the share link and set the permissions you want with For example, one cannot allow edition when creating a share link on a file. This can be useful when creating a share link for a markdown file. |
this is the issue then, it needs to be limited to the three options we support ? |
87219fe to
e2a7e6b
Compare
…ys use defaults Signed-off-by: Julien Veyssier <eneiluj@posteo.net>
e2a7e6b to
0f87e0a
Compare
|
@skjnldsv Here is a cleaner approach: When creating a public link (with
I might be wrong but I think the limitation is already applied earlier in this method: https://github.com/nextcloud/server/blob/master/apps/files_sharing/lib/Controller/ShareAPIController.php#L504-L508 |
Signed-off-by: Julien Veyssier <eneiluj@posteo.net>
|
What's the status? Is this still needed @julien-nc ? |
|
no activity, closing |
When
publicUploadis false:settings/admin/sharing)permissionsrequest parameterare ignored.
PERMISSION_READis always set.The createShare api method still has some permission issues with
publicUpload(#17504) and it's still impossible to create a share without expiration date if a default one is defined (#10178). But these issues are a bit trickier to fix.