Skip to content

feat(android): retire profile Access ownership on Forget - #156239

Draft
vincentkoc wants to merge 1 commit into
split/android-ingress-browser-renewal-20260923from
split/android-ingress-profile-forget-20260923
Draft

vincentkoc wants to merge 1 commit into
split/android-ingress-browser-renewal-20260923from
split/android-ingress-profile-forget-20260923

Conversation

@vincentkoc

Copy link
Copy Markdown
Member

What problem does this solve?

Add profile-specific Forget to the dormant Android Access controller. A departing profile must release its own admission and browser participation, preserve live sibling ownership, and acknowledge last-owner native-record deletion before clearing its durable association.

Why this approach?

This is the eighth narrow slice of #147305, stacked on #156236. It reuses the existing canonical retirement receipt and departure reconciliation flow. Discovery cancellation and browser-task joins stay outside the monitor; overlapping departures follow the latest acknowledgement rather than starting independent cleanup.

The two-file delta is 886 changed lines: production +60/-0; tests +767/-59. The production growth exposes one real cleanup capability. There is no app activation, storage-format change, origin-wide Sign out, Retry, or cleartext admission in this slice.

Evidence and remaining gates

  • Add twelve existing regression methods, bringing the prefix to 48 Controller methods. Cover sibling preservation, failed deletion/reconstruction, reentrant publication, stale association ownership, IPv6 origin identity, overlapping retirement, and grants renewed while departure acknowledgement is suspended.
  • Expand the credentialed-discovery retirement matrix with Forget and the browser retirement matrix with explicit Forget. Only supported Forget/origin-change cells are present in later mixed-mode methods; Sign out, Retry, cleartext, and shared-browser cells arrive with their capabilities. Final aggregate method bodies remain the preserved target.
  • Normal scoped commit hooks and git diff --check pass. Standalone compilation and runtime proof remain pending; prior 150-method results from the original aggregate are historical evidence only.
  • Automated source review remains held by the existing test-fixture filename classification. This draft makes no substitute review-clearance claim and does not resubmit that input.
  • Native persistence and complete fresh-install/same-signer install-over profile, selection, custom-header, settings, and pairing compatibility remain required for the final composition. This draft is not ready to merge.

@vincentkoc vincentkoc self-assigned this Sep 23, 2026
@clawsweeper

clawsweeper Bot commented Sep 23, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@clawsweeper

clawsweeper Bot commented Sep 23, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs real behavior proof before merge. Reviewed September 25, 2026, 11:04 PM ET / September 26, 2026, 03:04 UTC (Revision 2).

ClawSweeper review

What this changes

Adds an Android Access controller operation to forget one gateway profile, revoke its admission and browser participation, and preserve same-origin siblings during credential cleanup.

Merge readiness

⛔ Blocked before merge - 4 items remain

Keep open: this is a coherent prerequisite in an active Android Access PR stack. Current main and the latest release do not contain the controller’s Forget path.

Priority: P2
Reviewed head: 631c079625ce355d10ee581f3972958ecc96a2de

Review scores

Measure Result What it means
Overall readiness 🦪 silver shellfish (2/6) The focused authority design and scenarios are useful, but this unchanged draft head still lacks final-effect proof and standalone slice validation.
Proof confidence 🦪 silver shellfish (2/6) Needs real behavior proof before merge: Authority-chain proof required: the changed controller Forget path revokes a profile lease and starts Store retirement, while GatewaySession owns final network checks. The added tests exercise injected clients and storage, but no captured production-controller Gateway/media request shows after-Forgot rejection and sibling success before I/O. No stored-data format changes occur in this slice. After adding proof, update the PR body; ClawSweeper should re-review automatically. If it does not, the PR author or someone with repository write access can comment @clawsweeper re-review.
Patch quality 🦐 gold shrimp (3/6) Security review found an item that needs attention.

Verification

Check Result Evidence
Real behavior Needs proof Needs real behavior proof before merge: Authority-chain proof required: the changed controller Forget path revokes a profile lease and starts Store retirement, while GatewaySession owns final network checks. The added tests exercise injected clients and storage, but no captured production-controller Gateway/media request shows after-Forgot rejection and sibling success before I/O. No stored-data format changes occur in this slice. After adding proof, update the PR body; ClawSweeper should re-review automatically. If it does not, the PR author or someone with repository write access can comment @clawsweeper re-review.
Evidence reviewed 7 items Introduced Forget operation: The pinned parent-to-head diff adds profile revocation, sibling ownership selection, retirement reservation, and completion handling to the controller.
Existing retirement and storage owners: The parent already has the Store retirement operations and the registry’s persisted Access-origin field; this slice changes their use, not their stored format.
Final request boundary: GatewaySession checks ingress authorization at network interception and again around responses; final-effect proof must exercise this boundary with Forget.
Findings None None.
Security Needs attention Unproven revocation before final network I/O: Forget removes a profile’s lease and registration, but the supplied evidence does not exercise a retained or queued request through the real Gateway or media client after revocation.

How this fits together

The Android ingress controller combines saved gateway profiles with Cloudflare Access sessions to decide which requests may use an Access grant. The controller remains unwired to the app in this draft stack; once integrated, its authorization reaches Gateway and media transports.

flowchart LR
A[Forget profile] --> B[Android Access controller]
C[Saved profiles and Access grants] --> B
B --> D{Sibling owns origin?}
D -->|Yes| E[Keep shared grant]
D -->|No| F[Delete Access record]
B --> G[Revoke profile lease]
G --> H[Gateway and media requests]
Loading

Before merge

  • Add real behavior proof - Needs real behavior proof before merge: Authority-chain proof required: the changed controller Forget path revokes a profile lease and starts Store retirement, while GatewaySession owns final network checks. The added tests exercise injected clients and storage, but no captured production-controller Gateway/media request shows after-Forgot rejection and sibling success before I/O. No stored-data format changes occur in this slice. After adding proof, update the PR body; ClawSweeper should re-review automatically. If it does not, the PR author or someone with repository write access can comment @clawsweeper re-review.
  • Resolve security concern: Unproven revocation before final network I/O - Forget removes a profile’s lease and registration, but the supplied evidence does not exercise a retained or queued request through the real Gateway or media client after revocation.
  • Resolve merge risk (P1) - A forgotten profile’s retained or queued authorization has not been shown to fail before Gateway or media network I/O while a same-origin sibling remains usable.
  • Complete next step (P2) - Provide final-I/O Forget proof with redacted Gateway/media request traces or diagnostic recording, then record standalone focused Android compilation, tests, and duration. Redact IP addresses, keys, phone numbers, and private endpoints. Updating the PR body should trigger a fresh review; if it does not, ask a maintainer to comment @clawsweeper re-review.

Findings

  • [medium] Unproven revocation before final network I/O — apps/android/app/src/main/java/ai/openclaw/app/gateway/GatewayIngressController.kt:526
Agent review details

Security

Needs attention: The authority boundary needs final network-effect validation; the diff adds no unrelated supply-chain change.

PR surface

Tests +708, Other +60. Total +768 across 2 files.

View PR surface stats
Area Files Added Removed Net
Source 0 0 0 0
Tests 1 767 59 +708
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 1 60 0 +60
Total 2 827 59 +768

Review metrics

Metric Value Why it matters
Production versus test growth production +60/-0; tests +767/-59 The production growth serves one new cleanup capability; the larger test change covers its ownership and retirement cases.

Merge-risk options

Maintainer options:

  1. Prove revocation at final I/O (recommended)
    Capture a production-controller run with real Gateway and media clients showing rejection before I/O for a forgotten profile and continued access for its same-origin sibling.

Technical review

Best possible solution:

Integrate the controller with Android’s profile and transport flows after final-effect authority proof and the stack’s installed-old preservation checks are complete.

Do we have a high-confidence way to reproduce the issue?

Not applicable: this PR adds a controller capability. Its tests model Forget scenarios, but the PR reports no standalone runtime execution for this slice.

Is this the best way to solve the issue?

Yes in design: the controller reuses the Store’s retirement receipt and registry ownership rather than adding another state owner. Final network-effect proof is still needed.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against 37259b7cab6b.

Labels

Label changes:

  • add merge-risk: 🚨 security-boundary: Forget changes which profile may use a shared Access grant, and final network-effect rejection remains unproven.

Label justifications:

  • P2: This is a bounded Android capability in an active draft stack, with no demonstrated current user regression.
  • merge-risk: 🚨 security-boundary: Forget changes which profile may use a shared Access grant, and final network-effect rejection remains unproven.
  • rating: 🦪 silver shellfish: Overall readiness is 🦪 silver shellfish; proof is 🦪 silver shellfish and patch quality is 🦐 gold shrimp.
  • status: 📣 needs proof: The PR needs real behavior proof before ClawSweeper can clear the contributor ask. Needs real behavior proof before merge: Authority-chain proof required: the changed controller Forget path revokes a profile lease and starts Store retirement, while GatewaySession owns final network checks. The added tests exercise injected clients and storage, but no captured production-controller Gateway/media request shows after-Forgot rejection and sibling success before I/O. No stored-data format changes occur in this slice. After adding proof, update the PR body; ClawSweeper should re-review automatically. If it does not, the PR author or someone with repository write access can comment @clawsweeper re-review.

Evidence

Security concerns:

  • [medium] Unproven revocation before final network I/O — apps/android/app/src/main/java/ai/openclaw/app/gateway/GatewayIngressController.kt:526
    Forget removes a profile’s lease and registration, but the supplied evidence does not exercise a retained or queued request through the real Gateway or media client after revocation.
    Confidence: 0.82

What I checked:

Likely related people:

  • unknown: The claimed source-line change could not be verified from bounded local history. (role: source history unknown; confidence: low)

Rank-up moves

Optional improvements that raise the rating; they are not merge blockers.

  • Show final-I/O rejection for a forgotten profile’s retained or queued authorization while a same-origin sibling succeeds.
  • Record standalone compilation, focused regression results, and test duration for this slice.

Rating scale

Score Internal tier Crab rank Meaning
6/6 S 🦀 challenger crab Exceptional readiness
5/6 A 🦞 diamond lobster Very strong readiness
4/6 B 🐚 platinum hermit Good normal PR; ordinary maintainer review
3/6 C 🦐 gold shrimp Useful, but confidence is limited
2/6 D 🦪 silver shellfish Proof or implementation needs work
1/6 F 🧂 unranked krab Not merge-ready
N/A NA 🌊 off-meta tidepool Rating does not apply

Overall follows the weaker of proof and patch quality.
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics.

Workflow

  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.

History

Review history (1 earlier review cycle)
  • reviewed 2026-09-23T05:58:25.007Z sha 631c079 :: needs real behavior proof before merge. :: none

@clawsweeper clawsweeper Bot added rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask. P2 Normal backlog priority with limited blast radius. merge-risk: 🚨 security-boundary 🚨 May affect sandboxing, authorization, credentials, or sensitive data. labels Sep 26, 2026

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

app: android App: android merge-risk: 🚨 security-boundary 🚨 May affect sandboxing, authorization, credentials, or sensitive data. P2 Normal backlog priority with limited blast radius. rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. size: L status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant