You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Self-hosted iOS pairing is unreachable: #2734 fix lands, then #4198 blocks credential import
Summary
On a self-hosted relay, applying the buzz-pair-relay sidecar workaround from #2734
gets mobile pairing through steps 1 and 2 (QR scan, SAS confirm), but step 3
(credential import) then fails with the HTTPS requirement from #4198.
The two known issues compose into a dead end: there is no configuration that
satisfies both the relay's NIP-98 check and the iOS app's HTTPS requirement.
Added a pair-relay service using the same image with entrypoint: /usr/local/bin/buzz-pair-relay, exposed it on its own hostname,
and set BUZZ_PAIRING_RELAY_URL on the main relay.
Two details that were not obvious and may be worth documenting:
BUZZ_PAIR_RELAY_BIND_ADDR defaults to 127.0.0.1:5000, so the sidecar is
unreachable from outside the container unless it is set to 0.0.0.0:5000.
The relay derives the expected URL scheme from the protocol it received, not
from forwarding headers. Behind a TLS-terminating proxy this is always http.
Inspecting the relay binary, there appears to be no way to change that:
no env var matching BUZZ_*(PROXY|FORWARD|SCHEME|TRUST)*
no X-Forwarded-Proto / trust_proxy handling strings
no BUZZ_TLS* / BUZZ_CERT* — the relay does not terminate TLS itself
So the requirements are mutually exclusive:
Client
Requires
iOS app (credential import)
https://
CLI, desktop, agents (NIP-98)
http://
Suggested directions
Have the iOS credential import accept http:// for private/self-hosted
relays, or gate the check on something other than the scheme.
Or let the relay trust X-Forwarded-Proto (opt-in env var), so operators
behind a reverse proxy can present https:// consistently to all clients.
Self-hosted iOS pairing is unreachable: #2734 fix lands, then #4198 blocks credential import
Summary
On a self-hosted relay, applying the
buzz-pair-relaysidecar workaround from #2734gets mobile pairing through steps 1 and 2 (QR scan, SAS confirm), but step 3
(credential import) then fails with the HTTPS requirement from #4198.
The two known issues compose into a dead end: there is no configuration that
satisfies both the relay's NIP-98 check and the iOS app's HTTPS requirement.
Environment
ghcr.io/block/buzz:main@sha256:295bf4f5fa93…0.2.10.5.24(macOS, Apple Silicon)What works after the #2734 workaround
Added a
pair-relayservice using the same image withentrypoint: /usr/local/bin/buzz-pair-relay, exposed it on its own hostname,and set
BUZZ_PAIRING_RELAY_URLon the main relay.Two details that were not obvious and may be worth documenting:
BUZZ_PAIR_RELAY_BIND_ADDRdefaults to127.0.0.1:5000, so the sidecar isunreachable from outside the container unless it is set to
0.0.0.0:5000.Pairing now progresses:
Desktop shows steps 1 and 2 as complete (QR scanned, six-digit SAS confirmed on
both devices).
Where it fails
Step 3 fails on the phone:
Both sidecar connections then close and the desktop UI spins on
"Pairing mobile device…" indefinitely with no timeout or error surfaced:
The phone never reaches the main relay — no new pubkey appears in relay logs.
Why this cannot be fixed by configuration
Switching the relay URL to
https://breaks NIP-98 auth for every other client:{"error":"auth_error","message":"relay error 401: NIP-98: NIP-98 HTTP Auth verification failed: URL mismatch: event has `https://<host>/query`, expected `http://<host>/query`"}The relay derives the expected URL scheme from the protocol it received, not
from forwarding headers. Behind a TLS-terminating proxy this is always
http.Inspecting the relay binary, there appears to be no way to change that:
BUZZ_*(PROXY|FORWARD|SCHEME|TRUST)*X-Forwarded-Proto/trust_proxyhandling stringsBUZZ_TLS*/BUZZ_CERT*— the relay does not terminate TLS itselfSo the requirements are mutually exclusive:
https://http://Suggested directions
http://for private/self-hostedrelays, or gate the check on something other than the scheme.
X-Forwarded-Proto(opt-in env var), so operatorsbehind a reverse proxy can present
https://consistently to all clients.BUZZ_PAIR_RELAY_BIND_ADDRdefault and shippingthe sidecar in
deploy/composewould close deploy/compose: mobile pairing broken out of the box — bundle ships no buzz-pair-relay and relay 404s the legacy /pair fallback #2734.Related
deploy/composeships nobuzz-pair-relay; relay 404s the legacy/pairfallbackHappy to test patches on this setup.