Skip to content

BUG-28: crc-rollback.sh deletes on the cluster before LDAP can refuse #138

Closed

Description

@ephico2real2

Part of #94

What is wrong: deploy/crc-rollback.sh --yes deletes the workloads, the database objects, the Secrets and the roles on the cluster before it asks LDAP. If LDAP then refuses, the cluster part is gone and the LDAP part stays. This occurs when a new group or test user holds an attribute that step 9 did not write. The refusal gives no instruction to the operator.

Where: deploy/crc-rollback.sh:29-57, on PR #112 at ecc5cb3. The call to apply-test-identities.sh --remove-test-identities is the last step. The refusal messages are in examples/cmapi-sso/ldap/apply-test-identities.sh, functions remove_old and remove_new.

How to prove it: On the OpenLDAP stand-in of deploy/tests/ldap-identities-test.sh, run step 9. Add a description to cn=app-cmapi-rbac-viewer. Run the rollback with a stub oc that records each delete. The rollback must fail with no delete on the cluster and none in LDAP.

Measured or inferred: Measured on 2026-11-13 on macOS with Podman, by Codex gpt-6.1-sol and again by OB1. Before the fix: 32 delete calls to the stub oc, then the LDAP refusal. No real cluster.

Severity: Medium. A rollback stops halfway on a shared cluster, and the operator has no instruction.

What must hold after the fix: The rollback asks LDAP first, with a check that writes and deletes nothing. A refusal comes before the first delete on the cluster. The message says to stop, to report the listed entries to the directory owner, and not to remove attributes to force the rollback. A rollback on entries that are as written goes through as before.

Research: The check is a preflight and not a lock: the removal repeats the checks. The script cannot lock the directory.

Solution (inline, not applied): A new mode --check-remove-test-identities in apply-test-identities.sh, called at the start of crc-rollback.sh. Codex's patch C10.patch holds the full code and the changes to docs/13.

Class: INV. The fix adds a control, and the defect is in new INV work (#94, #110) that is not merged.

Activity

  1. added
    bug
    class:INV
    status:open
    sev:medium
    In-Progress
    on Nov 13, 2026
  2. ephico2real2 commented on Nov 13, 2026

    @ephico2real2
    OwnerAuthor

    In-Progress: found by the second pass on PR #112 (Codex gpt-6.1-sol, 2026-11-13). The fix goes on the branch of PR #112 (draft), with its case in deploy/tests/ldap-identities-test.sh.

  3. added a commit that references this issue on Nov 13, 2026
    83cd215
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    In-Progressbugclass:INVsev:mediumstatus:open

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions