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

deleting the last manager of a space results in space that cannot be managed #6433

Closed
individual-it opened this issue Jun 2, 2023 · 3 comments
Labels

Comments

@individual-it
Copy link
Member

Describe the bug

When the last user is deleted who has the permission "can manage" of a space, the space cannot be managed by anyone and no new user can receive that permission

Steps to reproduce

Steps to reproduce the behavior:

  1. as admin create two users "brian" & "carol"
  2. make "brian" space-admin
  3. as brian create a space called "finance" and one called "management"
  4. as brian add carol to the space "finance" with the permissions "can view"
  5. as brian add carol to the space "management" with the permissions "can manage"
  6. as carol check that you have access to both spaces
  7. as admin delete the user "brian"
  8. as admin check the spaces in the "administration" settings

Expected behavior

  1. the deleted user should not be included in the count of users in the space list
  2. the deleted users should not be shown anymore in the space list
  3. there should be some way to add a new space-admin to the space

Actual behavior

  1. after deleting of "brian" both shares still are shown to have 2 users and show one ghost-user
    image
    image
    image
  2. there is no way to add a new manager of that space after the last one is deleted
{
	"value": [
		{
			"driveAlias": "project/finance",
			"driveType": "project",
			"id": "c58e0760-0fe2-4255-bfab-52799020c0cb$20d2e739-1ad4-4785-9e72-9891f9cec499",
			"lastModifiedDateTime": "2023-06-02T11:46:55.932096014+05:45",
			"name": "finance",
			"owner": {
				"user": {
					"displayName": "",
					"id": "20d2e739-1ad4-4785-9e72-9891f9cec499"
				}
			},
			"quota": {
				"remaining": 999999954,
				"state": "normal",
				"total": 1000000000,
				"used": 46
			},
			"root": {
				"eTag": "\"102944b089b54328bbf37d7dc472ffdf\"",
				"id": "c58e0760-0fe2-4255-bfab-52799020c0cb$20d2e739-1ad4-4785-9e72-9891f9cec499",
				"permissions": [
					{
						"grantedToIdentities": [
							{
								"user": {
									"displayName": "",
									"id": "7ec9a663-d5f1-4a03-83a5-5166e71dd7d3"
								}
							}
						],
						"roles": [
							"manager"
						]
					},
					{
						"grantedToIdentities": [
							{
								"user": {
									"displayName": "",
									"id": "c969056d-a4f2-4343-b13d-ad4e87e643ef"
								}
							}
						],
						"roles": [
							"viewer"
						]
					}
				],
				"webDavUrl": "https://192.168.0.25:9200/dav/spaces/c58e0760-0fe2-4255-bfab-52799020c0cb$20d2e739-1ad4-4785-9e72-9891f9cec499"
			},
			"webUrl": "https://192.168.0.25:9200/f/c58e0760-0fe2-4255-bfab-52799020c0cb$20d2e739-1ad4-4785-9e72-9891f9cec499"
		},
		{
			"driveAlias": "project/management",
			"driveType": "project",
			"id": "c58e0760-0fe2-4255-bfab-52799020c0cb$2320ec0b-4da9-4fe6-810f-88c97a13b0aa",
			"lastModifiedDateTime": "2023-06-02T11:47:36.561399967+05:45",
			"name": "management",
			"owner": {
				"user": {
					"displayName": "",
					"id": "2320ec0b-4da9-4fe6-810f-88c97a13b0aa"
				}
			},
			"quota": {
				"remaining": 999999954,
				"state": "normal",
				"total": 1000000000,
				"used": 46
			},
			"root": {
				"eTag": "\"f7518e5aa5d25a681d53e06a200fed9d\"",
				"id": "c58e0760-0fe2-4255-bfab-52799020c0cb$2320ec0b-4da9-4fe6-810f-88c97a13b0aa",
				"permissions": [
					{
						"grantedToIdentities": [
							{
								"user": {
									"displayName": "",
									"id": "7ec9a663-d5f1-4a03-83a5-5166e71dd7d3"
								}
							}
						],
						"roles": [
							"manager"
						]
					},
					{
						"grantedToIdentities": [
							{
								"user": {
									"displayName": "",
									"id": "c969056d-a4f2-4343-b13d-ad4e87e643ef"
								}
							}
						],
						"roles": [
							"manager"
						]
					}
				],
				"webDavUrl": "https://192.168.0.25:9200/dav/spaces/c58e0760-0fe2-4255-bfab-52799020c0cb$2320ec0b-4da9-4fe6-810f-88c97a13b0aa"
			},
			"webUrl": "https://192.168.0.25:9200/f/c58e0760-0fe2-4255-bfab-52799020c0cb$2320ec0b-4da9-4fe6-810f-88c97a13b0aa"
		}
	]
}

Setup

Please describe how you started the server and provide a list of relevant environment variables or configuration files.

OCIS_URL=https://192.168.0.25:9200 ~/Downloads/ocis-3.0.0-rc.4-linux-amd64 server

@micbar
Copy link
Contributor

micbar commented Jun 2, 2023

known issue, see #5967

@micbar micbar closed this as completed Jun 2, 2023
@individual-it
Copy link
Member Author

@micbar what about the fact that the deleted user is still shown in the permissions and also "shown" in the UI as an empty avatar or empty string?

@micbar
Copy link
Contributor

micbar commented Jun 2, 2023

also known and accepted :-)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants