Repository navigation
Done
Labels
app/idPackage/app: id (pkgs/ or apps/ in this repo)effort/sSmall: expected under 2 hours of workkind/bugSomething isn't working (prefixed form of the classic bug label)meta/enrichedIntake review done: acceptance criteria, links, and normalized labels addedpriority/highImportant and time-sensitivestatus/needs-triageNot yet triaged; needs a first lookstatus:done
Description
Evidence
PR #14497 (for #14391) refuses filter and order columns that are reserved PostgREST parameter names or not plain identifiers. The projection path is still unchecked:
pkgs/id/crates/id-pg/src/translate.rsresolve_projection(around step 8) expands the query'sselectagainstdeclared_columnsand joins the names into theselectparameter (step 10:projection.join(",")).CollectionAllowlist(pkgs/id/crates/id-pg/src/allowlist.rs) accepts any string as a declared column name, so a declared column such asa,b,x(y), ororlands raw in theselectvalue.path: format!("/{relation}")is also raw; fix(id-pg): refuse reserved or non-identifier filter/order fields (#14391) #14497 refuses a non-identifier relation at translate time, but nothing refuses it at allowlist construction.
Why it matters
The translator is the only guard until the transport (#13763) makes live calls. A declared name with ,, (, ), " or whitespace changes the shape of the select list the source parses. Refusing at construction time means a bad config never reaches a request.
Suggested fix
- Add
CollectionAllowlist::validate(&self) -> Result<(), String>inallowlist.rs: relation is a plain identifier; every declared column name is a plain identifier and not reserved (is_usable_field_name);unique_keyentries are declared columns. - Call it from registration (id: impl: Postgres HTTP adapter registration and owner config (from #5805) #13758) when the allowlist is built, and from
Translator::newin debug builds or as aResult-returning constructor. - In
resolve_projection, refuse withfield_unsupportedif a declared column failsis_usable_field_name, as defense in depth.
Acceptance criteria
-
cargo test -p id-pginpkgs/idpasses. - Unit test: a collection declaring column
a,bfailsvalidate(); a declaredorfailsvalidate(); a declared plain column passes. - Unit test: a
select *query against a collection with a declared columnx(y)is refused asfield_unsupported(noselectparameter emitted). - Refusal bodies stay byte-identical for withheld and unknown columns (existing
withheld_and_unknown_columns_produce_identical_bodiesstill passes). - Doc comment on
validatestates which names are rejected and why.
Dependencies
- Builds on PR fix(id-pg): refuse reserved or non-identifier filter/order fields (#14391) #14497 (for id-pg: translator emits ambiguous requests for columns named like PostgREST reserved params (or/select/…) #14391):
is_usable_field_nameandis_plain_identifier. Blocked-by that PR merging. - Feeds registration id: impl: Postgres HTTP adapter registration and owner config (from #5805) #13758.
{
"direct_parent": null,
"links": [],
"lineage": {
"design": null,
"roadmap_item": null,
"priority": null
},
"pm_meta": 1,
"provenance": {
"queue_id": null,
"scheduled_start": null,
"picked_up_at": null,
"work_started_at": null,
"created_at": "2026-11-24T17:17:29Z",
"session_id": "ses_e5df177e305ffeUZzwUyoH6CdK",
"lane": null,
"host": "amd",
"worktree": "/home/user/git/fleet/dispatch-code-23601",
"model": null,
"lane_start_issues": [],
"workspace_ref": {
"kind": "worktree",
"id": "/home/user/git/fleet/dispatch-code-23601",
"repo": "developing-today/code",
"branch": "dispatch/23601-14337-proxy-relay-reset",
"sha": "3c33319c11f63763906ba682625b34d387e66d8a"
},
"auth_subject": "oc-code-04",
"stamped_by": "fleet 0.1.0 (native)"
}
}Metadata
Metadata
Assignees
Labels
app/idPackage/app: id (pkgs/ or apps/ in this repo)effort/sSmall: expected under 2 hours of workkind/bugSomething isn't working (prefixed form of the classic bug label)meta/enrichedIntake review done: acceptance criteria, links, and normalized labels addedpriority/highImportant and time-sensitivestatus/needs-triageNot yet triaged; needs a first lookstatus:done
Activity
developing-today commentedon Nov 24, 2026
CODE-5343
developing-today-fleet commentedon Nov 24, 2026
Agent note — claim (ITEM-WORK-199)
Lane ITEM-WORK-199 (Muse item lane) is working this issue directly. Queue anchor: task 23612 (
repo-health-code-pilot, deduperepo-health:v1:fix:developing-today/code:issue:14502), enqueued by this lane 2026-11-24T18:22:58Z; the broker record shows it claimed under the sharedrepo-worker-codeidentity (lanecode-g) with no checkpoint and no note — this comment is the visible claim of record for the work.Premise verified fresh: issue open, no
user/*label, no design gate, only prior comment is the bot Kaneo link; PR #14497 (the stated dependency, addsis_usable_field_name/is_plain_identifier) is open, mergeable/clean — this lane's branch is based on its head and the combinedcargo test -p id-pgrun will verify both changes together; #14497 merges first, then this fix.Plan:
CollectionAllowlist::validate()inallowlist.rs(relation plain identifier; declared columns usable field names; unique_key entries declared) with unit tests; a Result-returningTranslator::try_newconstructor that validates at construction; defense in depth inresolve_projection(declared column failingis_usable_field_name→field_unsupported, noselectemitted) plus the same refusal for unique-key columns rendered intoorder.id-pg: validate allowlist names at construction, refuse unsafe projec…
Merge pull request #14541 from developing-today/queue/iw199-14502-all…
developing-today-fleet commentedon Nov 24, 2026
Salvage / duplicate disposition — PR #14540 closed as superseded by PR #14541 (protocol §8 diff performed by ITEM-WORK-199)
Two lanes converged on this issue within the same minute: this lane (ITEM-WORK-199) enqueued task 23612 and posted the claim note above, while the claim's fleet lane (
code-g) implemented in parallel and opened PR #14540 at 18:37:00Z; this lane's PR #14541 merged at 18:38:02Z (9a7c7d62) and closed this issue.Salvage diff of #14540 against the merged #14541:
CollectionAllowlist::validate()— functionally identical in both (same three checks: relation plain identifier, declared columns usable field names, unique_key entries declared).debug_assert!inTranslator::newplus test refactoring to anunchecked_translatorhelper; fix(id-pg): validate allowlist names at construction, refuse unsafe projection columns (#14502) #14541 uses the Result-returningTranslator::try_newconstructor. Both are the alternatives the issue's suggested fix names; nothing to port.select *against declaredx(y)refusal. The blanket-strictness difference is a judgment call, recorded here; no functional capability in id-pg: validate allowlist names at construction, refuse unsafe projection columns (#14502) #14540 is missing from main.Conclusion: nothing to salvage-port. PR #14540 is closed as superseded by #14541, with this note as the salvage record. Task 23612 completes as merged_verified on PR #14541.
developing-today-fleet commentedon Nov 24, 2026
Intake review
🤖 Agent note · state=filed