推送通知连接拒绝 APNS
我正在尝试向我创建的应用程序添加推送通知。我遵循了苹果指南,并且能够注册设备以接收来自 APNS 的 devicetoken 值的发布通知。当我尝试向 APNS 发送数据时,就会出现问题,我的连接总是被拒绝。
我所做的唯一不标准的事情是推送通知证书的私钥是由非团队代理创建的(但通过团队代理帐户)。有谁知道团队代理是否必须生成推送通知的私钥?
Am attempting to add push notifications to an application that I have created. I followed the apple guide and am able to register the device for post notifications receiving a devicetoken value from APNS. The trouble occurs when I attempt to send data to the APNS to send, I always have my connection refused.
The only thing that i have done that is non standard is that the private key for the push notification certificate was created by a non-team agent (but through the Team agents account). Does anyone know if the team agent has to generate the private key for the push notification?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
如果您使用的是 Ad Hoc prov。 profile,不要使用沙箱 apns,使用生产服务器。
团队代理和管理员都应在其计算机上拥有私钥,他们应该能够创建必要的证书。
If you are using Ad Hoc prov. profile, don't use sandbox apns, use the production server.
Both team agents and admins should have their private keys on their machines, they should be able to create the necessary certificates.
您是否有理由想要设置自己的推送通知服务器?您只需使用Urbanairship即可,它提供免费的推送通知服务。
如果您仍然需要设置自己的服务器,可以找到有关生成证书的信息 此处。确保您连接到 Apple 这边正确的推送服务器。有不同的服务器用于调试和生产目的。
Is there a reason that you want to setup your own push notification server? You can just use Urbanairship which provides free push notification services.
If you still need to set up your own server, info on generating your certificates can be found here. Make sure that you're connecting to the right push server on Apple's side. There are different server's for debugging and production purposes.