Repository navigation
fix(strix): include search authorization context in PR scans #695
Copy link
Copy link
Open
Labels
area: apiAPI, protocol, event, or external contractAPI, protocol, event, or external contractarea: authAuthentication, authorization, identity, or tenant isolationAuthentication, authorization, identity, or tenant isolationarea: dataDatabase, schema, migration, ETL, or lineageDatabase, schema, migration, ETL, or lineagearea: ui-uxFrontend, interaction, design, or user experienceFrontend, interaction, design, or user experiencebugSomething isn't workingSomething isn't workingpriority: mediumNormal-priority or P2 workNormal-priority or P2 workstatus: triagedOpen issue has an organization taxonomy assignmentOpen issue has an organization taxonomy assignmenttype: bugDefect or incorrect behaviorDefect or incorrect behavior
Description
Problem
ContextualWisdomLab/naruon#1210 current head bccd1b1e6a722fa286e92f63fc2571b296f5388f failed central Strix run 30684197947 with four findings after the report explicitly limited itself to one frontend component and did not verify backend validation. Static current-head triage showed:
- relationship reads require signed-session
AuthContextand SQLuser_idplusorganization_idfilters - capture-source resolves the email with
Email.owner_filtersbefore reading or writing - state-changing BFF requests reject cross-site Origin/Referer and use a Secure, HttpOnly, SameSite=Lax session cookie
- the AI answer is a React text child, not an HTML sink
- sender addresses remain on the authenticated owner-scoped surface
The central context selector already supplies backend auth context for selected email frontend components, but it does not recognize frontend/src/components/SearchLayout.tsx or provide the ontology/search/BFF/session files needed to assess this path.
Acceptance criteria
- Map SearchLayout and the search route shell to a bounded cross-layer search/auth context.
- Include ontology/search authorization, owner-filter model, BFF same-origin guard, session-cookie, and API-client context without widening findings beyond changed files.
- Preserve trusted-base context for unchanged files and PR-head blobs for files changed in the same PR.
- Add a functional regression proving the expected context is present and unrelated files remain excluded.
- Pass focused/full Strix gate tests, shellcheck, actionlint, and diff hygiene.
- After merge, rerun exact-head Strix for 🎨 Palette: [UX 개선] 검색 결과 빈 화면 및 로딩 상태 시각적 피드백 강화 naruon#1210 and verify the metadata-only aggregate recovers only if the current-head Strix gate succeeds.
Agent: Codex
Started: 2026-08-01T14:00:00+09:00
Phase: Ops
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
area: apiAPI, protocol, event, or external contractAPI, protocol, event, or external contractarea: authAuthentication, authorization, identity, or tenant isolationAuthentication, authorization, identity, or tenant isolationarea: dataDatabase, schema, migration, ETL, or lineageDatabase, schema, migration, ETL, or lineagearea: ui-uxFrontend, interaction, design, or user experienceFrontend, interaction, design, or user experiencebugSomething isn't workingSomething isn't workingpriority: mediumNormal-priority or P2 workNormal-priority or P2 workstatus: triagedOpen issue has an organization taxonomy assignmentOpen issue has an organization taxonomy assignmenttype: bugDefect or incorrect behaviorDefect or incorrect behavior
Type
Projects
- StatusShow more project fieldsIn Progress
Activity
seonghobae commentedon Sep 9, 2026
Fresh Orgmetra Strix canary shows the same bounded-context-selection defect on a domain/application authorization boundary, not a frontend/search boundary.
Consumer:
ContextualWisdomLab/Orgmetra#63@d88800a5ca3ca15df332e8def5e25064c46e4005; required Strix34294884985, job102289341649; retained artifact10083683583(sha256:0936587636b5689136fb28221d55b84982fa8241950d087cb52818cb2299887f).Strix reports HIGH CWE-863
IDOR in JobAnalysisSnapshot tenant/job scope enforcementagainstpackages/hris-kernel/src/orgmetra_hris_kernel/job_analysis.py. Its claimed exploit is direct construction ofJobAnalysisSnapshotwith a victim tenant/job and its remediation asks the domain value object's__post_init__()to perform user authorization.Current authoritative code contradicts that boundary model:
JobAnalysisSnapshotas immutable job-analysis evidence, not an employment decision or persistence/authorization endpoint;services/job-analysis-api/src/orgmetra_job_analysis_api/snapshot.pyexplicitly states authorization occurs before write/read port invocation and invokesauthorize_resource_fields(...)for thejob_analysis_snapshot:<id>resource;port.calls == [];tasks,ksao_requirements, andtask_ksao_links, so it does not satisfy the constructor's non-empty evidence invariants anyway;Do not add authentication/session dependencies to the HRIS kernel constructor merely to satisfy this finding; that would invert the DDD dependency direction and couple a pure domain value to application authorization context. The central Strix scope should instead supply the narrow trusted-base job-analysis API authorization/persistence context whenever a PR changes the kernel job-analysis contract, then require a claimed IDOR to demonstrate a path that reaches an authoritative port while bypassing that application boundary.
Please generalize the #695/#697 approach with a focused fixture for
packages/hris-kernel/src/orgmetra_hris_kernel/job_analysis.py→ boundedservices/job-analysis-apiauth/snapshot/persistence context. Preserve PR-head trust only for changed files, trusted-base context for unchanged files, and do not globally suppress CWE-863/IDOR findings.seonghobae commentedon Sep 26, 2026
Canonical owner update for Orgmetra #63's Job Analysis false-positive scope gap: .github#2291 now carries source-first RED
1fd22f4e…and exact GREEN/traceability headb90d873e67860944308d5cef919a1f95243ef98f(tree03c09bdf…). The executable fixture requires the changed PR-head kernel module plus exactlyauth.py,authorization.py,http.py,postgres.py, andsnapshot.pyfrom the authenticated trusted base, and proves an unrelated administration module is excluded. Full Strix harness PASS; full repository suite 3388 passed, 28 skipped, 40 subtests. Hosted exact-head checks and protected-main integration remain pending, so this Issue stays open and no consumer acceptance transfers yet.