Feat nxe phase - #17
Conversation
The auth_rbac handler was registered on NGX_HTTP_PRECONTENT_PHASE with a plain ngx_array_push(), so its execution order relative to other same-phase modules (auth-gate, auth-cedar, internal-redirect) was whatever the reverse of --add-module/load_module ordering happened to produce, not something a config author could control. Vendor the shared nxe-phase submodule and register the handler with nxe_phase_add_handler(cf, NGX_HTTP_PRECONTENT_PHASE, NXE_PHASE_PRIO_RBAC, ngx_http_auth_rbac_handler, "auth_rbac"), matching the same migration already done in nginx-auth-cedar. Priority 750 places it after auth-gate (600) and auth-cedar (700), before internal-redirect (900). No return-value change is needed: the handler already returns NGX_DECLINED on both allow and deny paths.
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Team Run ID: 📒 Files selected for processing (6)
Included review availability: Your plan provides up to 1 included review per hour; 0 remain after this review. 📝 WalkthroughWalkthroughThe change adds the ChangesPRECONTENT Handler Ordering
Estimated code review effort: 2 (Simple) | ~10 minutes Merge Risk: ⚪ Minimal · up to The current changes leave no actionable merge-blocking risk beyond normal checks and review. Sequence Diagram(s)sequenceDiagram
participant ngx_http_auth_rbac_init
participant nxe_phase_add_handler
participant NGX_HTTP_PRECONTENT_PHASE
ngx_http_auth_rbac_init->>nxe_phase_add_handler: Register auth_rbac with NXE_PHASE_PRIO_RBAC
nxe_phase_add_handler->>NGX_HTTP_PRECONTENT_PHASE: Add ngx_http_auth_rbac_handler at fixed priority
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
Full details: Docstring CoverageExplanation Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 1 functions across 1 files. (5 skipped: 5 unsupported.) ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Summary by CodeRabbit
Improvements
Build & Packaging