matrix-org / sygnal

Sygnal: reference Push Gateway for Matrix
Apache License 2.0
167 stars 148 forks source link

Not a bug, but a problem with the delivery of notifications to iOS #318

Closed qcdnru closed 2 years ago

qcdnru commented 2 years ago

Hi guys I have a problem delivering push notifications to my own ios client via a self-hosted Sygnal. I have tried different configuration options such as:

Sygnal config: XXXXXXXX.ios.dev: type:apns keyfile: XXXXXXXX.p8 key_id: XXXXXXXX team_id: XXXXXXXX topic: XXXXXXXX.dev, XXXXXXXX.dev.voip, XXXXXXXX.complication platform: sandbox

Console output from Signal: WARNING sygnal.http [bc84308d-5efa-44b7-8f0e-e7f45e993b98] Got notification for unknown app ID XXXXXXXX.ios.prod 2022-08-01 16:39:33,137 [22222] INFO sygnal.http [bc84308d-5efa-44b7-8f0e-e7f45e993b98] Successfully delivered notifications with 1 rejected pushkeys 2022-08-01 16:39:33,137 [22222] INFO sygnal.access Handled request: "127.0.0.1" - - [01/Aug/2022:13:39:33 +0000] "POST /_matrix/push/v1 /notify HTTP/1.0" 200 62 "-" "Synapse/1.49.2"

Signal config: XXXXXXXX.ios.prod: type:apns keyfile: XXXXXXXX.p8 key_id: XXXXXXXX team_id: XXXXXXXX topic: XXXXXXXX.prod, XXXXXXXX.prod.voip, XXXXXXXX.complication platform: sandbox

Console output from Signal: ERROR aioapns Status of notification 54926c84-bd6c-42fb-9662-0e587a38150d is 400 (BadDeviceToken) 2022-08-01 17:06:18,725 [25073] INFO sygnal.apnspushkin [8acc2df2-10c7-4c5a-a6c0-a5582dec6469] APNs token e68ea8625d2bcb43b95bc5ae75646d4940e7270d2821dfcd093111f9c9d3d9d6 for pushkin XXXXXXXXt.ios.prod was rejected: 400 BadDeviceToken 2022-08-01 17:06:18,725 [25073] INFO sygnal.http [8acc2df2-10c7-4c5a-a6c0-a5582dec6469] Successfully delivered notifications with 1 rejected pushkeys

I'm trying to set up notifications for the developer version of my matrix client, but I don't understand what I'm doing wrong. Please help me

initpwn commented 2 years ago

Your client is registered with the production access token while sygnal environment is development. Use production certificate or if want both prod & dev, re-login the client.

H-Shay commented 2 years ago

I am closing this as it is not a bug. You can find support for de-bugging specific instances in the #sygnal:matrix.org room.