docs(roadmap): design-reviewed recovery-mode visibility item (Phase R3)#61
Conversation
…se R3) A pre-implementation design review of the recovery-mode visibility gap (notice + audit event fire only on the Sudo settings page) concluded: - Ship: a Site_Health::test_recovery_mode() returning critical, keyed strictly on wp_sudo_is_recovery_mode() — pull-based, REST-exposed, live, no cron dependence. - Drop: a daily-cron audit heartbeat — unreliable on the neglected sites where recovery is most likely left on (opportunistic/disabled WP-Cron), redundant with the Site Health REST status, and would force a user_id=0 row that corrupts the per-user sampling bucket and the documented semantics of wp_sudo_recovery_mode_active. A dedicated recovery_mode_heartbeat hook+event would be required if ever needed. - Defer: broadening the notice to all_admin_notices (notice fatigue + multisite capability nuance). Records the item under Phase R3 §12.1 with a planned Site Health test. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
🎮 Try in WordPress PlaygroundPreview is pinned to WordPress Uses the checked-in Logs in as ✅ What you can test
❌ What won't work
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #61 +/- ##
=========================================
Coverage 89.35% 89.35%
Complexity 1284 1284
=========================================
Files 18 18
Lines 5231 5231
=========================================
Hits 4674 4674
Misses 557 557
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Pull request overview
This PR updates the project roadmap to record the Phase R3 design-review outcome for closing the “recovery-mode visibility gap” (where the recovery-mode notice and the wp_sudo_recovery_mode_active audit event only fire from Admin::render_settings_page()), and documents the chosen monitoring approach for a future implementation PR.
Changes:
- Added a new “Visibility / monitoring follow-up” item documenting the design decision to ship a
Site_Health::test_recovery_mode()check keyed strictly onwp_sudo_is_recovery_mode(). - Documented why a daily-cron “audit heartbeat” was dropped (reliability + event semantics), and why expanding notices to
all_admin_noticeswas deferred. - Added acceptance-criteria notes for the planned Site Health test behavior (critical only when recovery mode is active; multisite visibility considerations).
Captures the outcome of a pre-implementation design review of the recovery-mode visibility gap: the warning notice (
Admin::render_recovery_mode_notice()) and thewp_sudo_recovery_mode_activeaudit event both fire only insiderender_settings_page(), so a permanent, security-degrading break-glass bypass can persist with no reminder and no SIEM signal if nobody revisits the Sudo settings page.Design-review conclusion (recorded under Phase R3 §12.1):
Site_Health::test_recovery_mode()→critical, keyed strictly onwp_sudo_is_recovery_mode(). Pull-based, REST-exposed (monitorable), live state, no cron dependence; must surface to the network operator on multisite.DISABLE_WP_CRON), redundant with the Site Health REST status, and would force auser_id = 0row that corrupts the per-user sampling bucket and the documented "user accessing the Sudo surface" semantics ofwp_sudo_recovery_mode_active. Would require a dedicatedrecovery_mode_heartbeathook+event if ever needed.all_admin_notices(notice fatigue + multisite capability nuance).Docs-only; no code. Implementation (the Site Health test) is a separate follow-up PR via TDD.
🤖 Generated with Claude Code