问题
What network services, port numbers, outgoing incoming or both, need to be open on a network for an ipod touch to receive Apple Push Notifications?
I know the outgoing port number to set when sending the apns. The only thing is, in my school practically every outgoing (and incoming) port is blocked and as a result APNs do not work. I am sure that if I talked to my network administrator and told him which port to unblock, he would do so. So my question is: What network services, port numbers, outgoing incoming or both, need to be open on a network for an ipod touch to receive Apple Push Notifications?
回答1:
According to Apple's docs: port 5223.
If the device is connected over Wi-Fi and is still unable to receive notifications, the Wi-Fi network you're using might have a firewall that is blocking port 5223. This port must be open to TCP traffic for notifications to work.
回答2:
For APNS to work from within your network you must be able to communicate to 17.0.0.0/8:5223. The TCP connection is made from iOS device out to *.push.apple.com. There is no inbound TCP connections required.
来源:https://stackoverflow.com/questions/1950546/port-number-for-incoming-apple-push-notifications