Skip to content

bug: import with pubky ring fails after authorize #785

Description

@ovitrif

What happened?

"Import with Pubky Ring" fails after the user taps Authorize in Pubky Ring. Bitkit hands the Paykit grant request to Ring as a legacy sign-in, so Ring answers with a legacy auth token and Bitkit's grant flow rejects it. The profile and contacts are never imported.

PubkyRingAuthURLBuilder.ringHandoffURL (Bitkit/Managers/PubkyProfileManager.swift) sets the host of every handoff link to signin. That rewrites signin_grant requests, dropping their grant intent, while Pubky Ring 1.19 already handles pubkyring://signin_grant.

Expected behavior

The handoff keeps the grant intent (pubkyring://signin_grant, including its cid/cpk parameters). Ring then approves a grant, Bitkit accepts it, and "Found profile & contacts" appears.

Steps to Reproduce

  1. Install Pubky Ring 1.19 or later, holding a key with a Pubky App profile and at least one follow.
  2. In Bitkit, open Profile and choose "Import with Pubky Ring".
  3. In Ring, tap Authorize.
  4. Back in Bitkit: the import fails instead of showing "Found profile & contacts".

Logs / Screenshots / Recordings

  • Found by reading the handoff code and confirmed with an offline check of the handoff URL against Ring's handler. It has not yet been reproduced end to end on a device.
  • A fix that keeps signin_grant on the handoff, with a unit test for it, passes the unit tests on a demo branch and can be opened as a PR.
  • Overlap: feat: use pubky ring keys via shared keychain #774 removes this rewrite as part of the shared-keychain Ring flow. If feat: use pubky ring keys via shared keychain #774 lands first, this issue closes with it.

Bitkit Version

master at 69a85df

Device / OS

iOS Simulator, iOS 26.5, with a Pubky Ring 1.19 Release build

Reproducibility

Always, whenever the auth request is a signin_grant.

Activity

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

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions