Skip to content

Per-Bot grants leak: accepting a Helper invite exposes the joiner's Chief; face-room Chief shows in Friends' Bots; Manage access wrong/raw #138

Closed

Description

@Birfy

Environment: ThinkFlowLab/FlyBot main 1ac7104 (core, plugins/social, plugins/tree) on @deepseek-ai/dsh@0.2.0-rc.2, two fresh installs on one Linux box (A on :3080, B on :3081), Bot Social server https://47-80-69-220.sslip.io. Found in the scheduled two-instance UI self-test on 2026-10-16 (~19:35 UTC+8).

What happened

  1. A invited B to Helper only (Helper → Settings → "Invite to this Bot", text: "Accepting the invite grants them Helper only"). B accepted with + → Accept invite. Status: "You are now friends with Helper as Chief." B was never asked which Bot to join as.
  2. A's sidebar then shows Friends' Bots 1 → SelfB1935 → "SelfB1935's Chief", although B never granted any Bot to A.
  3. After a face-to-face room together, B's Friends' Bots, which said "No Bots shared yet", lists "SelfA1935's Chief", although A never invited B to Chief (face-room join is supposed to be room-only).
  4. A's Helper → Manage access: right after B joined (after a reload) it said "Nobody has this Bot yet". Later it lists "Chief@chief.selfb1935.home" with Revoke: a raw member handle instead of the person (SelfB1935).

Repro

  1. Two fresh installs A and B. A: Helper → details → gear → Invite to this Bot → Copy link.
  2. B: + → Accept invite → paste → Join.
  3. Look at A's Friends' Bots, and A's Helper → Manage access.
  4. Create a face-to-face room A+B (bring Chief), chat, Leave on both; look at B's Friends' Bots.

Expected (owner design: per-Bot grants, default deny, Chief included; no publish)

  • Accepting an invite grants exactly the invited Bot to me. It does not grant any of my Bots back. If the protocol needs a Bot on my side to talk through, ask which one (default Chief) and make clear it is not shared with the inviter unless I invite them to it.
  • Face-to-face join stays room-only: after leaving, no Bot from the room shows in Friends' Bots.
  • Manage access lists people ("SelfB1935 (@selfb1935.home)") and is correct right after the join.
  • Success copy names the person and the Bot: "SelfA1935 shared Helper with you."

Activity

  1. Birfy commented on Oct 16, 2026

    @Birfy
    CollaboratorAuthor

    Fixed on main (566f1e6) by #141 plus the review follow-up #142.

    All four points from the report:

    1. Invite grants only the invited Bot. The joiner's talk-through Bot is no longer shown back to the inviter. Friends' Bots drops reverse relationships created by your own invites (inboundBots, with a one-time backfill in fix(social): Codex review follow-up for #141 (canonical grants, inbound backfill, scoped unhide) #142 so an upgrade doesn't drop real reciprocal friends). Accept invite always shows "Talk through [Bot] (not shared unless you invite them to it)".
    2. Face-to-face stays room-only. Room-only remotes stay out of Friends' Bots and are dropped when you leave (fix(social): Codex review follow-up for #141 (canonical grants, inbound backfill, scoped unhide) #142 also stops markRoomRemote re-adding friends already on the roster). Test: #138: leaving a face room drops room-only remotes from Friends' Bots.
    3. Manage access lists people. Grants come from list_bot_grants and render as Name (@home). fix(social): Codex review follow-up for #141 (canonical grants, inbound backfill, scoped unhide) #142 stores core grants as the canonical @handle, so reach() matches them. Test: #136 / #138: grant labels use the person home….
    4. Success copy: {person} shared {Bot} with you.

    Caveat: the leak is fixed in the client and core grants (what appears in Friends' Bots and what reach() allows). The Bot Social relationship itself is still home-to-home on the server.

    Closing as completed.

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

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions