Skip to content

fix(dav): align principal search and not-found responses with server settings - #66805

Merged
GVodyanov merged 1 commit into
masterfrom
fix/dav/principal-search-settings
Nov 24, 2026
Merged

GVodyanov merged 1 commit into
masterfrom
fix/dav/principal-search-settings

Conversation

@GVodyanov

@GVodyanov GVodyanov commented Nov 19, 2026 •

Copy link
Copy Markdown
Contributor
  • Resolves: #

Summary

DAV principal search and DAV error responses had drifted from the rest of the server.

  • Group principal search now honours the share dialog's enumeration settings (shareapi_allow_share_dialog_user_enumeration, shareapi_restrict_user_enumeration_to_group), using the same rules as GroupPlugin::search().
  • User principal search uses the same enumeration semantics as Share20\Manager. The phone book restriction now works on its own, and the group-members-only exclude list is applied.
  • Not-found responses for calendars and address books are the same whether a path doesn't exist or can't be accessed. This also covers multiget hrefs, If: URIs and expand-property.

Instances with default sharing settings see no change in search results.

Behaviour changes

  • Non-default enumeration settings now also limit attendee/sharee search in calendar clients.
  • Some error messages change from Calendar with name … / Card not found to Node with name … could not be found. The integration test expectations are updated.

TODO

  • Manual test on a live instance

Checklist

AI (if applicable)

  • The content of this PR was partly or fully generated using AI

Assisted by ClaudeCode:claude-opus-5-5

@GVodyanov
GVodyanov requested review from Altahrim and CarlSchwan and removed request for a team November 19, 2026 11:12
@GVodyanov
GVodyanov force-pushed the fix/dav/principal-search-settings branch from f732065 to f3a61d9 Compare November 19, 2026 11:14
@kesselb kesselb added the 3. to review Waiting for reviews label Nov 19, 2026
Group principal search returned every group matching the term, and
searchUserPrincipals() kept its own copy of the enumeration rules,
which had drifted from the share dialog: the phone book restriction
had no effect unless the group restriction was also enabled, and the
group-members-only exclude list was not applied. Both searches now
use the same rules as GroupPlugin and Share20\Manager. Default
settings are unaffected.

DavAclPlugin answered inaccessible calendar and address book paths
with its own message, which differed from the collection's regular
not-found response, and multiget hrefs, If: header URIs and
expand-property paths could get different status codes for the same
case. These paths now resolve the same way and return one consistent
"Node with name … could not be found".

Full-match principal search and the remote-calendars/ and
system-calendars/ roots are left as is.

Assisted-by: ClaudeCode:claude-opus-5-5
Signed-off-by: Grigory Vodyanov <scratchx@gmx.com>
@GVodyanov
GVodyanov force-pushed the fix/dav/principal-search-settings branch from f3a61d9 to 6fe5e29 Compare November 19, 2026 17:40
@GVodyanov
GVodyanov enabled auto-merge November 19, 2026 17:43
@GVodyanov
GVodyanov disabled auto-merge November 19, 2026 18:19
@GVodyanov
GVodyanov merged commit 507e34e into master Nov 24, 2026
168 of 171 checks passed
@GVodyanov
GVodyanov deleted the fix/dav/principal-search-settings branch November 24, 2026 11:03
@GVodyanov

Copy link
Copy Markdown
Contributor Author

/backport to stable35

@GVodyanov

Copy link
Copy Markdown
Contributor Author

/backport to stable34

@GVodyanov

Copy link
Copy Markdown
Contributor Author

/backport to stable33

@GVodyanov

Copy link
Copy Markdown
Contributor Author

/backport to stable32

@GVodyanov

Copy link
Copy Markdown
Contributor Author

/backport to stable31

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

Labels

3. to review Waiting for reviews AI assisted

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants