Skip to content

Commit 9b04a57

Browse files
committed
chore(changeset): declare the search narrowing as an acceptance widening
1 parent 61177d0 commit 9b04a57

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎.changeset/25672-search-readable-fields.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
fix(objectql): a free-text `search` resolves only over the fields the caller may query
66

7-
Clause-②: no
7+
Clause-②: yes (widening)
88
Metadata-protocol: none
99

1010
The server-resolved search set used to include fields the caller cannot read, so the field-read predicate guard refused the whole expanded `$or` with 403. On `sys_user`, `role`, `ban_reason` and `last_login_ip` broke every user and owner picker for non-admin members as soon as they typed. The engine now asks the registered security service's `getQueryableFields` (the complement of what the guard refuses) and withholds every other field from the resolved set, on `find`, `findOne`, `count` and `aggregate`. The guard is unchanged: an explicit `filter`, or a `searchFields` naming a hidden field, is still refused with 403. A search whose declared fields are all hidden from the caller answers the existing `400 INVALID_FIELD` empty-search-set refusal, never every row.

0 commit comments

Comments
 (0)