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

[Bug] Guests are displayed as "Users" #5634

Closed
tbsbdr opened this issue Aug 5, 2021 · 9 comments · Fixed by #6813
Closed

[Bug] Guests are displayed as "Users" #5634

tbsbdr opened this issue Aug 5, 2021 · 9 comments · Fixed by #6813
Assignees
Labels
Priority:p2-high Escalation, on top of current planning, release blocker Type:Bug Something isn't working

Comments

@tbsbdr
Copy link

tbsbdr commented Aug 5, 2021

Steps to reproduce

  1. OC10.8: login to classic ui
  2. share a file with a guest (enter an email)
  3. switch to Web UI
  4. select the same, shared file and open "People" section the sidebar
  5. guest share with email gets displayed as "User" share (which is wrong, its a guest)

image

Expected behaviour

Display "Guest" for guest shares

Actual behaviour

Guest shares are displayed as "User" shares

Background

  • The Web UI relys on the share-type of oc10
  • oC10 provides sharetype = 0 for guest shares which we won't change any more (sharetype 0 = user; sharetype 4 = guest)
  • @kulmann mentioned that there should be a flag llike "isGuest" which we could use to display the right role in WebUI+oC10
@tbsbdr tbsbdr added the Type:Bug Something isn't working label Aug 5, 2021
@kulmann kulmann added the Priority:p2-high Escalation, on top of current planning, release blocker label Dec 3, 2021
@tbsbdr
Copy link
Author

tbsbdr commented Dec 23, 2021

@janackermann do you maybe have an idea how to distinguish guests from users? @kulmann mentioned some flag or tag "isguest" do you maybe know more?

OCS api doesnt know about guests:

The share’s type. This can be one of:

- 0 = user
- 1 = group
- 3 = public link
- 6 = federated cloud share

https://doc.owncloud.com/server/next/developer_manual/core/apis/ocs-share-api.html

@AlexAndBear
Copy link
Contributor

AlexAndBear commented Dec 23, 2021

@tbsbdr we only know this by config flag in oc_preferences. We can update the API

@kulmann
Copy link
Contributor

kulmann commented Dec 23, 2021

In oc10 you can do $config->getUserValue($uid, 'owncloud', 'isGuest', false); with $config being the systems IConfig, to determine in the php code if a user is a guest user. The classic UI is utilizing that information. To my knowledge there is no API that makes this information available. Best would be to use the proper guest share type in OCS responses. 😞 but I don't know the implications of such a change.

@AlexAndBear
Copy link
Contributor

@kulmann With ownCloud 10.7 I implemented user types that are user or guest.
We can emit this information via the share API, for example by adding a new field called <share_with_user_type/>

I think breaking changes to the share api are not favorable.

@AlexAndBear
Copy link
Contributor

image

@kulmann
Copy link
Contributor

kulmann commented Apr 25, 2022

discussed in a call, that the share_with_user_type prop can be utilized inside our sdk to rewrite the share type to 4 (guest) for user shares with user type guest. sdk as our API abstraction layer is the perfect place for that. This will resolve showing existing guest shares as guest instead of user. 👍

@AlexAndBear
Copy link
Contributor

Oc10 Backend part: owncloud/core#40013

@AlexAndBear
Copy link
Contributor

SDK part: owncloud/owncloud-sdk#1046

@AlexAndBear AlexAndBear self-assigned this Apr 26, 2022
@AlexAndBear
Copy link
Contributor

Frontend part: #6813

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Priority:p2-high Escalation, on top of current planning, release blocker Type:Bug Something isn't working
Projects
No open projects
Status: Done
Development

Successfully merging a pull request may close this issue.

3 participants