Repository navigation
fix: show federated users in the share dialog when local users also match - #41814
Merged
Merged
Conversation
…atch The share dialog only appended federated sharees when the search returned no local users and no local groups, so a single local match hid every federated result - including exact federated cloud id matches. Searching for a name stem shared by local accounts therefore made federated users unreachable unless the full cloud id was typed. That filtering existed to hide a suggestion generated by the server: a search term containing an "@" was always offered as a federated cloud id, even when it was the email address of an existing local account. Suppress that guess at its source instead - it is now skipped whenever the search matched a local user or group exactly - and let the share dialog show all federated results again. The previous backend guard only dropped the guess when the domain part was one of the instance's trusted_domains, which is rarely the case for user email addresses, so isInstanceDomain() is no longer needed. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
phil-davis
approved these changes
Sep 7, 2026
oc-tmueller
added a commit
that referenced
this pull request
Sep 25, 2026
Bump version.php to 10.16.5 and materialize the changelog fragments for this release. $OC_Version becomes [10, 16, 5, 0]: the 4th digit is the internal DB-upgrade patch level, not the public patch number, and nothing in this release needs it moved. The 11 fragments in changelog/unreleased/ move into changelog/10.16.5_2026-09-25/ (git mv, so the renames stay tracked) and CHANGELOG.md is regenerated with calens. unreleased/ keeps its .gitkeep and is now empty, ready for the next cycle. Security: - #41784 update PHP dependencies to close published advisories - #41803 prevent path traversal via appconfig public_/remote_ keys - #41827 reject SVG/script content before it reaches ImageMagick bitmap previews - #41834 pin the Imagick coder for each preview provider Bugfixes: - #41782 restore index usage for filecache writes on Oracle - #41808 avoid a deprecation notice when hashing the file cache path on Oracle - #41814 show federated users in the share dialog when local users also match - #41819 speed up Oracle schema introspection - #41835 release the file handle when a bitmap preview cannot be decoded - #41855 report a preview file that cannot be opened without logging noise Changes: - #41788 update PHP dependencies Same shape as 852062d ("feat: release 10.16.4"), which did the changelog and the version bump in one commit. Once merged, v10.16.5 gets tagged on the merged commit and the release bundles are built and published from owncloud/server-release. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Signed-off-by: Thomas Müller <323649642+oc-tmueller@users.noreply.github.com>
oc-tmueller
added a commit
that referenced
this pull request
Sep 25, 2026
* feat: release 10.16.5 Bump version.php to 10.16.5 and materialize the changelog fragments for this release. $OC_Version becomes [10, 16, 5, 0]: the 4th digit is the internal DB-upgrade patch level, not the public patch number, and nothing in this release needs it moved. The 11 fragments in changelog/unreleased/ move into changelog/10.16.5_2026-09-25/ (git mv, so the renames stay tracked) and CHANGELOG.md is regenerated with calens. unreleased/ keeps its .gitkeep and is now empty, ready for the next cycle. Security: - #41784 update PHP dependencies to close published advisories - #41803 prevent path traversal via appconfig public_/remote_ keys - #41827 reject SVG/script content before it reaches ImageMagick bitmap previews - #41834 pin the Imagick coder for each preview provider Bugfixes: - #41782 restore index usage for filecache writes on Oracle - #41808 avoid a deprecation notice when hashing the file cache path on Oracle - #41814 show federated users in the share dialog when local users also match - #41819 speed up Oracle schema introspection - #41835 release the file handle when a bitmap preview cannot be decoded - #41855 report a preview file that cannot be opened without logging noise Changes: - #41788 update PHP dependencies Same shape as 852062d ("feat: release 10.16.4"), which did the changelog and the version bump in one commit. Once merged, v10.16.5 gets tagged on the merged commit and the release bundles are built and published from owncloud/server-release. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Signed-off-by: Thomas Müller <323649642+oc-tmueller@users.noreply.github.com> * fix: correct three defects in the 10.16.5 release notes Found reviewing the release commit, all three in text that ships inside the tarball, so this is the last point at which they are free to fix. **Six updated dependencies were unnamed.** Diffing composer.lock at v10.16.4 against this branch gives 17 changed production packages; the entry listed 11. Missing: sabre/dav (4.7.0 to 4.7.1), sabre/event (5.1.7 to 5.1.9), sabre/vobject (4.5.8 to 4.6.1), pimple/pimple (v3.6.1 to v3.6.2), nikic/php-parser (v5.7.0 to v5.9.0) and dg/composer-cleaner (v2.2.1 to v2.2.2). All but sabre/event are direct entries in composer.json's require, and sabre/vobject is a minor bump of the vCard/iCalendar parser behind CalDAV and CardDAV — an administrator auditing what moved in that stack for 10.16.5 would have seen nothing. Five of the six came from #41787, whose URL was missing from the entry as well; nikic/php-parser then went on to v5.9.0 in #41830, which was already listed. Earlier releases on this branch do list sabre bumps here (10.10.0, 10.11.0, 10.12.0), so the omission also broke the house convention. **Two entries linked a pull request that never reached this branch.** #41819 was merged into ci/oracle-db-in-github-actions-10.16, an intermediate branch that no longer exists on the remote; the change reached 10.16 through #41815 (9408736). Likewise the 41835 entry cited only master's #41835, while the 10.16 delivery was #41837 (6443822). Both now cite the 10.16 pull request first, matching what 41827, 41834 and 41855 already do with #41863 — so calens also makes the branch's own pull request the primary link. CHANGELOG.md is regenerated with calens and, as on the rest of this branch, written without a trailing newline: `ocrelease changelog` captures calens' stdout through execa, which strips it, and every released section on 10.16 was produced that way. Adding one here would only create churn at the next release. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Signed-off-by: Thomas Müller <323649642+oc-tmueller@users.noreply.github.com> * chore: fold the federated address book sync fix into the 10.16.5 release notes Its fix merged into 10.16 after the release notes were first prepared, so its changelog fragment was still sitting in changelog/unreleased and would have been deferred to the next release while the fix itself shipped in this one. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Signed-off-by: Thomas Müller <323649642+oc-tmueller@users.noreply.github.com> --------- Signed-off-by: Thomas Müller <323649642+oc-tmueller@users.noreply.github.com> Co-authored-by: Thomas Müller <323649642+oc-tmueller@users.noreply.github.com> Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
10.16 backport of #41807.
Description
The share dialog only appended federated sharees when the search returned no local users and no local groups:
A single local match - including a partial one - therefore hid every federated result, exact federated cloud id matches included. If a federated user's name shares a stem with any local account (e.g. federated
Kamp,Andreaon one instance, localBouwkampandHaverkampon the other), the federated user becomes unreachable from the share dialog unless the full cloud id is typed.Root cause
That frontend filter was introduced in #38389 to hide a suggestion the server generates:
ShareesController::getRemote()offers the raw search term as a federated cloud id whenever it merely contains an@, so typing the email address of an existing local account produced a bogus federated suggestion next to the real one.The backend already tried to guard against this, but only dropped the guess when the address' domain part was listed in
trusted_domains. For a typical deployment (mail@company.com, instancecloud.company.com) that never matches, which is why the far broader frontend filter was reached for.Fix
Suppress the speculative entry at its source:
getRemote()now skips it whenever the search term already matched a local user or group exactly - the local account wins. With the noise gone, the share dialog can append federated results unconditionally again.Note this only affects the generated guess (the sole remote entry that carries no
value.server); federated contacts found in the address book and remotes returned by asharing.remoteShareesSearchplugin are unaffected.isInstanceDomain()has no remaining callers and is removed.Behaviour change
ShareesTestcase #15 is inverted deliberately: an exact local user now wins even when the email domain is not a trusted domain.Tests
apps/files_sharing/tests/API/ShareesTest.php: case use post to delete files, get has a limit and fails with many files #15 updated; new cases for an exact local group suppressing the guess, and for an address-book federated contact surviving alongside an exact local user.core/js/tests/specs/sharedialogviewSpec.js: two specs covering a federated sharee alongside partially matching local users, and an exact federated match alongside a matching local group. Both fail without the change incore/js/sharedialogview.js.Verified locally on this branch:
ShareesTest333 tests / 875 assertions green on PHP 7.4; the share dialog karma spec passed 40/41 (1 pre-existing skip) on the master branch, where these two files are byte-identical.The diff is identical to #41807 apart from one pre-existing line - 10.16 has
\strtolower($user->getEMailAddress())where master added a PHP 8 null-safety cast - which this change does not touch.Related
🤖 Generated with Claude Code