Skip to content
This repository was archived by the owner on Nov 23, 2026. It is now read-only.

Add alias links to web UI - #7133

Merged
kulmann merged 4 commits into
masterfrom
permissionsless-links
Aug 9, 2022
Merged

kulmann merged 4 commits into
masterfrom
permissionsless-links

Conversation

@pascalwengerter

@pascalwengerter pascalwengerter commented Jun 15, 2022 •

Copy link
Copy Markdown
Contributor

Description

Cleaning up my local git stash and came across this draft. Needs concepting how to properly turn this into an oCIS-only feature. Update: alias-link capability has landed in oCIS

Related Issue

@pascalwengerter
pascalwengerter force-pushed the permissionsless-links branch from c02184a to 97f529e Compare June 29, 2022 13:11
@pascalwengerter
pascalwengerter marked this pull request as ready for review June 29, 2022 13:11
@pascalwengerter
pascalwengerter requested a review from fschade as a code owner June 29, 2022 13:11
@pascalwengerter
pascalwengerter requested review from fschade and kulmann and removed request for fschade June 29, 2022 13:12
@pascalwengerter

Copy link
Copy Markdown
Contributor Author

This does now work on the link-creator side, but I run into problems when trying to open the (permissionless) link - I'd expect it to render the login form, but it shows an error page (with a 401 when listing drives)

@pascalwengerter pascalwengerter changed the title Add draft for permissionless/internal/alias-link shares for oCIS Add alias links to web UI Jun 29, 2022
@kulmann
kulmann force-pushed the permissionsless-links branch from 97f529e to 7c33803 Compare July 7, 2022 21:17
@kulmann

kulmann commented Jul 7, 2022

Copy link
Copy Markdown
Contributor

@pascalwengerter I took the liberty of rebasing this PR, as the public link resolving has changed in the web runtime today (see #7072 for reference). However, whenever I want to create an internal link I get invalid permissions from the backend. Can you confirm that?

@pascalwengerter

pascalwengerter commented Jul 14, 2022 •

Copy link
Copy Markdown
Contributor Author

@pascalwengerter I took the liberty of rebasing this PR, as the public link resolving has changed in the web runtime today (see #7072 for reference). However, whenever I want to create an internal link I get invalid permissions from the backend. Can you confirm that?

Did some investigation now and can confirm it doesn't work - I thought we had implemented the necessary changes in the SDK already, but getting an invalid permissions webdav response when trying to sending e.g. a "0" as zero-permission (sending nothing doesn't work because that is the standard behavior when updating links without touching permissions). I've opened an issue in the SDK

@pascalwengerter

Copy link
Copy Markdown
Contributor Author

@pascalwengerter I took the liberty of rebasing this PR, as the public link resolving has changed in the web runtime today (see #7072 for reference). However, whenever I want to create an internal link I get invalid permissions from the backend. Can you confirm that?

Did some investigation now and can confirm it doesn't work - I thought we had implemented the necessary changes in the SDK already, but getting an invalid permissions webdav response when trying to sending e.g. a "0" as zero-permission (sending nothing doesn't work because that is the standard behavior when updating links without touching permissions). I've opened an issue in the SDK

Turns out sending a 0 permission is enough, it does work with cs3org/reva#3079 (stopped CI, this PR needs a rebase & review once Julian's PR is merged in reva and then in oCIS and the oCIS commit ID is bumped)!

@pascalwengerter

Copy link
Copy Markdown
Contributor Author

@pascalwengerter I took the liberty of rebasing this PR, as the public link resolving has changed in the web runtime today (see #7072 for reference). However, whenever I want to create an internal link I get invalid permissions from the backend. Can you confirm that?

Did some investigation now and can confirm it doesn't work - I thought we had implemented the necessary changes in the SDK already, but getting an invalid permissions webdav response when trying to sending e.g. a "0" as zero-permission (sending nothing doesn't work because that is the standard behavior when updating links without touching permissions). I've opened an issue in the SDK

Turns out sending a 0 permission is enough, it does work with cs3org/reva#3079 (stopped CI, this PR needs a rebase & review once Julian's PR is merged in reva and then in oCIS and the oCIS commit ID is bumped)!

Ideally we also get an E2E test for alias links in oCIS to make sure they don't break unnoticed in the near future

@kulmann
kulmann force-pushed the permissionsless-links branch from 1c22ebd to 261e462 Compare July 21, 2022 09:44
@kulmann

kulmann commented Jul 21, 2022

Copy link
Copy Markdown
Contributor

This PR handles creating internal / permissionless links, that works with updated ocis/reva as you mentioned. Respective commit id has been bumped in web already, so a rebase was sufficient. But: resolving an internal link is not handled in the public link resolve page. I'd like to merge this PR but flip the default of the capability to internal links being disabled, until we implement resolving internal links in a separate PR. Do you agree @pascalwengerter ?

@pascalwengerter

Copy link
Copy Markdown
Contributor Author

This PR handles creating internal / permissionless links, that works with updated ocis/reva as you mentioned. Respective commit id has been bumped in web already, so a rebase was sufficient. But: resolving an internal link is not handled in the public link resolve page. I'd like to merge this PR but flip the default of the capability to internal links being disabled, until we implement resolving internal links in a separate PR. Do you agree @pascalwengerter ?

Please do push to this PR as you deem necessary, I don't have any preference on how to proceed here ;)

@JammingBen

Copy link
Copy Markdown
Contributor

I rebased and updated the PR to go along with current master. No idea why the condition coverage does not cover availableRoleOptions() though. Locally, the tests call this method and reach the updated return statement 🤷

Besides that, this should be ready for review. LGTM to me, although I'm not too invested in the topic.

@kulmann kulmann left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Some nitpicks (see comments). Also: please update the ocis commit id in .drone.env to one after the alias capability value has changed in ocis.

@JammingBen
JammingBen requested a review from kulmann August 3, 2022 11:50
@JammingBen

JammingBen commented Aug 3, 2022 •

Copy link
Copy Markdown
Contributor

Arghs I forgot the .drone.env, coming up next. Edit: Done.

@kulmann
kulmann force-pushed the permissionsless-links branch from d9eb76b to 7743ee2 Compare August 9, 2022 07:41
@kulmann
kulmann force-pushed the permissionsless-links branch from 7743ee2 to 551cde7 Compare August 9, 2022 07:52
@kulmann
kulmann force-pushed the permissionsless-links branch from 551cde7 to f3a1f64 Compare August 9, 2022 08:00
@sonarqubecloud

sonarqubecloud Bot commented Aug 9, 2022

Copy link
Copy Markdown

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

65.5% 65.5% Coverage
0.0% 0.0% Duplication

@kulmann
kulmann merged commit 38fb08c into master Aug 9, 2022
@delete-merged-branch
delete-merged-branch Bot deleted the permissionsless-links branch August 9, 2022 14:52
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants