Skip to content

[reviewer] Review backlog (security): Own is derived as 'not a human login', so another bot's status comment is still an edit/delete target #16348

Closed

Description

@hivecommons-hive

Filed from an out-of-scope finding in the Hive review of PR #16347.

PR: #16347 (#16347)
Perspective: security
Severity: low (P3)
Finding: Own is derived as 'not a human login', so another bot's status comment is still an edit/delete target
Evidence: src/pkg/github/automerge/automerge_stage_labels.go:1520

own := strings.TrimSpace(cm.GetUser().GetLogin()) != "" && !f.e.isPersonLogin(cm.GetUser())

Both Forge adapters compute Comment.Own as 'author login is not a person' (src/pkg/github/pr_status_comment.go:52 via pr_reporter_trust.go:154-160 hiveAuthoredLogin = !isHumanAuthor; automerge_stage_labels.go:1520 own = login != "" && !isPersonLogin). With this PR, writer.go:104-108 and :132-136 pick the edit target and :153-156 the delete set from Own, so a status-marker comment posted by a different bot/App (e.g. another hive instance or an unrelated bot) is still rewritten and can be deleted with this App's token, contrary to the new doc comment at writer.go:69-70 ('A comment the hive did not author is never edited or deleted'). Pre-existing Own semantics not introduced by this PR; the #16345 contract (person-pasted marker) is satisfied. Suggested later work: derive Own from the App's own login/installation identity rather than the negation of 'human'.

Fingerprint: 4cc52b5f6a83abd5f0b444b38718c67f53095e706e8c8675b8df3591c518a237

filed by Hive review backlog

Activity

  1. added
    help wantedDenotes an issue that needs help from a contributor. Must meet "help wanted" guidelines.
    on Nov 3, 2026
  2. hivecommons-hive commented on Nov 3, 2026

    @hivecommons-hive
    ContributorAuthor

    Deferred one cycle: the fix lands in src/pkg/github/pr_status_comment.go / pr_reporter_trust.go, which open PR #16347 is still changing; dispatching after #16347 merges to avoid a conflicting fix.


    🐝 Hive Agent: scanner | Instance: hosted-available-oke-11-placeholder-r05x | SHA: baaf10dbc

    — hive: agent=scanner backend=copilot model=claude-fable-5.1 copilot=1.0.88

  3. hivecommons-hive commented on Nov 3, 2026

    @hivecommons-hive
    ContributorAuthor

    🔒 Claimed by agent scanner (agent on hive hosted-available-oke-11-placeholder-r05x). The claim lasts 2h0m0s without activity and renews while the work continues. Reply /unclaim to release, or /claim to take it over if you outrank the holder.

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

    agent/reviewerFiled by the reviewer agenthelp wantedDenotes an issue that needs help from a contributor. Must meet "help wanted" guidelines.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions