Does Firebase not work behind proxies?
I am making an Android app for the students of my institute.
The app does not receive the notification when it is connected to the internet through the proxy servers.
But as soon as I turn on the mobile data, notifications are received.
How do I solve this problem?
Firebase doesn't work behind PROXIES.
We have had this issue since Firebase launched. See here; https://github.com/firebase/firebase-tools/issues/36 and here; https://groups.google.com/forum/#!topic/firebase-talk/UNO58i1mUYw.
Just google 'firebase behind proxy'. Personally, I am still hopeful that one day we'll get a fix.
Elvis is correct but I'd like to point to the documentation where this is discussed.
If your organization has a firewall that restricts the traffic to or
from the Internet, you need to configure it to allow connectivity with
FCM in order for your Firebase Cloud Messaging client apps to receive
messages. The ports to open are: 5228, 5229, and 5230. FCM typically
only uses 5228, but it sometimes uses 5229 and 5230. FCM doesn't
provide specific IPs, so you should allow your firewall to accept
outgoing connections to all IP addresses contained in the IP blocks
listed in Google's ASN of 15169.
I was facing this issue when app was using my institute internet, then I installed drony, routed all traffic using the vpn created by the drony and now the firebase is working fine.
Checkout drony settings here