Skip to content

Group deletion should delete shares #26632

Done

Description

@dominikmebs

How to use GitHub

  • Please use the 👍 reaction to show that you are affected by the same issue.
  • Please don't comment if you have no relevant information to add. It's just extra noise for everyone subscribed to this issue.
  • Subscribe to receive notifications on status change and new comments.

Steps to reproduce

  1. create a folder "test"
  2. create a group "test"
  3. share folder "test" with group "test"
  4. delete group test

Expected behaviour

delete shares of group if group get deleted.
if later same group name get created again (maybe with other members) it will automatically have all the shares from the past
(this is also a "security" topic)

Server configuration

Nextcloud version: 21.0.1

Activity

  1. added
    0. Needs triage
    on Apr 19, 2021
  2. solracsf commented on Apr 20, 2021

    @solracsf
    Member

    if later same group name get created again (maybe with other members) it will automatically have all the shares from the past
    (this is also a "security" topic)

    Have you reproduced this?

  3. szaimen commented on Jul 2, 2021

    @szaimen
    Contributor

    cc @nextcloud/security

  4. nickvergessen commented on Jul 2, 2021

    @nickvergessen
    Member

    Should listen to one of those events and clear all shares, yeah:

    if ($result) {
    $this->dispatcher->dispatch(IGroup::class . '::postDelete', new GenericEvent($this));
    if ($this->emitter) {
    $this->emitter->emit('\OC\Group', 'postDelete', [$this]);
    }
    }

  5. added
    1. to develop
    and removed
    0. Needs triage
    on Jul 2, 2021
  6. szaimen commented on Jan 23, 2023

    @szaimen
  7. added
    0. Needs triage
    and removed
    1. to develop
    on Jan 23, 2023
  8. 4 remaining items

  9. ChairBorn commented on Sep 6, 2024

    @ChairBorn

    Hey, @joshtrichards, @szaimen, I am looking to contribute, if available, can you assign it to me?

  10. changed the title [-]group deletion not delete shares[/-] [+]Group deletion should delete shares[/+] on Mar 27, 2025
  11. skjnldsv commented on Apr 25, 2025

    @skjnldsv
    Member

    @ChairBorn any news? :)

  12. ChairBorn commented on Apr 25, 2025

    @ChairBorn

    I just saw the assignment, my bad, if you want me to still look at it, I can do it right now

  13. susnux commented on Nov 30, 2026

    @susnux
    Contributor

    Thanks for reporting this. Shares to a group are now removed when the group is deleted, so recreating a group with the same name no longer brings the old shares back. This was fixed in #51000, which shipped in Nextcloud 32 and was backported to 31.0.1 and 30.0.7, together with an integration test for this exact scenario.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

1. to develop26-feedbackbugfeature: sharingfeature: users and groupsgood first issue

Type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions