Skip to content

[bug] An Android phone still signs a TV in after the TV cancels phone sign-in #738

Closed

Description

@Quick104

What happened

When an Apple TV or Android TV is on its sign-in screen, an Android phone or tablet offers "Sign in to ?". If the person at the TV chooses Allow and then Cancel while the phone is still showing the code to compare, the phone keeps "Yes, this matches" enabled. Tapping it approves the TV's sign-in request and the TV signs in, while the phone reports a failure (" cancelled." or " closed the connection. Try again.").

This happened 4 times out of 4: twice with an Apple TV simulator and twice with an Android TV emulator. The server recorded each of the four requests as approved by the phone's account and then collected by the TV, with none cancelled.

An iPhone and iPad fail closed with the same steps: the TV's cancel reaches them in about a second and removes the button. A Roku also fails closed because it cancels its own request (the approve gets 409), but it then says "Sign-in was declined on your phone." and the phone shows the raw text "Device login request was canceled on the device".

Steps to reproduce

  1. On an Apple TV or Android TV, choose a server and stay on the sign-in screen with the code showing.
  2. On a signed-in Android phone on the same network, tap Sign in on the offer for that TV and choose the server.
  3. On the TV, choose Allow.
  4. While the phone shows "Check that shows", press Cancel on the TV.
  5. Tap Yes, this matches on the phone.

Expected behavior

Once the TV cancels, the phone stops, approves nothing, and says the TV cancelled. The TV stays on its sign-in screen and is not signed in.

Device

Android phone; Android tablet

Device model and OS version

Android phone and tablet emulators (Android 14). TVs: Apple TV 4K simulator (tvOS 27.0, silo-apple main at f3347940) and Android TV emulator (Android 14).

App version and build

Debug build from main at 8fff98ba3

Installed from

Built from source

Silo server version

main at 3cd9e484

Relevant server logs

Request rows on the server for the four attempts (ids and codes redacted): status consumed, approved_at followed by consumed_at 0.7–3.0 s later, canceled_at empty.

Technical notes

In android-shared/.../pairing/CompanionPairingCoordinator.kt, the confirmation waits on a separate decision. When the TV's connection closes, the reader only closes its inbox, and after "Yes" the approve call runs before the coordinator reads that closed inbox (around lines 301 and 473 at 8fff98ba3).

In sign-in mode the TV reuses the request on its screen and keeps it after cancelling the LAN attempt (Apple ReceiverPairingCoordinator.swift, Android PairingReceiver.kt around line 493), so the late approval lands on a live request. The server behaves correctly: it never issues tokens for an expired, denied, or cancelled request.

AI harness

Claude Code in T3 Code

AI tool(s)

Claude Code; OpenAI Codex for the static review

AI model(s)

claude-opus-5-5, claude-sonnet-5-5, gpt-6.1-sol

AI involvement

AI-assisted

Independent or adversarial review

A cross-provider static review (gpt-6.1-sol) flagged this path before the live run, and the live run confirmed it on both TV families.

Confirmations

  • I searched open and recently closed issues and pull requests, and this is not already reported
  • I reproduced this myself on the device and app version above (reproduced by the AI agent on simulators, emulators, and Roku hardware)

Source: found while validating Silo-Server/silo-server#1192 (AI-run check, 2026-10-30).

Activity

  1. added
    bug
    on Oct 30, 2026
  2. added
    impact: security
    priority: P1
    triaged
    on Oct 30, 2026
  3. Quick104 commented on Oct 30, 2026

    @Quick104
    ContributorAuthor

    🤖 AI agent claim. Claude Code (claude-opus-5-5) is working on a fix for this issue on behalf of @Quick104, who is assigned.

    A pull request will link here when the fix is ready. If the work stops without a fix, the assignment and this comment are removed.

    Planning to work on this, or have context to add? Reply here and mention @Quick104.

  4. self-assigned this
    on Oct 30, 2026
  5. added a commit that references this issue on Oct 31, 2026
    900bdd3
  6. added a commit that references this issue on Oct 31, 2026
    c031104
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

bugimpact: securitypriority: P1triaged

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions