nextcloud / nextcloud/server

[Bug]: Meaning and default of `hide_disabled_user_shares` was changed and functionality lost

Open
#63,159 3 comments 1 reaction 1 assignee View on GitHub

@provokateurin is already working on this.

Since Aug 19, 2026.

0. Needs triage 34-feedback bug
Dominant language
PHP
Stars
36.9k
Forks
5.2k
Avg merge
2d 3h
Merged PRs (30d)
713

Description

⚠️ This issue respects the following points: ⚠️
Bug description

Prior to nextcloud 34.0.2, shared files of disabled users were blocked for external access (links etc.), but would still be allowed to be accessed by internal users. So if a person left the organization, all shares sent to third parties stopped working, but colleagues could still access internal folders. In case internal access wasn't wanted, hide_disabled_user_shares could be set to yes. So the two options were Internal access only and no access to files shared by disabled users.

In https://github.com/nextcloud/server/pull/62092 this behavior was changed: Now all access is blocked by default (internal and external). In order to grant access to these files, hide_disabled_user_shares can be set to no, but this also enables external access (e.g., via link). So now the two options are no access and internal_and_exeternal_access. There is no option to replicate the previous default. Also, documentation wasn't adapted.

In practice this means that after upgrading nextcloud many users see files/folders disappear and the only way to quickly restore their access is to also allow access for external users via links.

Steps to reproduce
  1. Install Nextcloud 34.0.1
  2. Share a file internally and externally
  3. Disable the account sharing the file
  4. Check the shared file still visible internally
  5. Check the shared file not accessible externally
  6. Upgrade to Nextcloud 34.0.2
  7. See the shared file not visible internally anymore
  8. Change config: ./occ config:app:set files_sharing hide_disabled_user_shares --value no
  9. Check the shared file visible internally again
  10. Check the external link accessible
Expected behavior

Restore the previous meaning and default of hide_disabled_user_shares, so things won't break on upgrade.

Introduce a new configuration setting hide_disabled_user_external_shares which defaults to yes. This accomplishes the goal of #62092 without breaking access on upgrade and maintain the ability to keep internal shares working while blocking external shares (which was and IMHO is a reasonable default in terms of balancing security and functionality). Adapt documentation.

Nextcloud Server version

34

Operating system

Other

PHP engine version

PHP 8.3

Web server

Nginx

Database engine version

MariaDB

Is this bug present after an update or on a fresh install?

Updated from a MINOR version (ex. 32.0.1 to 32.0.2)

Are you using the Nextcloud Server Encryption module?

None

What user-backends are you using?
  • Default user-backend (database)
  • LDAP/ Active Directory
  • SSO - SAML
  • Other
Configuration report

List of activated Apps

Nextcloud Signing status

Nextcloud Logs

Additional info

This affects multiple versions of Nextcloud, as it was backported to 34, 33, 32, 31 and 30.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.