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

Link permissions #20846

Merged
merged 3 commits into from
May 18, 2020
Merged

Link permissions #20846

merged 3 commits into from
May 18, 2020

Conversation

rullzer
Copy link
Member

@rullzer rullzer commented May 6, 2020

Follow up to #20726

Turns out we do need the permission in the DB. Else the federated code still chokes as it doesn't use the API.

Also updated the tests to reflect the new situation.

@rullzer rullzer added this to the Nextcloud 19 milestone May 6, 2020
@rullzer rullzer mentioned this pull request May 6, 2020
3 tasks
@rullzer rullzer modified the milestones: Nextcloud 19, Nextcloud 20 May 6, 2020
@rullzer
Copy link
Member Author

rullzer commented May 6, 2020

/backport to stable19

@@ -511,6 +502,11 @@ public function createShare(
$permissions = Constants::PERMISSION_READ;
}

// TODO: It might make sense to have a dedicated setting to allow/deny converting link shares into federated ones
if (($permissions & Constants::PERMISSION_READ)$this->shareManager->outgoingServer2ServerSharesAllowed()) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

typo?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes

@skjnldsv
Copy link
Member

skjnldsv commented May 6, 2020

It still doesn't change the issue about the front end then.
What does the federation uses then? If not the api?

@skjnldsv
Copy link
Member

skjnldsv commented May 6, 2020

It still doesn't change the issue about the front end then.

Ah, actually it might 🤔

@rullzer
Copy link
Member Author

rullzer commented May 6, 2020

It still doesn't change the issue about the front end then.

Ah, actually it might thinking

Not really. But the feeration part that we use instally to check this uses the ShareManager. Basically this fix is not pretty. But it makes the state consistent. The hack for the frontend stays in place for now. It is not ideal I know.

@MorrisJobke
Copy link
Member

Failing tests 🙈

rullzer and others added 3 commits May 15, 2020 08:18
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
Signed-off-by: Julius Härtl <jus@bitgrid.net>
@juliushaertl
Copy link
Member

Rebased and pushed a fix for the failing test as well.

@juliushaertl juliushaertl added 4. to release Ready to be released and/or waiting for tests to finish and removed 3. to review Waiting for reviews labels May 18, 2020
@MorrisJobke MorrisJobke merged commit ca276a9 into master May 18, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
4. to release Ready to be released and/or waiting for tests to finish bug feature: sharing
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants