## Summary - add a first-class finding exception domain with request, approval, rejection, renewal, and revocation lifecycle support - add tenant-scoped exception register, finding governance surfaces, and a canonical workspace approval queue in Filament - add audit, badge, evidence, and review-pack integrations plus focused Pest coverage for workflow, authorization, and governance validity ## Validation - vendor/bin/sail bin pint --dirty --format agent - CI=1 vendor/bin/sail artisan test --compact - manual integrated-browser smoke test for the request-exception happy path, tenant register visibility, and canonical queue visibility ## Notes - Filament implementation remains on v5 with Livewire v4-compatible surfaces - canonical queue lives in the admin panel; provider registration stays in bootstrap/providers.php - finding exceptions stay out of global search in this rollout Co-authored-by: Ahmed Darrazi <ahmed.darrazi@live.de> Reviewed-on: #184
4.7 KiB
4.7 KiB
Quickstart: Finding Risk Acceptance Lifecycle
Goal
Verify that the product can govern accepted-risk findings with explicit request, approval, expiry, renewal, revocation, and audit semantics.
Prerequisites
- Start Sail and ensure the application database is available.
- Have at least one workspace, one tenant in that workspace, and at least one finding visible in tenant context.
- Use two distinct tenant members for validation:
- requester with
finding_exception.manage - approver with
finding_exception.approve
- requester with
- Use a seeded local Sail dataset with one workspace, one tenant, one eligible open finding, and one active exception near expiry for reminder validation.
Happy Path
- Open the tenant finding detail for an open finding.
- Trigger
Request exception. - Enter justification, accountable owner, and review or expiry timing.
- Optionally link one or more supporting evidence references.
- Confirm that the new exception appears as
pendingin the tenant exception register and the canonical approval queue. - Sign in as the approver.
- Open the pending request from the canonical queue and choose
Approve exception. - Confirm that:
- the exception becomes
active - the finding is shown as governed accepted risk
- audit history shows request and approval decisions
- the exception becomes
Rejection Path
- Create a second request for another finding.
- Reject the request with a reason.
- Confirm that:
- the exception becomes
rejected - the finding is not treated as valid accepted risk
- audit history includes the rejection decision
- the exception becomes
Renewal Path
- Use an active exception with a near-term expiry.
- Trigger
Renew exception. - Enter updated justification and evidence references.
- Approve the renewal as an approver.
- Confirm that:
- the validity window extends
- prior decision history remains visible
- the exception still has one current valid governing record
Revocation and Expiry Path
- Revoke one active exception with a reason.
- Confirm that it becomes
revokedand no longer counts as valid accepted risk. - Create or adjust another exception so its expiry is in the past.
- Confirm that tenant and canonical views show it as
expiredand that the linked finding surfaces a governance warning if it still showsrisk_accepted.
Reminder Visibility Path
- Use an active exception that is close to expiry according to the configured due-state thresholds.
- Open the tenant finding detail, tenant exception register, canonical queue, and exception detail.
- Confirm that requester, accountable owner, tenant managers, and entitled workspace approvers see the expected passive in-product reminder cues in the surfaces they can access.
- Confirm that no scheduled job, email, background notification, or
OperationRunis required for this visibility in v1.
Concurrency and History Path
- Submit a pending exception request for a finding.
- Attempt to submit a second request or second renewal workflow for that same finding before the first reaches a terminal state.
- Confirm that the system blocks the parallel pending workflow and preserves the original in-flight request.
- Resolve, close, reopen, or change the severity of a finding with historical exception decisions.
- Confirm that exception history remains readable and the UI shows whether the current finding state is still governed, no longer valid, or requires a fresh decision.
Authorization Checks
- Verify a tenant member with
finding_exception.viewbut without manage or approve capabilities can inspect exception detail but cannot request, approve, renew, reject, or revoke. - Verify a non-member or wrong-tenant user receives deny-as-not-found behavior for tenant and canonical exception routes.
- Verify the requester cannot approve their own pending request in v1, receives the defined self-approval rejection response, and does not change the exception state.
Suggested Focused Test Runs
- Run focused Pest feature tests for findings workflow, exception authorization, canonical queue filtering, and audit history.
- Run any badge and action-surface guard tests impacted by new exception-state surfaces.
- Run the minimal Livewire or Filament tests for tenant detail and canonical queue actions.
Timed Acceptance Checks
- Time SC-001 by starting on tenant finding detail and stopping when a complete exception request is visible in the canonical queue on the first successful run against the seeded baseline.
- Time SC-003 by starting on exception detail and stopping when the reviewer can point to requester, approver, justification, and validity-window evidence without leaving the product on the first successful run against the seeded baseline.