The documentation from Google indicates that the Google Cast extension is not supported in Linux, but it actually does work. In order for it to work you must configure iptables to allow the uPnP/SSDP traffic used by the Google Cast browser extension to discover the Chromecast Devices.

The browser will send a multicast UDP packet from the local IP and an ephemeral (random) port to 239.255.255.250 port 1900. The ChromeCast device will respond with a unicast UDP packet from the ChromeCast device’s IP and another ephemeral port to the source IP/port of the multicast packet. Note that this is slightly different than most other UPnP devices, which will usually respond with a unicast UDP packet from port 1900 instead of an ephemeral port.

You will need to add a rule to accept UDP packets on all ephermeral ports. The ephermal port range for the inital multicast packet should be 32768 to 61000.

iptables -I INPUT -p udp -m udp --dport 32768:61000 -j ACCEPT

Once you have made this change in iptables you must restart the browser. You should now find your Chromecast devices to be discoverable in Chrome.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.